Contract cb448116044397df4dc3f0d87b2ef4957ca2c9fdfb0249b063bd8f9f9bd7eeb7

← Back to Index 📥 Download WASM

Meta

cliver 25.2.0#28484880988199233a7e8e87c97cb12dac323cb3
rssdk_spec_shaking 2
rssdkver 25.3.0#dcbea44513feb7734af6b6c4aced2c4a7a2715d0
rsver 1.94.1

Instances

  • CBDM3TH2BYEKP5TWZLYL7OL4RIAEC3TTRFBIJLQKFVMIQRMLOSWOFHER

Interface

Verify a WebAuthn signature against a message and public key.

Arguments

  • signature_payload - The message hash that was signed
  • key_data - Bytes containing:
  • 65-byte secp256r1 public key (uncompressed format)
  • Variable length credential ID (used on the client side)
  • sig_data - XDR-encoded WebAuthnSigData structure containing:
  • Authenticator data
  • Client data JSON
  • Signature components

Returns

  • true if the signature is valid
  • false otherwise
fn verify(
    env: soroban_sdk::Env,
    signature_payload: soroban_sdk::Bytes,
    key_data: soroban_sdk::Bytes,
    sig_data: soroban_sdk::Bytes,
) -> bool

Returns the canonical byte representation of a WebAuthn public key.

The canonical identity is the 65-byte uncompressed secp256r1 public key, stripping the variable-length credential ID suffix which is not part of the cryptographic identity.

Arguments

  • key_data - Bytes containing the 65-byte public key followed by an optional credential ID.
fn canonicalize_key(
    env: soroban_sdk::Env,
    key_data: soroban_sdk::Bytes,
) -> soroban_sdk::Bytes

Canonicalizes a batch of WebAuthn keys.

Arguments

  • keys_data - A vector with bytes containing the 65-byte public key followed by an optional credential ID.
fn batch_canonicalize_key(
    env: soroban_sdk::Env,
    keys_data: soroban_sdk::Vec,
) -> soroban_sdk::Vec

Imports

WebAssembly Text (WAT) ▶