ogar-encryption: own the wasm bindings on the argon2-0.6 envelope - #310
Merged
Merged
Conversation
The `wasm` feature used to forward ndarray encryption's wasm module, whose seal/open ran that crate's argon2-0.5 envelope. src/wasm.rs now exports the same seven functions over this crate's envelope (plus the re-exported sign and hash). The encryption dep is default-features = false so, with ndarray #333, argon2 0.5 leaves the tree. Fixes a doctest that imported encryption::kdf. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019HnekoM1EidTwQLS3oFVFm
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019HnekoM1EidTwQLS3oFVFm
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. Note Currently processing new changes in this PR. This may take a few minutes, please wait... ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Essentials Run ID: 📒 Files selected for processing (5)
✨ Finishing Touches📝 Generate docstrings
Comment |
Bugbot couldn't run - usage limit reachedBugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit. A user or team admin can review and increase usage limits in the Cursor dashboard. (requestId: serverGenReqId_c8f7b7ba-4809-4a06-af66-f277884659f2) |
Workspace-wide sweep: lance 12 / lancedb 0.39 (lancedb 0.39 requires lance =12.0.0 and still arrow ^58 / datafusion ^54, so those are unchanged). No member crate currently uses lance or lancedb; the workspace table moves so the next consumer starts on the current pair. rust-version follows rust-toolchain.toml (1.98.1). cargo +1.98.1 check --workspace --all-targets: clean. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019HnekoM1EidTwQLS3oFVFm
AdaWorldAPI
marked this pull request as ready for review
September 25, 2026 01:43
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
src/wasm.rs(new, featurewasm). Browser bindings owned by this crate, exporting the same seven functions as ndarrayencryption'swasmmodule:seal_envelope,open_envelopegenerate_signing_seed,public_key_of,sign_message,verify_signaturesha384seal_envelopeandopen_envelopenow run this crate's own envelope, which uses argon2 0.6 from thepassword-hashesfork. Before this change thewasmfeature re-exportedencryption::wasm, whose seal/open ran argon2 0.5.Features.
wasm = ["dep:wasm-bindgen"]replaceswasm = ["encryption/wasm-bindings"].ndarray dependency.
encryptionis nowdefault-features = false. Together with ndarray #333 this drops that crate's argon2-0.5 KDF and envelope, which this crate never used.Doctest fix. The
kdf.rsdoctest importedencryption::kdf; it now importsogar_encryption::kdf.Ordering
This PR is safe to merge before or after ndarray #333. On current ndarray master,
default-features = falsechanges nothing (that crate's default is[]), so argon2 0.5.3 stays in the tree until #333 lands.Verification
Tests pass for both
cargo +1.98.1 test -p ogar-encryptionandcargo +1.98.1 test -p ogar-encryption --features wasm: 18 passed, 1 ignored, plus 1 doctest.The other checks pass with the fmt fixup commit:
cargo check -p ogar-encryption --features wasm --target wasm32-unknown-unknowncargo clippy -p ogar-encryption --features wasm --all-targets -- -D warningscargo fmt --checkDependency tree for
-p ogar-encryption --features wasm:The tests were also rerun against the #333 branch and pass.
Consumers are unaffected: a2ui-rs and MedCare-rs use
ogar_encryption::{kdf, KdfParams, seal, open}, and none of them enables thewasmfeature.🤖 Generated with Claude Code
https://claude.ai/code/session_019HnekoM1EidTwQLS3oFVFm
Generated by Claude Code
Summary by CodeRabbit