Skip to content

Commit

Permalink
feat(wasm): expose presentation verifying key
Browse files Browse the repository at this point in the history
  • Loading branch information
sinui0 committed Oct 2, 2024
1 parent 7de49c8 commit 6be7494
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions crates/wasm/src/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,11 @@ pub struct Presentation(tlsn_core::presentation::Presentation);

#[wasm_bindgen]
impl Presentation {
/// Returns the verifying key.
pub fn verifying_key(&self) -> VerifyingKey {
self.0.verifying_key().into()
}

/// Verifies the presentation.
pub fn verify(&self) -> Result<PresentationOutput, JsError> {
let provider = CryptoProvider::default();
Expand Down

0 comments on commit 6be7494

Please sign in to comment.