Skip to content

Commit

Permalink
verifier: Update README.md to make example commands useful.
Browse files Browse the repository at this point in the history
  • Loading branch information
flihp committed Dec 7, 2023
1 parent ad57d0b commit 65fa28c
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions verifier/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ past attestations produced using the same nonce.

```shell
$ dd if=/dev/urandom of=nonce.bin bs=32 count=1
$ cargo run --package verifier -- get attestation nonce.bin > attestation.bin
$ cargo run --package verifier -- attest nonce.bin > attestation.bin
```

We prove the attestation includes the nonce using a mechanism described in the
Expand All @@ -43,7 +43,7 @@ guarantees and so we cannot trust any analysis of it until we've established a
basis for trusting its accuracy.

```shell
$ cargo run --package verifier -- get log > log.bin
$ cargo run --package verifier -- log > log.bin
```

An attestation is a detached signature over the measurement log. By verifying
Expand All @@ -52,8 +52,8 @@ attestation at the same time by including the nonce in the signed data as the
RoT does:

```shell
$ cargo run --package verifier -- get cert --index 0 > alias.pem
$ cargo run --package verifier -- verify attestation --alias_cert alias.pem --log log.bin --nonce nonce.bin attestation.bin
$ cargo run --package verifier -- cert --index 0 > alias.pem
$ cargo run --package verifier -- verify-attestation --alias_cert alias.pem --log log.bin --nonce nonce.bin attestation.bin
```

The signature verification boils down to:
Expand All @@ -70,6 +70,6 @@ the key used to sign the attestation for the purpose of attestation. We do so
by first establishing trust in the certificate chain from the RoT:

```shell
$ cargo run --package verifier -- get cert-chain > cert-chain.pem
$ cargo run --package verifier -- verify cert-chain --ca-cert ca-root.pem cert-chain.pem
$ cargo run --package verifier -- cert-chain > cert-chain.pem
$ cargo run --package verifier -- verify-cert-chain --ca-cert ca-root.pem cert-chain.pem
```

0 comments on commit 65fa28c

Please sign in to comment.