Switches to asmcrypto-lite for AES
This commit is contained in:
parent
be2c605e5b
commit
aba8a7a647
File diff suppressed because it is too large
Load Diff
|
@ -16,9 +16,9 @@ import blowfish from './blowfish.js';
|
|||
|
||||
export default {
|
||||
/** @see module:crypto/cipher/aes */
|
||||
aes128: aes[128],
|
||||
aes192: aes[192],
|
||||
aes256: aes[256],
|
||||
aes128: aes(128),
|
||||
aes192: aes(192),
|
||||
aes256: aes(256),
|
||||
/** @see module:crypto/cipher/des.originalDes */
|
||||
des: desModule.originalDes,
|
||||
/** @see module:crypto/cipher/des.des */
|
||||
|
|
|
@ -55,6 +55,7 @@ if(nodeCrypto) { // Use Node native crypto for all hash functions
|
|||
sha256: asmCrypto.SHA256.bytes,
|
||||
/** @see module:crypto/hash/sha.sha384 */
|
||||
sha384: sha.sha384,
|
||||
// TODO: compare sha512 in asmcrypto.js and jsSHA
|
||||
/** @see module:crypto/hash/sha.sha512 */
|
||||
sha512: sha.sha512,
|
||||
/** @see module:crypto/hash/ripe-md */
|
||||
|
|
|
@ -1594,7 +1594,6 @@ export default {
|
|||
sha384: function(str) {
|
||||
var shaObj = new jsSHA(str, "TYPED", "UTF8");
|
||||
return shaObj.getHash("SHA-384", "TYPED");
|
||||
|
||||
},
|
||||
/** SHA512 hash */
|
||||
sha512: function(str) {
|
||||
|
|
|
@ -270,6 +270,7 @@ describe('X25519 Cryptography', function () {
|
|||
var msg = openpgp.cleartext.readArmored(signed.data);
|
||||
// Verifying signed message
|
||||
return Promise.all([
|
||||
// FIXME this test sporadically fails
|
||||
openpgp.verify(
|
||||
{ message: msg, publicKeys: hi.toPublic() }
|
||||
).then(output => expect(output.signatures[0].valid).to.be.true),
|
||||
|
|
Loading…
Reference in New Issue
Block a user