From 03a74d3ecd1842ff6506c95fe966e136f1d41362 Mon Sep 17 00:00:00 2001 From: Mohammed Gadi Date: Mon, 16 Dec 2024 17:08:27 +0530 Subject: [PATCH] added issuersWhitelist to fast-jwt example --- README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 37b5020..0d7df14 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ const getJwks = buildGetJwks({ ttl: 60 * 1000, timeout: 5000, issuersWhitelist: ['https://example.com'], - checkIssuer: (issuer) => { + checkIssuer: issuer => { return issuer === 'https://example.com' }, providerDiscovery: false, @@ -101,6 +101,10 @@ const getJwks = buildGetJwks() fastify.register(fjwt, { decode: { complete: true }, + issuersWhitelist: ['https://example.com'], + checkIssuer: issuer => { + return issuer === 'https://example.com' + }, secret: (request, token, callback) => { const { header: { kid, alg },