summary refs log tree commit diff
path: root/crypto/src/security/CipherUtilities.cs
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/src/security/CipherUtilities.cs')
-rw-r--r--crypto/src/security/CipherUtilities.cs5
1 files changed, 5 insertions, 0 deletions
diff --git a/crypto/src/security/CipherUtilities.cs b/crypto/src/security/CipherUtilities.cs
index de05bc9ef..eb10baec8 100644
--- a/crypto/src/security/CipherUtilities.cs
+++ b/crypto/src/security/CipherUtilities.cs
@@ -53,6 +53,7 @@ namespace Org.BouncyCastle.Security
             SEED,
             SERPENT,
             SKIPJACK,
+            SM4,
             TEA,
             THREEFISH_256,
             THREEFISH_512,
@@ -433,6 +434,9 @@ namespace Org.BouncyCastle.Security
                 case CipherAlgorithm.SKIPJACK:
                     blockCipher = new SkipjackEngine();
                     break;
+                case CipherAlgorithm.SM4:
+                    blockCipher = new SM4Engine();
+                    break;
                 case CipherAlgorithm.TEA:
                     blockCipher = new TeaEngine();
                     break;
@@ -740,6 +744,7 @@ namespace Org.BouncyCastle.Security
                 case CipherAlgorithm.SEED: return new SeedEngine();
                 case CipherAlgorithm.SERPENT: return new SerpentEngine();
                 case CipherAlgorithm.SKIPJACK: return new SkipjackEngine();
+                case CipherAlgorithm.SM4: return new SM4Engine();
                 case CipherAlgorithm.TEA: return new TeaEngine();
                 case CipherAlgorithm.THREEFISH_256: return new ThreefishEngine(ThreefishEngine.BLOCKSIZE_256);
                 case CipherAlgorithm.THREEFISH_512: return new ThreefishEngine(ThreefishEngine.BLOCKSIZE_512);