Last active
August 29, 2015 14:02
-
-
Save acoomans/d34765b7abcc1fbbf89d to your computer and use it in GitHub Desktop.
How to calculate a MAC without leaking computation-time (side channel) info
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Everything you need to know about cryptography in 1 hour | |
| // http://www.daemonology.net/papers/crypto1hr.pdf | |
| for (x = i = 0; i < MACLEN; i++) { | |
| x |= MAC_computed[i] − MAC_received[i]; | |
| } | |
| return (x ? MAC_GOOD : MAC_BAD); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment