4 ms·
I'm not too much of a cryptography expert. How do I know if I'm using a > constant-time cryptographic library ? Edit: thanks everyone, I just wasn't familia
by kube-system 4y ago
I'm not too much of a cryptography expert. How do I know if I'm using a
> constant-time cryptographic library
?
Edit: thanks everyone, I just wasn't familiar with the terminology.
- arkadiyt 4y agoIf your cryptographic library is not constant time then it is already vulnerable. This new attack is able to target the even previously unaffected constant time libraries - that's why they call it out specifically in their FAQ, but this is saying that _all_ cryptographic libraries are vulnerable to timing/side channel attacks (when running on processors which don't have these performance features disabled).
- Grimburger 4y agoIf you are not using one it is a very bad sign. All modern cryptographic libraries use various constant time operations.
- zamalek 4y agoIf it's the one built into your language stdlib, then you almost certainly are. Crypto libraries that are not constant time tend to not pass audits.
- Phlarp 4y agoAs one example, SSL uses constant-time crypto operations, so the answer to this question is an almost universal "yes"
- deleted 4y ago[deleted]
- nindalf 4y agoAll libraries we use are constant time. What’s constant time? Crypto libraries need to do operations to encrypt and decrypt your data. The simple, naive implementation of these operations will work - giving correct input and output. However, a person can time the operation being performed and learn about the key being used. If you’ve deployed on a server and the other person can submit any text they want, whenever they want, they would be able to extract the key from your naive implementation. That’s bad, the worst outcome possible. That’s why good libraries will make sure that these operations take the same amount of time, regardless of input. So we thought we were safe. And now these authors tell us, no. That’s not the case. The guidelines used by crypto library developers don’t protect against the attack being described here.
- Zamicol 4y ago>All libraries we use are constant time. Well, except anything Javascript. "Node.js’s crypto libraries do not provide constant-time guarantees and, unfortunately, are still at the mercy of the JavaScript GC" https://cseweb.ucsd.edu/~dstefan/pubs/renner:2018:ct-wasm.pdf https://cseweb.ucsd.edu/~dstefan/pubs/renner:2018:ct-wasm.pd...
- CodeArtisan 4y agoReturning earlier in a procedure or breaking a loop once a condition is met give inconstant time allowing to retrieve, for example, a password. Here an example in python: https://ideone.com/W24UZW https://ideone.com/W24UZW