@velocitycareerlabs/server-webwallet 1.27.0-dev-build.1472cc275 → 1.27.0-dev-build.142d72c39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@velocitycareerlabs/server-webwallet",
|
|
3
|
-
"version": "1.27.0-dev-build.
|
|
3
|
+
"version": "1.27.0-dev-build.142d72c39",
|
|
4
4
|
"description": "Web Wallet application",
|
|
5
5
|
"repository": "https://github.com/velocitycareerlabs/packages",
|
|
6
6
|
"engines": {
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"@fastify/swagger": "^9.0.0",
|
|
33
33
|
"@fastify/swagger-ui": "^5.0.0",
|
|
34
34
|
"@spencejs/spence-mongo-repos": "^0.10.2",
|
|
35
|
-
"@velocitycareerlabs/migrations": "1.27.0-dev-build.
|
|
35
|
+
"@velocitycareerlabs/migrations": "1.27.0-dev-build.142d72c39",
|
|
36
36
|
"@verii/auth": "1.1.0-pre.1771382986",
|
|
37
37
|
"@verii/common-functions": "1.1.0-pre.1771382986",
|
|
38
38
|
"@verii/common-schemas": "1.1.0-pre.1771382986",
|
|
@@ -72,5 +72,5 @@
|
|
|
72
72
|
"nodemon": "3.1.13",
|
|
73
73
|
"prettier": "3.8.1"
|
|
74
74
|
},
|
|
75
|
-
"gitHead": "
|
|
75
|
+
"gitHead": "cd324e82e914e237970bc639ef61dd210750c262"
|
|
76
76
|
}
|
|
@@ -32,7 +32,6 @@ const JwtSignServiceImpl = (context) => {
|
|
|
32
32
|
};
|
|
33
33
|
|
|
34
34
|
const KeyKeyId = 'keyId';
|
|
35
|
-
const KeyJwk = 'jwk';
|
|
36
35
|
const KeyKid = 'kid';
|
|
37
36
|
const KeyIss = 'iss';
|
|
38
37
|
const KeyAud = 'aud';
|
|
@@ -46,7 +45,6 @@ const KeyPayload = 'payload';
|
|
|
46
45
|
const generateJwtPayloadToSign = (jwtDescriptor, nonce, didJwk) => {
|
|
47
46
|
const header = didJwk
|
|
48
47
|
? {
|
|
49
|
-
[KeyJwk]: didJwk.publicJwk.valueJson,
|
|
50
48
|
[KeyKid]: didJwk.kid,
|
|
51
49
|
}
|
|
52
50
|
: {};
|
|
@@ -38,7 +38,24 @@ describe('sign service implementation test', () => {
|
|
|
38
38
|
|
|
39
39
|
it('should sign payload successfully', async () => {
|
|
40
40
|
const nockedRequest = nock(fastify.config.careerWalletUrl)
|
|
41
|
-
.post('/api/v0.6/jwt/sign')
|
|
41
|
+
.post('/api/v0.6/jwt/sign', (body) => {
|
|
42
|
+
expect(body).toEqual({
|
|
43
|
+
header: {
|
|
44
|
+
kid: DidJwkMocks.DidJwk.kid,
|
|
45
|
+
},
|
|
46
|
+
payload: {
|
|
47
|
+
...OriginalPayload,
|
|
48
|
+
nonce: 'nonce123',
|
|
49
|
+
aud: 'aud123',
|
|
50
|
+
jti: 'jti123',
|
|
51
|
+
iss: 'iss123',
|
|
52
|
+
},
|
|
53
|
+
options: {
|
|
54
|
+
keyId: DidJwkMocks.DidJwk.keyId,
|
|
55
|
+
},
|
|
56
|
+
});
|
|
57
|
+
return true;
|
|
58
|
+
})
|
|
42
59
|
.reply(200, JwtResponseMock);
|
|
43
60
|
|
|
44
61
|
const jwt = await subject.sign(
|