
Küçük et al.
and evaluate systematically whether TEE assistance can fulll the
implementation details of a stronger malware. Section 4 relates
to this theme by comparing a TEE assisted malware with wild
malware in a system. The relation of Section 5 to the paper’s theme
is to discuss the remaining aspects potentially being abused by
bad actors, and how these aspects should be considered in future
trusted hardware designs. We do not intend to discuss how attackers
should be developing malware in next-generation TEE. We show
why attackers would nd developing malware with TEE infeasible.
We hypothesise that malware in TEE gives no new advantages
to attackers; we will discuss how it brings disadvantages in some
cases.
Contributions:
This study presents the most comprehensive
collection of misconceptions about malware in enclaves to date.
Our novel contribution is that we systematically show why mal-
ware becomes weaker due to trusted hardware. We also clarify the
ambiguity of malware in an SGX-enclave and the malware in the
core SGX ecosystem.
Concepts:
Throughout the paper, we may use the following
synonyms. Wild malware refers to malware in commodity sys-
tems, malware in the untrusted world, ELB in IoT deployments, or
malware in a highly noisy system. Enclave-based malware refers
to a malicious code placed in a custom developed enclave, SGX-
malware, SGX-based malware, malware based on trusted hardware,
or malware in TEE. In order to distinguish the core SGX ecosystem
from custom developed enclaves, we provide a detailed denition
in Section 1.3.
1.1 Scope of Malware
Malware presence can be in various forms; virus, worm, trojan,
zombie/botnet, phishing/spam, spyware, keylogger, snier and ran-
somware. Throughout this paper, we refer to this section for the
precise scope of the malware. We take into account specically the
malicious software targeting Windows PCs. Nevertheless, most of
our systematisation can also be valid for Linux distributions and OS
X systems (Intel, non-ARM). Malware targeting other commodity
operating systems, advanced persistent threats (APT), and other rel-
atively harmful software can be explored outside of this paper. We
keep relatively badly behaving software outside of the malware def-
inition. A bad program is one, when found and analysed by an AV
company, is subsequently detected by their malware detection sys-
tems. Finally, we consider malware as malicious software tailored
for disruption, damage and unauthorised access to the commodity
computer system. We describe the characteristics of malware in
more detail in Section 1.2. Similar to malware in a single computer,
an IoT deployment with tens of devices in a house suers from the
same problems due to ELB.
1.2 Characteristics of Malware
The ideal malware must
2
have the characteristics listed below for
a successful malware campaign. However, one of the fundamental
issues is that these characteristics can also be seen in benign and
legitimate software. Having these characteristics in benign soft-
ware makes malware detection a challenging task for anti-malware
mechanisms.
2
Others may structure these characteristics or malware patterns in an alternative way.
1.2.1
Persistence across boot cycles/load at startup
.The mal-
ware must be able to reload itself whenever the system is available.
This can be done via scheduled events, registry entries, drivers and
functions in other processes. Section 3.5 presents the persistence
aspect of enclave-assisted malware.
1.2.2
Communication on demand
.Ideally, the malware must
be able to communicate with the author to receive commands or
leak information whenever required. Communication might be nec-
essary for reselling the network of victims, fetching a new payload
or ready-to-use new exploits, or equipping malware with up-to-date
zero days to be exploited. A secure communication channel is also
required for the key management; whether the keys are managed
locally or through external servers, the malware must have a direct
or indirect key management channel. We present the communica-
tion aspects in Section 3.3 and Section 3.6, and key management
aspects in Section 3.2 and Section 3.4.
1.2.3
Full Un-Detection (FUD)
.The malware must remain fully
undetected throughout its life cycle against any possible detection
mechanisms. At a minimum, this can be done via resilience to all
anti-virus software products in the market. FUD checks can be done
oine via automated environments without leaking the know-how
of malware. We present the arguments on detection in Section 3.1
and Section 3.7.
1.2.4
Access to system calls/APIs
.Ideal malware must be able
to access kernel functionalities, system calls, and Application Pro-
gramming Interfaces (APIs) present for low-level operations. Access
to the full system is especially necessary for targeted attacks where
a victim user’s core assets are extracted. Section 3.8 presents the
arguments on syscalls.
1.2.5
The highest possible privileges
.The malware must es-
calate into privilege levels present in a system as high as possible.
Most attacks may begin at the lowest level of permissions; however,
successful malware must be equipped with the necessary payloads
to exploit the rest of the system. Section 3.5 and Section 3.9 present
the arguments on malware privileges.
1.2.6
Unrestricted resources and assets
.Ideally, malware must
be able to use all system resources without restrictions. Resources
may refer to all devices/components other than computational abil-
ities and full memory access. These resources may also contain the
target user assets and valuable information. We present the argu-
ments on resources in Section 3.10 and on user assets in Section 3.4.
1.2.7
Infect more targets, audience and availability
.Ideally,
malware must aim to infect more victims in a campaign. Infection
rate can be a success measure for malware. A malicious attack
targeting one specic system might fall into the APT category. For
compatibility, the target system must full the requirements of
the malware at infection time. Further, if the malware has specic
dependencies to operate, these dependencies must continue to be
available. We present the arguments on target victims in Section 3.11
and malware availability in Section 3.3.
1.2.8
Maximise revenue/profit and long-term maintenance
.
The goal of malware should be to increase its prot above all. The
monetisation of a campaign might be a way to see the prot, but the