5 ms·
This allows an attacker to iteratively try various HMAC values and see how long it takes the server to respond. The longer it takes, the more characters he has
by crescendo 17y ago
This allows an attacker to iteratively try various HMAC values and see how long it takes the server to respond. The longer it takes, the more characters he has correct.
Can one of the security gurus here explain this in a bit more detail? I'm guessing he would base this on an average over a sample of response times with the same input. Otherwise, how would he account for other things happening on the server that could affect the timing for a single request?
- tptacek 17y agoExactly like that.
- NateLawson 17y agoThe important thing that probably isn't obvious is how few samples you actually need. Jitter is essentially random, which means it is decorrelated from the repeated pattern (1 compare takes longer, 255 take the same time) With the added noise (jitter), all you need to do is distinguish the two normal distributions. This takes less samples than you might guess at first. Think of it as the same problem as distinguishing a biased coin (51% heads) from an indentical-looking unbiased one, merely by flipping each. Given the known bias percent and a desired confidence level (say 95%), calculate how many flips you will need to make a decision.