mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-23 09:48:56 +00:00
LibCrypto+LibWeb: De-templetize RSA and EC key types
There is no need to have `RSAPrivateKey`, `RSAPublicKey`, `ECPrivateKey` and `ECPublicKey` to be templatize to utilize different implementation of numbers.
This commit is contained in:
parent
7f44b88eea
commit
289f2b24bf
Notes:
github-actions[bot]
2025-06-25 00:23:30 +00:00
Author: https://github.com/devgianlu
Commit: 289f2b24bf
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4950
Reviewed-by: https://github.com/ADKaster
Reviewed-by: https://github.com/alimpfard
Reviewed-by: https://github.com/konradekk
Reviewed-by: https://github.com/shannonbooth
9 changed files with 113 additions and 122 deletions
|
@ -22,7 +22,7 @@ TEST_CASE(test_RSA_raw_encrypt)
|
|||
{
|
||||
ByteBuffer data { "hellohellohellohellohellohellohellohellohellohellohellohello123-"_b };
|
||||
u8 result[] { 0x6f, 0x7b, 0xe2, 0xd3, 0x95, 0xf8, 0x8d, 0x87, 0x6d, 0x10, 0x5e, 0xc3, 0xcd, 0xf7, 0xbb, 0xa6, 0x62, 0x8e, 0x45, 0xa0, 0xf1, 0xe5, 0x0f, 0xdf, 0x69, 0xcb, 0xb6, 0xd5, 0x42, 0x06, 0x7d, 0x72, 0xa9, 0x5e, 0xae, 0xbf, 0xbf, 0x0f, 0xe0, 0xeb, 0x31, 0x31, 0xca, 0x8a, 0x81, 0x1e, 0xb9, 0xec, 0x6d, 0xcc, 0xb8, 0xa4, 0xac, 0xa3, 0x31, 0x05, 0xa9, 0xac, 0xc9, 0xd3, 0xe6, 0x2a, 0x18, 0xfe };
|
||||
Crypto::PK::RSA rsa(Crypto::PK::RSAPublicKey<> {
|
||||
Crypto::PK::RSA rsa(Crypto::PK::RSAPublicKey {
|
||||
"8126832723025844890518845777858816391166654950553329127845898924164623511718747856014227624997335860970996746552094406240834082304784428582653994490504519"_bigint,
|
||||
"65537"_bigint,
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue