Skip to content

Implement WebAssembly cryptographic sandboxing for client signing #419

Description

@Fatimasanusi

Description

Handling private keys or complex cryptographic hashing directly in JavaScript exposes the client to memory scraping and XSS vulnerabilities.

Architecture & Context

To secure fractional asset redemptions, sensitive cryptographic operations must be isolated within a WebAssembly (Wasm) sandbox. The frontend should load a Rust-compiled Wasm module to handle signature verification and hash generation securely.

Technical Requirements

  • Compile a minimal Rust cryptographic module to Wasm.
  • Load the Wasm module asynchronously within the Next.js frontend.
  • Expose secure signature verification functions to the TypeScript layer.

Acceptance Criteria

  • Cryptographic operations execute strictly within the Wasm context.
  • Wasm bundle size is optimized to under 500KB.
  • Signature generation time is benchmarked to be faster than native JS.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions