67d4de1657
Move all inout parameters to the front of the arguments list
2024-06-07 17:47:42 +00:00
7b539ccdcd
cipher/chacha20: logical AND is &&
2024-06-07 17:34:03 +00:00
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
0605d10bb3
Implement XChaCha20 and XChaCha20-Poly1305
2024-06-07 02:18:50 +00:00
06f835e27c
cipher/chacha20: treat the counter as part of the nonce
2024-06-07 00:29:25 +00:00
b793cb5b69
cipher/chacha20: rename chacha20_x to chacha20_common
2024-06-07 00:29:25 +00:00
e5215ac18e
cipher/chacha20: buffer the full input block
...
The final implementation is simpler, at the cost of doing work in
chacha20_x_final.
2024-06-07 00:29:17 +00:00
5bd46fffa6
aead/chacha20-poly1305: use chacha20_x_final instead of reaching into chacha20_ctx guts
2024-06-07 00:29:17 +00:00
11b86db9db
auth/hmac: 0-pad the hashed key in longer-than-blocksize case
2024-06-06 17:14:30 +00:00
d6235df66f
wycheproof: add a failfast mode
2024-06-06 17:12:41 +00:00
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
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
216ef8f940
Add hash interface and SHA-{384,512} implementations
2024-06-06 12:40:38 +00:00
f511cddf0d
Fix *_ctx_new and *_ctx_free implementations
...
They both will only alloc and free the internal *_ctx structs. Get rid
of the void * argument for new and only pass arg to *_free instead of
the whole lc_*_ctx struct.
2024-06-06 11:45:30 +00:00
0a47025c19
util/hexdump_line: fix space padding
2024-06-06 00:56:20 +00:00
6ac9d9b325
util/lc_hexdump_fp: advance pointer
2024-06-05 23:36:48 +00:00
dd94f1e75d
Makefile.inc: organize LC_SRCS and use WARNINGS instead of defining our own
2024-06-05 23:10:04 +00:00
e9bcc64e62
Make all *_impl provide ctx_new and ctx_free functions
2024-06-05 22:05:37 +00:00
fa489d2b4b
Update README to reflect completion of aead_open for ChaCha20-Poly1305
...
Missed in 217145edc0
.
2024-05-31 22:03:52 +00:00
f0b5d01017
util: add hexdump function
2024-05-31 21:54:10 +00:00
f3667cfe05
util: make lc_scrub public
2024-05-31 21:51:37 +00:00
afc2e4b721
wycheproof: hide debug output behind -v flag
2024-05-31 16:53:05 +00:00
e62534925b
wycheproof: depend on the static lib
2024-05-31 16:47:18 +00:00
6f0fdd23f6
wycheproof_aead: test against lc_aead_open
2024-05-31 16:46:54 +00:00
217145edc0
aead: implement ChaCha20-Poly1305 open
2024-05-31 16:46:05 +00:00
8f8924bfdf
Make .gitignore ignore all the obj/ directories
2024-05-31 11:48:43 +00:00
eedaa46831
wycheproof_aead: divide by 8 at parse time
2024-05-31 11:47:42 +00:00
7bc527c769
initial import
2024-05-31 10:59:58 +00:00