Commit Graph
10 Commits
Author SHA1 Message Date
Dean 0fbe14c153 Merge pull request #12945 from EagleBearerYS/feat/libressl3-bio-up-ref-on-12754
feat(libSceLibreSsl3): implement BIO_up_ref
2026-11-06 22:38:41 +13:00
Ryuzaki 3bdfa07d4d Merge upstream main into EVP_PKEY_bits branch 2026-11-06 07:49:46 +00:00
Dean Galvin a19cd6a1d3 Merge branch 'main' 2026-11-06 19:52:56 +13:00
Ryuzaki 35925a331f feat(libressl3): implement EVP_PKEY_bits 2026-11-05 11:23:14 +00:00
Dean Galvin 80bce94f35 Merge branch 'main' 2026-11-05 21:52:51 +13:00
9327713d3a fix(libSceLibreSsl): give EC keys libSceLibreSsl3's reference layout
libSceLibreSsl3 forwards EC_KEY_new, EC_KEY_new_by_curve_name and
EC_KEY_free here, while its EC_KEY_up_ref increments the counter at
offset 48 of LibreSSL 4.0.0's 64-byte EC_KEY. On the 8-byte keys of the
previous commit, that write lands past the end of the key.

Keys now have that layout and LibreSSL 2.5.4 EC_KEY_new's defaults:
version 1, uncompressed conversion form, the group in its group slot
and the reference count, starting at one, at offset 48. EC_KEY_free
decrements it atomically and frees the key at zero or below, as
LibreSSL does.
libSceLibreSsl3's interface and code are unchanged.

Co-authored-by: Ahmad Mujahid <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-03 09:14:47 +01:00
Yunus Shaikh 82c0aa626f feat(libSceLibreSsl3): implement BIO_up_ref
BIO_up_ref adds one to the reference count of a caller-owned BIO through
the shared retain in Reference.hpp and returns 1 when the new count is
above 1, as CRYPTO_add(...) > 1 does. LibreSsl3Bio in Key.hpp is the
112-byte BIO with its counter at offset 80.

Behaviour and layout follow LibreSSL 4.0.0 (ce488b78e0bd): bio_lib.c
L198-L202 and bio_local.h. No upstream source is copied.
2026-10-31 16:17:38 +00:00
PrivacyOnion 3e2103d0f3 feat(libressl3): retain SSL_CTX references 2026-10-31 15:30:39 +00:00
msbutt1 f1f3ba8ed4 feat(libSceLibreSsl3): implement RSA_up_ref 2026-10-30 04:38:39 -06:00
atharvjairath 5255577954 feat(libressl3): retain EVP and EC key references 2026-10-27 03:31:01 +05:30