From 6690332718232f5d2a7a3a7b96cd3daf6129f084 Mon Sep 17 00:00:00 2001 From: Bernd Schoolmann Date: Mon, 11 Nov 2024 14:02:00 +0100 Subject: [PATCH] Fix --- crates/bitwarden-wasm-internal/build.sh | 4 ++-- crates/bitwarden-wasm-internal/src/crypto.rs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/crates/bitwarden-wasm-internal/build.sh b/crates/bitwarden-wasm-internal/build.sh index bd62cf02..2555880f 100755 --- a/crates/bitwarden-wasm-internal/build.sh +++ b/crates/bitwarden-wasm-internal/build.sh @@ -4,12 +4,12 @@ cd ../../ if [ "$1" != "-r" ]; then # Dev - cargo build -p bitwarden-wasm-internal --target wasm32-unknown-unknown -Ctarget-feature=+simd128 + cargo build -p bitwarden-wasm-internal --target wasm32-unknown-unknown wasm-bindgen --target bundler --out-dir languages/js/sdk-internal ./target/wasm32-unknown-unknown/debug/bitwarden_wasm_internal.wasm wasm-bindgen --target nodejs --out-dir languages/js/sdk-internal/node ./target/wasm32-unknown-unknown/debug/bitwarden_wasm_internal.wasm else # Release - RUSTFLAGS=-Ctarget-feature=+simd128 cargo build -p bitwarden-wasm-internal --target wasm32-unknown-unknown --release + cargo build -p bitwarden-wasm-internal --target wasm32-unknown-unknown --release wasm-bindgen --target bundler --out-dir languages/js/sdk-internal ./target/wasm32-unknown-unknown/release/bitwarden_wasm_internal.wasm wasm-bindgen --target nodejs --out-dir languages/js/sdk-internal/node ./target/wasm32-unknown-unknown/release/bitwarden_wasm_internal.wasm fi diff --git a/crates/bitwarden-wasm-internal/src/crypto.rs b/crates/bitwarden-wasm-internal/src/crypto.rs index a25cf6c5..c0351242 100644 --- a/crates/bitwarden-wasm-internal/src/crypto.rs +++ b/crates/bitwarden-wasm-internal/src/crypto.rs @@ -126,8 +126,8 @@ impl ClientCrypto { Ok(signature) } - pub fn verify_ed25519(data: Vec, signature: Vec, public: Vec) -> Result { - let res = bitwarden_crypto::ed25519::verify(data, signature, public)?; + pub fn verify_ed25519(data: Vec, signature: Vec, public_key: Vec) -> Result { + let res = bitwarden_crypto::ed25519::verify(data, signature, public_key)?; Ok(res) }