summary refs log tree commit diff
diff options
context:
space:
mode:
authorPeter Dettman <peter.dettman@bouncycastle.org>2022-09-28 12:50:16 +0700
committerPeter Dettman <peter.dettman@bouncycastle.org>2022-09-28 12:50:16 +0700
commitf17136e7a29a758a4148b23ffab5198dc0a09328 (patch)
treef82173b07a0791b110755a692bbe427c6acf15ba
parent(D)TLS: RFC 7250 Raw Public Keys (diff)
downloadBouncyCastle.NET-ed25519-f17136e7a29a758a4148b23ffab5198dc0a09328.tar.xz
Use AesUtilities
-rw-r--r--crypto/src/pqc/crypto/frodo/FrodoMatrixGenerator.cs2
-rw-r--r--crypto/src/pqc/crypto/ntruprime/NtruPrimeEngine.cs2
2 files changed, 2 insertions, 2 deletions
diff --git a/crypto/src/pqc/crypto/frodo/FrodoMatrixGenerator.cs b/crypto/src/pqc/crypto/frodo/FrodoMatrixGenerator.cs
index ffd7727b3..01f1016a7 100644
--- a/crypto/src/pqc/crypto/frodo/FrodoMatrixGenerator.cs
+++ b/crypto/src/pqc/crypto/frodo/FrodoMatrixGenerator.cs
@@ -67,7 +67,7 @@ namespace Org.BouncyCastle.Pqc.Crypto.Frodo
             public Aes128MatrixGenerator(int n, int q)
                 : base(n, q)
             {
-                cipher = new BufferedBlockCipher(new AesEngine());
+                cipher = new BufferedBlockCipher(AesUtilities.CreateEngine());
 
             }
 
diff --git a/crypto/src/pqc/crypto/ntruprime/NtruPrimeEngine.cs b/crypto/src/pqc/crypto/ntruprime/NtruPrimeEngine.cs
index 2302e0c4b..64e4e19fc 100644
--- a/crypto/src/pqc/crypto/ntruprime/NtruPrimeEngine.cs
+++ b/crypto/src/pqc/crypto/ntruprime/NtruPrimeEngine.cs
@@ -916,7 +916,7 @@ namespace Org.BouncyCastle.Pqc.Crypto.NtruPrime
             uint[] L_uint = new uint[_p];
 
             // AES256 CTR
-            BufferedBlockCipher cipher = new BufferedBlockCipher(new SicBlockCipher(new AesEngine()));
+            BufferedBlockCipher cipher = new BufferedBlockCipher(new SicBlockCipher(AesUtilities.CreateEngine()));
             KeyParameter kp = new KeyParameter(k);
             cipher.Init(true, new ParametersWithIV(kp, new byte[16]));
             int len = cipher.ProcessBytes(cipherInput, 0, 4 * _p, L, 0);