Commit Graph
4 Commits
Author SHA1 Message Date
jacob6769 e56245a42c Merge remote-tracking branch 'origin/main' into fix/libressl-digest-version-paths
# Conflicts:
#	core/libs/prx/libSceLibreSsl3/src/Digest.cpp
#	core/libs/tests/GuestLibreSslDigest.cpp
#	docs/dev/debt/libSceLibreSsl.md
2026-10-25 15:13:36 +09:00
boykopovar f38d29fd08 refactor(sdk): add canonical headers for remaining libraries 2026-10-24 23:17:42 +03:00
jacob6769andClaude Opus 5.5 0fed30252a fix(libSceLibreSsl): follow LibreSSL 2.5.4 and 4.0.0 for null digest buffers and SHA-512/t lengths
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-10-24 12:01:56 +09:00
HQasperandClaude Opus 5.5 52a439bc70 feat(libSceLibreSsl): implement the MD4, MD5, SHA-1 and SHA-2 digests
MD4, MD5, SHA1, SHA224, SHA256, SHA384 and SHA512 Init/Update/Final and
the SHA256 one-shot threw. They now hash as LibreSSL does, on the
caller's MD4_CTX, MD5_CTX, SHA_CTX, SHA256_CTX and SHA512_CTX laid out as
in LibreSSL's md4.h, md5.h and sha.h, so a context copied or inspected
by the title stays valid: the bit count in Nl/Nh, the partial block in
data with its length in num, and md_len selecting the truncated digest.
Final pads and clears the buffer as LibreSSL's sources do.

Cases that differ between LibreSSL versions throw: SHA256 with a null
digest buffer and SHA512_Final with the SHA-512/224 or SHA-512/256
length. The test checks the RFC 1320, RFC 1321 and FIPS 180 vectors over
several chunk sizes, the context fields, copied contexts and those
cases.

Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
2026-10-21 09:59:04 +00:00