You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

get-jwks

Package Overview
Dependencies
Maintainers
7
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

get-jwks - npm Package Compare versions

Comparing version

to
8.0.5

4

package.json
{
"name": "get-jwks",
"version": "8.0.4",
"version": "8.0.5",
"description": "Fetch utils for JWKS keys",

@@ -33,3 +33,3 @@ "main": "src/get-jwks.js",

"jwk-to-pem": "^2.0.4",
"lru-cache": "^8.0.0",
"lru-cache": "^9.0.0",
"node-fetch": "^2.6.1"

@@ -36,0 +36,0 @@ },

@@ -1,2 +0,2 @@

import LRU from 'lru-cache'
import type { LRUCache } from 'lru-cache'
import type { Agent } from 'https'

@@ -26,6 +26,6 @@

getJwksUri: (normalizedDomain: string) => Promise<string>
cache: LRU<string, JWK>
staleCache: LRU<string, JWK>
cache: LRUCache<string, JWK>
staleCache: LRUCache<string, JWK>
}
export default function buildGetJwks(options?: GetJwksOptions): GetJwks
'use strict'
const fetch = require('node-fetch')
const LRU = require('lru-cache')
const { LRUCache } = require('lru-cache')
const jwkToPem = require('jwk-to-pem')

@@ -26,4 +26,4 @@

const agent = options.agent || null
const staleCache = new LRU({ max: max * 2, ttl })
const cache = new LRU({
const staleCache = new LRUCache({ max: max * 2, ttl })
const cache = new LRUCache({
max,

@@ -30,0 +30,0 @@ ttl,

import { expectAssignable } from 'tsd'
import LRU from 'lru-cache'
import type { LRUCache } from 'lru-cache'
import buildGetJwks, { GetPublicKeyOptions, JWK, JWKSignature } from '../../src/get-jwks'

@@ -10,3 +10,3 @@

expectAssignable<(options?: GetPublicKeyOptions) => Promise<string>>(getPublicKey)
expectAssignable<LRU<string, JWK>>(cache)
expectAssignable<LRU<string, JWK>>(staleCache)
expectAssignable<LRUCache<string, JWK>>(cache)
expectAssignable<LRUCache<string, JWK>>(staleCache)

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet