summaryrefslogtreecommitdiffhomepage
path: root/example/index.js
diff options
context:
space:
mode:
authorMatthew Miller <matthew@millerti.me>2020-05-22 12:41:05 -0700
committerMatthew Miller <matthew@millerti.me>2020-05-22 12:41:05 -0700
commit6a8393f8d2d9e0857ae773f482aa7c89cd3548d8 (patch)
tree7e50f80419a7b7332cd0275727d6aa569aebc483 /example/index.js
parent40fc370e2babab0cafffb19d37d170a2e06ee46f (diff)
Add attestation response verification
Diffstat (limited to 'example/index.js')
-rw-r--r--example/index.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/example/index.js b/example/index.js
index af0c65a..8fe64a3 100644
--- a/example/index.js
+++ b/example/index.js
@@ -43,7 +43,9 @@ app.get('/generate-attestation-options', (req, res) => {
app.post('/verify-attestation', (req, res) => {
const { body } = req;
- console.log('verifying:', body);
+ const verification = verifyAttestationResponse(body, `https://${origin}`);
+
+ res.send({ verified: verification.verified });
});
app.post('/verify-registration', (req, res) => {