@types/jsonwebtoken
Advanced tools
Comparing version 9.0.2 to 9.0.3
@@ -19,3 +19,3 @@ // Type definitions for jsonwebtoken 9.0 | ||
import { KeyObject } from 'crypto'; | ||
import { KeyObject } from "crypto"; | ||
@@ -119,7 +119,7 @@ export class JsonWebTokenError extends Error { | ||
cty?: string | undefined; | ||
crit?: Array<string | Exclude<keyof JwtHeader, 'crit'>> | undefined; | ||
crit?: Array<string | Exclude<keyof JwtHeader, "crit">> | undefined; | ||
kid?: string | undefined; | ||
jku?: string | undefined; | ||
x5u?: string | string[] | undefined; | ||
'x5t#S256'?: string | undefined; | ||
"x5t#S256"?: string | undefined; | ||
x5t?: string | undefined; | ||
@@ -149,11 +149,19 @@ x5c?: string | string[] | undefined; | ||
export type Algorithm = | ||
"HS256" | "HS384" | "HS512" | | ||
"RS256" | "RS384" | "RS512" | | ||
"ES256" | "ES384" | "ES512" | | ||
"PS256" | "PS384" | "PS512" | | ||
"none"; | ||
| "HS256" | ||
| "HS384" | ||
| "HS512" | ||
| "RS256" | ||
| "RS384" | ||
| "RS512" | ||
| "ES256" | ||
| "ES384" | ||
| "ES512" | ||
| "PS256" | ||
| "PS384" | ||
| "PS512" | ||
| "none"; | ||
export type SigningKeyCallback = ( | ||
error: Error | null, | ||
signingKey?: Secret | ||
signingKey?: Secret, | ||
) => void; | ||
@@ -163,3 +171,3 @@ | ||
header: JwtHeader, | ||
callback: SigningKeyCallback | ||
callback: SigningKeyCallback, | ||
) => void; | ||
@@ -224,3 +232,7 @@ | ||
export function verify(token: string, secretOrPublicKey: Secret, options: VerifyOptions & { complete: true }): Jwt; | ||
export function verify(token: string, secretOrPublicKey: Secret, options?: VerifyOptions & { complete?: false }): JwtPayload | string; | ||
export function verify( | ||
token: string, | ||
secretOrPublicKey: Secret, | ||
options?: VerifyOptions & { complete?: false }, | ||
): JwtPayload | string; | ||
export function verify(token: string, secretOrPublicKey: Secret, options?: VerifyOptions): Jwt | JwtPayload | string; | ||
@@ -227,0 +239,0 @@ |
{ | ||
"name": "@types/jsonwebtoken", | ||
"version": "9.0.2", | ||
"version": "9.0.3", | ||
"description": "TypeScript definitions for jsonwebtoken", | ||
@@ -80,4 +80,4 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/jsonwebtoken", | ||
}, | ||
"typesPublisherContentHash": "fbf5d1aac740ef64efb231322882351465fcb311accd6b41d154c87117bc3844", | ||
"typeScriptVersion": "4.3" | ||
"typesPublisherContentHash": "fc15f887c0b608ef3b24af14ff04ff74f798d49187cea3e6f00c9a3db3595ef8", | ||
"typeScriptVersion": "4.5" | ||
} |
@@ -11,3 +11,3 @@ # Installation | ||
### Additional Details | ||
* Last updated: Thu, 27 Apr 2023 07:32:45 GMT | ||
* Last updated: Fri, 15 Sep 2023 20:36:37 GMT | ||
* Dependencies: [@types/node](https://npmjs.com/package/@types/node) | ||
@@ -14,0 +14,0 @@ * Global values: none |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
14439
252