timing attack

Uses your system voice; voice and rate in settings.

Q2665075Snapshot

≈ 4 min read

Names in other languages

  • Portuguêsataque de temporização
  • FrançaisAttaque temporelle
  • РусскийАтака по времени
  • ΕλληνικάTiming Attack
  • Englishtiming attack
  • УкраїнськаАтака по часу
  • PolskiAtak czasowy
  • 日本語タイミング攻撃

Article bodies are English and are not machine-translated. A name in another language is not a translation of the article.

. The left graph denotes a timing attack successfully detecting a cached image whereas the right one shows an attack that fails to do the same. In cryptography, a timing attack is a side-channel attack in which the attacker attempts to compromise a cryptosystem by analyzing the time taken to execute cryptographic algorithms. Every logical operation in a computer takes time to execute, and the time can differ based on the input; with precise measurements of the time for each operation, an attacker may be able to work backwards to the input. Information can leak from a system through measurement of the time it takes to respond to certain queries. How much this information can help an attacker depends on many variables such as cryptographic system design, the CPU running the system, the algorithms used, assorted implementation details, timing attack countermeasures, and accuracy of the timing measurements. Any algorithm that has data-dependent timing variation is vulnerable to timing attacks. Removing timing-dependencies is difficult since varied execution time can occur at any level. Vulnerability to timing attacks is often overlooked in the design phase and can be introduced unintentionally with compiler optimizations. Countermeasures include blinding and constant-time functions.

. The left graph denotes a timing attack successfully detecting a cached image whereas the right one shows an attack that fails to do the same. In cryptography, a timing attack is a side-channel attack in which the attacker attempts to compromise a cryptosystem by analyzing the time taken to execute cryptographic algorithms. Every logical operation in a computer takes time to execute, and the time can differ based on the input; with precise measurements of the time for each operation, an attacker may be able to work backwards to the input. Information can leak from a system through measurement of the time it takes to respond to certain queries. How much this information can help an attacker depends on many variables such as cryptographic system design, the CPU running the system, the algorithms used, assorted implementation details, timing attack countermeasures, and accuracy of the timing measurements. Any algorithm that has data-dependent timing variation is vulnerable to timing attacks. Removing timing-dependencies is difficult since varied execution time can occur at any level. Vulnerability to timing attacks is often overlooked in the design phase and can be introduced unintentionally with compiler optimizations. Countermeasures include blinding and constant-time functions. include bool insecure_string_compare(const void *a, const void *b, size_t length) { const char *ca = a, *cb = b; for (size_t i = 0; i By comparison, the following version runs in constant-time by testing all characters and using a bitwise operation to accumulate the result: include bool constant_time_string_compare(const void *a, const void *b, size_t length) { const char *ca = a, *cb = b; bool result = true; for (size_t i = 0; i In the world of C library functions, the first function is analogous to , while the latter is analogous to NetBSD's or OpenBSD's and . On other systems, the comparison function from cryptographic libraries like OpenSSL and libsodium can be used. ==References== ==Further reading==   Describes dudect, a simple program that times a piece of code on different data.

Text derived from https://en.wikipedia.org/w/index.php?oldid=1372367929 under CC BY-SA 4.0; modifications have been made.

Provenance

snapshot timing-attack-313122-fd67f127a96e7a43 · hash fd67f127a96e7a430a56d7b2ced5d1dfbaef87ca5fc43ccf1f943fe6c21d8ea3 · captured 1788172039.0 · version history

Cite this page as: encyclopegia.org, “timing attack”, snapshot timing-attack-313122-fd67f127a96e7a43. https://encyclopegia.org/a/timing-attack