aboutsummaryrefslogtreecommitdiff
path: root/src/bun.js/bindings/webcrypto/CryptoKeyECOpenSSL.cpp
diff options
context:
space:
mode:
authorGravatar Dylan Conway <dylan.conway567@gmail.com> 2023-10-10 15:28:08 -0700
committerGravatar Dylan Conway <dylan.conway567@gmail.com> 2023-10-10 15:28:08 -0700
commitee2e34866e3bc0d12ba5cb1d5041524776472d71 (patch)
tree3f71bf8153545396ba38294f8577e77ce0b12439 /src/bun.js/bindings/webcrypto/CryptoKeyECOpenSSL.cpp
parente6d97f2581959d77a5b486faefbfdf094abedf9b (diff)
parent6301778a589254e2c3c0d95f768fce303f528b03 (diff)
downloadbun-ee2e34866e3bc0d12ba5cb1d5041524776472d71.tar.gz
bun-ee2e34866e3bc0d12ba5cb1d5041524776472d71.tar.zst
bun-ee2e34866e3bc0d12ba5cb1d5041524776472d71.zip
Merge branch 'main' into dylan/github-api-option
Diffstat (limited to 'src/bun.js/bindings/webcrypto/CryptoKeyECOpenSSL.cpp')
-rw-r--r--src/bun.js/bindings/webcrypto/CryptoKeyECOpenSSL.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/bun.js/bindings/webcrypto/CryptoKeyECOpenSSL.cpp b/src/bun.js/bindings/webcrypto/CryptoKeyECOpenSSL.cpp
index bb5dc5e62..c2b363b32 100644
--- a/src/bun.js/bindings/webcrypto/CryptoKeyECOpenSSL.cpp
+++ b/src/bun.js/bindings/webcrypto/CryptoKeyECOpenSSL.cpp
@@ -25,6 +25,7 @@
#include "config.h"
#include "CryptoKeyEC.h"
+#include "../wtf-bindings.h"
#if ENABLE(WEB_CRYPTO)
@@ -408,15 +409,15 @@ bool CryptoKeyEC::platformAddFieldElements(JsonWebKey& jwk) const
auto x = BIGNUMPtr(BN_new());
auto y = BIGNUMPtr(BN_new());
if (1 == EC_POINT_get_affine_coordinates_GFp(EC_KEY_get0_group(key), publicKey, x.get(), y.get(), ctx.get())) {
- jwk.x = base64URLEncodeToString(convertToBytesExpand(x.get(), keySizeInBytes));
- jwk.y = base64URLEncodeToString(convertToBytesExpand(y.get(), keySizeInBytes));
+ jwk.x = Bun::base64URLEncodeToString(convertToBytesExpand(x.get(), keySizeInBytes));
+ jwk.y = Bun::base64URLEncodeToString(convertToBytesExpand(y.get(), keySizeInBytes));
}
}
if (type() == Type::Private) {
const BIGNUM* privateKey = EC_KEY_get0_private_key(key);
if (privateKey)
- jwk.d = base64URLEncodeToString(convertToBytes(privateKey));
+ jwk.d = Bun::base64URLEncodeToString(convertToBytes(privateKey));
}
return true;
}