Lably
Skip to content

Side-channel attack

Any attack based on information gained from the implementation of a computer system

  • 10 min read
  • 2 chapters

Related on Lably

Through Computer security, Algorithm and HTTPS

Some side-channel attacks require technical knowledge of the internal operation of the system, others such as differential power analysis are effective as black-box attacks. The rise of Web 2.0 applications and software-as-a-service has also significantly raised the possibility of side-channel attacks on the web, even when transmissions between a web browser and server are encrypted (e.g. through HTTPS or WiFi encryption), according to researchers from Microsoft Research and Indiana University.

Attempts to break a cryptosystem by deceiving or coercing people with legitimate access are not typically considered side-channel attacks: see social engineering and rubber-hose cryptanalysis.

General classes of side-channel attack include:

  • Cache attack – attacks based on attacker's ability to monitor cache accesses made by the victim in a shared physical system as in virtualized environment or a type of cloud service.
  • Timing attack – attacks based on measuring how much time various computations (such as, say, comparing an attacker's given password with the victim's unknown one) take to perform.
  • Power-monitoring attack – attacks that make use of varying power consumption by the hardware during computation.
  • Electromagnetic attack – attacks based on leaked electromagnetic radiation, which can directly provide plaintexts and other information. Such measurements can be used to infer cryptographic keys using techniques equivalent to those in power analysis or can be used in non-cryptographic attacks, e.g. TEMPEST (aka Van Eck phreaking or radiation monitoring) attacks.
  • Acoustic cryptanalysis – attacks that exploit sound produced during a computation (rather like power analysis).
  • Differential fault analysis – in which secrets are discovered by introducing faults in a computation.
  • Data remanence – in which sensitive data are read after supposedly having been deleted. (e.g. cold boot attack)
  • Software-initiated fault attacks – Currently a rare class of side channels, row hammer is an example in which off-limits memory can be changed by accessing adjacent memory too often (causing state retention loss).
  • Whitelist – attacks based on the fact that the whitelisting devices will behave differently when communicating with whitelisted (sending back the responses) and non-whitelisted (not responding to the devices at all) devices. Whitelist-based side channel may be used to track Bluetooth MAC addresses.
  • Optical – in which secrets and sensitive data can be read by visual recording using a high resolution camera, or other devices that have such capabilities (see examples below).

In all cases, the underlying principle is that physical effects caused by the operation of a cryptosystem (on the side) can provide useful extra information about secrets in the system, for example, the cryptographic key, partial state information, full or partial plaintexts and so forth. The term cryptophthora (secret degradation) is sometimes used to express the degradation of secret key material resulting from side-channel leakage.

Examples

A cache side-channel attack works by monitoring security critical operations such as AES T-table entry or modular exponentiation or multiplication or memory accesses. The attacker then is able to recover the secret key depending on the accesses made (or not made) by the victim, deducing the encryption key. Also, unlike some of the other side-channel attacks, this method does not create a fault in the ongoing cryptographic operation and is invisible to the victim.

In 2017, two CPU vulnerabilities (dubbed Meltdown and Spectre) were discovered, which can use a cache-based side channel to allow an attacker to leak memory contents of other processes and the operating system itself.

Timing attacks monitor data movement into and out of the CPU or memory on the hardware running the cryptosystem or algorithm. Simply by observing variations in how long it takes to perform cryptographic operations, it might be possible to determine the entire secret key. Such attacks involve statistical analysis of timing measurements and have even been demonstrated across networks.

A power analysis attack can provide even more detailed information by observing the power consumption of a hardware device such as CPU or cryptographic circuit. These attacks are roughly categorized into simple power analysis (SPA) and differential power analysis (DPA). One example is Collide+Power, which affects nearly all CPUs. Other examples use machine learning approaches.

Fluctuations in current also generate radio waves, enabling attacks that analyze measurements of electromagnetic (EM) emanations. These attacks typically involve similar statistical techniques as power-analysis attacks.

A deep-learning-based side-channel attack, using the power and EM information across multiple devices has been demonstrated with the potential to break the secret key of a different but identical device in as low as a single trace.

Historical analogues to modern side-channel attacks are known. A recently declassified NSA document reveals that as far back as 1943, an engineer with Bell telephone observed decipherable spikes on an oscilloscope associated with the decrypted output of a certain encrypting teletype. According to former MI5 officer Peter Wright, the British Security Service analyzed emissions from French cipher equipment in the 1960s. In the 1980s, Soviet eavesdroppers were suspected of having planted bugs inside IBM Selectric typewriters to monitor the electrical noise generated as the type ball rotated and pitched to strike the paper; the characteristics of those signals could determine which key was pressed.

Power consumption of devices causes heating, which is offset by cooling effects. Temperature changes create thermally induced mechanical stress. This stress can create low level acoustic emissions from operating CPUs (about 10 kHz in some cases). Recent research by Shamir et al. has suggested that information about the operation of cryptosystems and algorithms can be obtained in this way as well. This is an acoustic cryptanalysis attack.

If the surface of the CPU chip, or in some cases the CPU package, can be observed, infrared images can also provide information about the code being executed on the CPU, known as a thermal-imaging attack.

An optical side-channel attack examples include gleaning information from the hard disk activity indicator to reading a small number of photons emitted by transistors as they change state.

Allocation-based side channels also exist and refer to the information that leaks from the allocation (as opposed to the use) of a resource such as network bandwidth to clients that are concurrently requesting the contended resource.

Trusted execution environment attacks

What is a TEE?

A TEE is an isolated execution area designed to protect sensitive computations even if the normal operating system is compromised.

Trusted execution environments (TEEs) such as Intel SGX and AMD SEV are designed to isolate sensitive computations from the rest of a system, but researchers have demonstrated numerous side-channel attacks against them, including page-fault-based attacks, cache-based attacks such as SGAxe, and memory-bus attacks. These attacks are notable because they undermine the isolation guarantees that TEEs are specifically designed to provide, even when the surrounding operating system or hypervisor is compromised.

A Trusted Execution Environment (TEE) attack is an attack that attempts to compromise the confidentiality or integrity of code and data that are supposed to be protected inside a hardware-backed secure environment.

Sign in to keep reading

One more chapter is free with a Lably account.

More in Computing and communication