From 5b148089c3b1344081a1fbd79bbb611e3c51ef1e Mon Sep 17 00:00:00 2001 From: Daniel Huigens Date: Mon, 27 Apr 2020 21:37:51 +0200 Subject: [PATCH] Switch to ES8 build of asmcrypto.js --- src/crypto/cfb.js | 2 +- src/crypto/cipher/aes.js | 2 +- src/crypto/cmac.js | 2 +- src/crypto/eax.js | 2 +- src/crypto/gcm.js | 2 +- src/crypto/hash/index.js | 4 ++-- src/packet/public_key.js | 4 ++-- 7 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/crypto/cfb.js b/src/crypto/cfb.js index afaa25a3..b5ddbf9f 100644 --- a/src/crypto/cfb.js +++ b/src/crypto/cfb.js @@ -24,7 +24,7 @@ * @module crypto/cfb */ -import { AES_CFB } from 'asmcrypto.js/dist_es5/aes/cfb'; +import { AES_CFB } from 'asmcrypto.js/dist_es8/aes/cfb'; import stream from 'web-stream-tools'; import cipher from './cipher'; diff --git a/src/crypto/cipher/aes.js b/src/crypto/cipher/aes.js index 9a82dbb8..ff389480 100644 --- a/src/crypto/cipher/aes.js +++ b/src/crypto/cipher/aes.js @@ -2,7 +2,7 @@ * @requires asmcrypto.js */ -import { AES_ECB } from 'asmcrypto.js/dist_es5/aes/ecb'; +import { AES_ECB } from 'asmcrypto.js/dist_es8/aes/ecb'; // TODO use webCrypto or nodeCrypto when possible. function aes(length) { diff --git a/src/crypto/cmac.js b/src/crypto/cmac.js index e6ce66c1..3eda17ea 100644 --- a/src/crypto/cmac.js +++ b/src/crypto/cmac.js @@ -6,7 +6,7 @@ * @module crypto/cmac */ -import { AES_CBC } from 'asmcrypto.js/dist_es5/aes/cbc'; +import { AES_CBC } from 'asmcrypto.js/dist_es8/aes/cbc'; import util from '../util'; const webCrypto = util.getWebCrypto(); diff --git a/src/crypto/eax.js b/src/crypto/eax.js index 0844b8af..e59cf3ff 100644 --- a/src/crypto/eax.js +++ b/src/crypto/eax.js @@ -24,7 +24,7 @@ * @module crypto/eax */ -import { AES_CTR } from 'asmcrypto.js/dist_es5/aes/ctr'; +import { AES_CTR } from 'asmcrypto.js/dist_es8/aes/ctr'; import CMAC from './cmac'; import util from '../util'; diff --git a/src/crypto/gcm.js b/src/crypto/gcm.js index f028c3b0..64b75567 100644 --- a/src/crypto/gcm.js +++ b/src/crypto/gcm.js @@ -23,7 +23,7 @@ * @module crypto/gcm */ -import { AES_GCM } from 'asmcrypto.js/dist_es5/aes/gcm'; +import { AES_GCM } from 'asmcrypto.js/dist_es8/aes/gcm'; import util from '../util'; const webCrypto = util.getWebCrypto(); // no GCM support in IE11, Safari 9 diff --git a/src/crypto/hash/index.js b/src/crypto/hash/index.js index f5a695f3..aeefce36 100644 --- a/src/crypto/hash/index.js +++ b/src/crypto/hash/index.js @@ -11,8 +11,8 @@ * @module crypto/hash */ -import { Sha1 } from 'asmcrypto.js/dist_es5/hash/sha1/sha1'; -import { Sha256 } from 'asmcrypto.js/dist_es5/hash/sha256/sha256'; +import { Sha1 } from 'asmcrypto.js/dist_es8/hash/sha1/sha1'; +import { Sha256 } from 'asmcrypto.js/dist_es8/hash/sha256/sha256'; import sha224 from 'hash.js/lib/hash/sha/224'; import sha384 from 'hash.js/lib/hash/sha/384'; import sha512 from 'hash.js/lib/hash/sha/512'; diff --git a/src/packet/public_key.js b/src/packet/public_key.js index 7323c390..3401baa7 100644 --- a/src/packet/public_key.js +++ b/src/packet/public_key.js @@ -24,8 +24,8 @@ * @requires util */ -import { Sha1 } from 'asmcrypto.js/dist_es5/hash/sha1/sha1'; -import { Sha256 } from 'asmcrypto.js/dist_es5/hash/sha256/sha256'; +import { Sha1 } from 'asmcrypto.js/dist_es8/hash/sha1/sha1'; +import { Sha256 } from 'asmcrypto.js/dist_es8/hash/sha256/sha256'; import type_keyid from '../type/keyid'; import type_mpi from '../type/mpi'; import config from '../config';