Lucas Gabriel Vuotto
9ba30dbe41
hash/sha512: add SHA-512/224 and SHA-512/256 variants
2024-06-17 14:41:20 +00:00
Lucas Gabriel Vuotto
666b833b98
auth/hmac: complete overhaul
...
Now that there are dedicated struct for initial parameters, make the
HMAC params provide a lc_hash_ctx to be used internally. This makes HMAC
less special and allows it to work with any hash, instead of needing
dedicated inits and ctx_news. As an upside, now it's possible to have a
one-pass HMAC.
2024-06-10 17:29:29 +00:00
Lucas Gabriel Vuotto
c54ac8289b
Shuffle code around in Wycheproof tests
...
Group struct, put utility functions before main, put runners after main
and rename kwimpl to kwrunner.
2024-06-08 00:45:45 +00:00
Lucas Gabriel Vuotto
61d9652b2e
Fix Wycheproof tests for params
2024-06-08 00:35:49 +00:00
Lucas Gabriel Vuotto
1a8f813442
hash: implement SHA-{224,256}
...
Add the HMAC and Wycheproof bits for HMAC while at it.
2024-06-07 03:14:21 +00:00
Lucas Gabriel Vuotto
52ab9ca179
ct/lc_ct_cmp: improve interface
...
Return 0xffffffff if arguments compare equal, 0 otherwise. Change all
consumers accordingly.
2024-06-06 13:49:25 +00:00
Lucas Gabriel Vuotto
ad42d99e0b
auth: add HMAC implementation
...
This allows for checking the SHA-512 implementation against Wycheproof
via the HMAC tests.
2024-06-06 12:41:44 +00:00