Skip to content

Commit 271ac37

Browse files
authored
Fix example (#1033)
* fix: provide encoder secret to attestation * Add missing entry in example's README file
1 parent f69dd7a commit 271ac37

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

crates/examples/README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,7 @@ This folder contains examples demonstrating how to use the TLSNotary protocol.
44

55
* [Interactive](./interactive/README.md): Interactive Prover and Verifier session without a trusted notary.
66
* [Attestation](./attestation/README.md): Performing a simple notarization with a trusted notary.
7+
* [Interactive_zk](./interactive_zk/README.md): Interactive Prover and Verifier session demonstrating zero-knowledge age verification using Noir.
8+
79

810
Refer to <https://tlsnotary.org/docs/quick_start> for a quick start guide to using TLSNotary with these examples.

crates/examples/attestation/prove.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -322,6 +322,7 @@ async fn notary<S: AsyncWrite + AsyncRead + Send + Sync + Unpin + 'static>(
322322
let (
323323
VerifierOutput {
324324
transcript_commitments,
325+
encoder_secret,
325326
..
326327
},
327328
verifier,
@@ -382,6 +383,10 @@ async fn notary<S: AsyncWrite + AsyncRead + Send + Sync + Unpin + 'static>(
382383
.server_ephemeral_key(tls_transcript.server_ephemeral_key().clone())
383384
.transcript_commitments(transcript_commitments);
384385

386+
if let Some(encoder_secret) = encoder_secret {
387+
builder.encoder_secret(encoder_secret);
388+
}
389+
385390
let attestation = builder.build(&provider)?;
386391

387392
// Send attestation to prover.

0 commit comments

Comments
 (0)