@connectedcars/jwtutils
Advanced tools
Comparing version 1.0.7 to 1.0.8
{ | ||
"name": "@connectedcars/jwtutils", | ||
"version": "1.0.7", | ||
"version": "1.0.8", | ||
"description": "Zero dependency JWT encoding/decoding for Node", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -143,3 +143,3 @@ 'use strict' | ||
'to throw', | ||
'Unknown audience' | ||
`Unknown audience 'https://host/oauth/token'` | ||
) | ||
@@ -240,3 +240,3 @@ }) | ||
'to throw', | ||
'Unknown pubkey id for this issuer' | ||
`Unknown pubkey id '3' for this issuer` | ||
) | ||
@@ -253,3 +253,3 @@ }) | ||
'to throw', | ||
'Signature verification failed with alg RS256' | ||
`Signature verification failed with alg 'RS256'` | ||
) | ||
@@ -256,0 +256,0 @@ }) |
@@ -143,3 +143,3 @@ const express = require('express') | ||
statusCode: 401, | ||
data: 'Unknown pubkey id for this issuer' | ||
data: `Unknown pubkey id '2' for this issuer` | ||
}) | ||
@@ -146,0 +146,0 @@ }) |
@@ -73,3 +73,5 @@ 'use strict' | ||
if (!pubkey) { | ||
throw new JwtVerifyError('Unknown pubkey id for this issuer') | ||
throw new JwtVerifyError( | ||
`Unknown pubkey id '${header.kid}' for this issuer` | ||
) | ||
} | ||
@@ -79,3 +81,3 @@ | ||
throw new JwtVerifyError( | ||
`Signature verification failed with alg ${header.alg}` | ||
`Signature verification failed with alg '${header.alg}'` | ||
) | ||
@@ -86,3 +88,3 @@ } | ||
if (!auds.some(aud => audiences.includes(aud))) { | ||
throw new JwtVerifyError('Unknown audience') | ||
throw new JwtVerifyError(`Unknown audience '${auds.join(',')}'`) | ||
} | ||
@@ -89,0 +91,0 @@ |
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
55436
1234