You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Can't resolve 'zlib' in /node_modules/node-jose/lib/jwe/encrypt.js and /node_modules/node-jose/lib/jwe/decrypt.js #257
I included jose.JWK.asKey() into our progrem, as:
jose.JWK.asKey({
'kty': 'oct',
'use': 'enc',
'k': name,
'alg': 'password'
})
.then(key => {
jose.JWE.createDecrypt(key)
.decrypt(token)
.then(result => {
const claims = new TextDecoder().decode(result.plaintext);
sessionStorage.setItem('detail', claims);
});
});
but I get a error as
ERROR in ./node_modules/node-jose/lib/jwe/encrypt.js
Module not found: Error: Can't resolve 'zlib' in '/Users/projectName/node_modules/node-jose/lib/jwe'
ERROR in ./node_modules/node-jose/lib/jwe/decrypt.js
Module not found: Error: Can't resolve 'zlib' in '/Users/projectName/node_modules/node-jose/lib/jwe'
Activity
CristianDallos commentedon Apr 4, 2019
I have the same problem in angular app, when I change version: 5.2 to 7.
CristianDallos commentedon Apr 6, 2019
Hello, maybe it's helpful, I was reviewing and I found that the problem occurs when uploading the CLI version in angular, 1.7.x to 6.
jkroepke commentedon Apr 20, 2019
Workaround: VadimDez/ng2-pdf-viewer#322 (comment)
NewtonJoshua commentedon Aug 29, 2019
Hi,
This PR will fix this issue #264
It is published to https://www.npmjs.com/package/node-jose-browserify