Comparing version 0.4.3 to 0.5.0
'use strict' | ||
module.exports = { | ||
es256k: require('./signing-algorithms/secp256k1') | ||
ES256K: require('./signing-algorithms/secp256k1') | ||
} |
@@ -14,3 +14,3 @@ 'use strict' | ||
} | ||
signingAlgorithm = signingAlgorithm.toLowerCase() | ||
signingAlgorithm = signingAlgorithm.toUpperCase() | ||
if (!CryptoClients.hasOwnProperty(signingAlgorithm)) { | ||
@@ -17,0 +17,0 @@ throw 'invalid signing algorithm' |
@@ -11,3 +11,3 @@ 'use strict' | ||
SECP256K1Client.algorithmName = 'ES256' | ||
SECP256K1Client.algorithmName = 'ES256K' | ||
@@ -14,0 +14,0 @@ var ec = new EC('secp256k1') |
@@ -14,3 +14,3 @@ 'use strict' | ||
} | ||
signingAlgorithm = signingAlgorithm.toLowerCase() | ||
signingAlgorithm = signingAlgorithm.toUpperCase() | ||
if (!CryptoClients.hasOwnProperty(signingAlgorithm)) { | ||
@@ -17,0 +17,0 @@ throw 'invalid signing algorithm' |
{ | ||
"name": "jwt-js", | ||
"version": "0.4.3", | ||
"version": "0.5.0", | ||
"description": "node.js library for encoding, decoding, and verifying JSON Web Tokens (JWTs)", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
# JSON Web Token JS | ||
[![CircleCI](https://circleci.com/gh/blockstack/jwt-js.png?style=shield&circle-token=:circle-token)](https://circleci.com/gh/blockstack/jwt-js) | ||
[![npm](https://img.shields.io/npm/l/jwt-js.svg)](https://www.npmjs.com/package/jwt-js) | ||
[![npm](https://img.shields.io/npm/v/jwt-js.svg)](https://www.npmjs.com/package/jwt-js) | ||
[![npm](https://img.shields.io/npm/dm/jwt-js.svg)](https://www.npmjs.com/package/jwt-js) | ||
[![Slack](http://slack.blockstack.org/badge.svg)](http://slack.blockstack.org/) | ||
[![](https://nodei.co/npm/jwt-js.png?downloads=true)](https://www.npmjs.com/package/jwt-js) | ||
node.js library for signing, decoding, and verifying JSON Web Tokens (JWTs) | ||
@@ -9,0 +10,0 @@ |
@@ -14,3 +14,3 @@ 'use strict' | ||
sampleDecodedToken = { | ||
header: { typ: 'JWT', alg: 'ES256' }, | ||
header: { typ: 'JWT', alg: 'ES256K' }, | ||
payload: | ||
@@ -30,3 +30,3 @@ { issuedAt: '1440713414.85', | ||
var tokenSigner = new TokenSigner('ES256k', rawPrivateKey) | ||
var tokenSigner = new TokenSigner('ES256K', rawPrivateKey) | ||
t.ok(tokenSigner, 'token signer should have been created') | ||
@@ -46,3 +46,3 @@ | ||
var tokenVerifier = new TokenVerifier('ES256k', rawPublicKey) | ||
var tokenVerifier = new TokenVerifier('ES256K', rawPublicKey) | ||
t.ok(tokenVerifier, 'token verifier should have been created') | ||
@@ -49,0 +49,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
15568
70