d667efde68
A constant-time version of memcmp(), useful to compare nonces and counters in little-endian format, that plays well with sodium_increment(). Unlike sodium_memcmp() which can compare anything for equality, sodium_compare() is designed to compare things that are comparable, byte by byte. Therefore, the prototype is slightly different: its arguments are supposed to be `const unsigned char *`. The names sodium_memcmp() and sodium_compare() are slightly confusing. But we're not going to rename sodium_memcmp(), and I cannot think of a better name for sodium_compare() than sodium_compare(). |
||
---|---|---|
.. | ||
default | ||
quirks | ||
Makefile.am |