Nikos Mavrogiannopoulos nmav@gnutls.org writes:
nettle_memcmp?
I'd prefer to avoid "memcmp" in the name, since the return value is very different from libc memcmp. Nettle's function returns 1 for equality, and 0 for inequality. So the name should associate with equality.
"sec" in the name is a gmp convention for side-channel silent functions, where it's usually a prefix, e.g., mpn_sec_mul. But it is used mainly when there is some "non-sec" function computing the same thing but with side-channel leaks.
nettle/mem.h, which will include memxor, memcmp, and memset?
Makes sense. Or memory.h, or memops.h.
Regards, /Niels