@sd-jwt/decode
Advanced tools
Comparing version 0.3.2-next.94 to 0.3.2-next.95
{ | ||
"name": "@sd-jwt/decode", | ||
"version": "0.3.2-next.94+32af6cf", | ||
"version": "0.3.2-next.95+a2daee4", | ||
"description": "sd-jwt draft 7 implementation in typescript", | ||
@@ -40,7 +40,7 @@ "main": "dist/index.js", | ||
"devDependencies": { | ||
"@sd-jwt/crypto-nodejs": "0.3.2-next.94+32af6cf" | ||
"@sd-jwt/crypto-nodejs": "0.3.2-next.95+a2daee4" | ||
}, | ||
"dependencies": { | ||
"@sd-jwt/types": "0.3.2-next.94+32af6cf", | ||
"@sd-jwt/utils": "0.3.2-next.94+32af6cf" | ||
"@sd-jwt/types": "0.3.2-next.95+a2daee4", | ||
"@sd-jwt/utils": "0.3.2-next.95+a2daee4" | ||
}, | ||
@@ -63,3 +63,3 @@ "publishConfig": { | ||
}, | ||
"gitHead": "32af6cfa150fceb440fc9225bcaf2791a6aeee90" | ||
"gitHead": "a2daee4acc8def8b4d5871b36f740f0f5d50479d" | ||
} |
@@ -8,2 +8,3 @@ import { describe, expect, test } from 'vitest'; | ||
getClaimsSync, | ||
getSDAlgAndPayload, | ||
splitSdJwt, | ||
@@ -40,2 +41,10 @@ } from '../index'; | ||
test('split sdjwt without disclosures', () => { | ||
const sdjwt = 'h.p.s'; | ||
const { jwt, disclosures, kbJwt } = splitSdJwt(sdjwt); | ||
expect(jwt).toBe('h.p.s'); | ||
expect(disclosures).toStrictEqual([]); | ||
expect(kbJwt).toBeUndefined(); | ||
}); | ||
test('split sdjwt with kbjwt', () => { | ||
@@ -152,2 +161,7 @@ const sdjwt = 'h.p.s~d1~d2~kbh.kbp.kbs'; | ||
}); | ||
test('Test default sd hash algorithm', () => { | ||
const { _sd_alg, payload } = getSDAlgAndPayload({}); | ||
expect(_sd_alg).toBe('sha-256'); | ||
}); | ||
}); |
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
53598
1041