summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/rsa/rsa_local.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Stop requiring the RSA_FLAG_SIGN_VERtb2025-01-051-4/+2
| | | | | | | | | | | | | | | | | | | | You can set custom sign and verify handlers on an RSA method (wihch is used to create RSA private and public key handles). However, even if you set them explicitly with RSA_meth_set_{sign,verify}(3), these handlers aren't used for the sake of "backward compatibility" (with what?). In order to use them, you need to opt your objects into using the custom methods you set by setting the RSA_FLAG_SIGN_VER flag. OpenSSL 1.1 dropped this requirement and therefore nobody sets this flag anyore. Like most of the mechanically added accessors, almost nothing uses them, but, as found by kn, the yubco-piv-tool does. This resulted in a public key being passed to rsa_private_encrypt(), which of course doesn't end well. So follow OpenSSL 1.1 and drop this muppetry. This makes kn's problem with yubico-piv-tool go away. ok jsing kn
* Remove weird pad member that was never set to zero after malloc() sotb2024-11-291-4/+1
| | | | | | the weird thing it was supposed to be doing couldn't possibly work. ok jsing
* pkey_is_pss() and pkey_ctx_is_pss() to rsa_ameth.ctb2024-01-011-5/+1
| | | | | These aren't particularly helpful and should probably both be expanded. For now move them to the only place where they are actually used.
* Ignore ENGINE at the API boundarytb2023-11-291-3/+1
| | | | | | | | This removes the remaining ENGINE members from various internal structs and functions. Any ENGINE passed into a public API is now completely ignored functions returning an ENGINE always return NULL. ok jsing
* Rework BN_BLINDING to use pthread_t directlytb2023-08-091-2/+2
| | | | | | | | | | Instead of CRYPTO_THREADID, which passes pthread_via through unsigned long, we can use pthread_self() and pthread_equal() directly. This commit keeps using the awkward 'local' nomenclature as that is used throughout the rsa code. This will be changed after the blinding code will have been fully merged into rsa_blinding.c. ok jsing
* Move bn_blind.c to rsa_blinding.ctb2023-08-091-1/+8
| | | | discussed with jsing
* Make BN_BLINDING internaltb2023-07-281-1/+3
| | | | | | | | | | RSA is pretty bad. In my most optimistic moments I dream of a world that stopped using it. That won't happen during my lifetime, unfortunately. Blinding is one way of making it a little less leaky. Unfortunately this side-channel leak mitigation leaked out of the library for no good reason. Let's at least fix that aspect of it. ok jsing
* Add missing license for rsa_local.htb2023-07-211-1/+57
| | | | discussed with jsing
* Add back support for RSA_X931_PADDINGtb2023-05-051-1/+7
| | | | | | | This makes the custom stalt stack work again. Tested by robert as part of a larger diff ok jsing
* Make internal header file names consistenttb2022-11-261-0/+94
Libcrypto currently has a mess of *_lcl.h, *_locl.h, and *_local.h names used for internal headers. Move all these headers we inherited from OpenSSL to *_local.h, reserving the name *_internal.h for our own code. Similarly, move dtls_locl.h and ssl_locl.h to dtls_local and ssl_local.h. constant_time_locl.h is moved to constant_time.h since it's special. Adjust all .c files in libcrypto, libssl and regress. The diff is mechanical with the exception of tls13_quic.c, where #include <ssl_locl.h> was fixed manually. discussed with jsing, no objection bcook