diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2024-01-20 17:55:07 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2024-01-20 17:55:07 +0700 |
commit | 27c1d7797c79cd799ba04132e0d4b571de509e24 (patch) | |
tree | c8ff0d7c6d188841553b08e2561a267488d917bb /crypto/src/asn1 | |
parent | Align sig alg checks in X509Certificate, X509Crl (diff) | |
download | BouncyCastle.NET-ed25519-27c1d7797c79cd799ba04132e0d4b571de509e24.tar.xz |
Overhaul algorithm registries
Diffstat (limited to 'crypto/src/asn1')
-rw-r--r-- | crypto/src/asn1/smime/SMIMECapabilities.cs | 8 | ||||
-rw-r--r-- | crypto/src/asn1/smime/SMIMECapability.cs | 3 |
2 files changed, 7 insertions, 4 deletions
diff --git a/crypto/src/asn1/smime/SMIMECapabilities.cs b/crypto/src/asn1/smime/SMIMECapabilities.cs index 0142f0797..47710d9cb 100644 --- a/crypto/src/asn1/smime/SMIMECapabilities.cs +++ b/crypto/src/asn1/smime/SMIMECapabilities.cs @@ -1,7 +1,9 @@ using System; using System.Collections.Generic; +using Org.BouncyCastle.Asn1.Misc; using Org.BouncyCastle.Asn1.Nist; +using Org.BouncyCastle.Asn1.Oiw; using Org.BouncyCastle.Asn1.Pkcs; using Org.BouncyCastle.Asn1.X509; @@ -28,9 +30,9 @@ namespace Org.BouncyCastle.Asn1.Smime public static readonly DerObjectIdentifier Aes256Cbc = NistObjectIdentifiers.IdAes256Cbc; public static readonly DerObjectIdentifier Aes192Cbc = NistObjectIdentifiers.IdAes192Cbc; public static readonly DerObjectIdentifier Aes128Cbc = NistObjectIdentifiers.IdAes128Cbc; - public static readonly DerObjectIdentifier IdeaCbc = new DerObjectIdentifier("1.3.6.1.4.1.188.7.1.1.2"); - public static readonly DerObjectIdentifier Cast5Cbc = new DerObjectIdentifier("1.2.840.113533.7.66.10"); - public static readonly DerObjectIdentifier DesCbc = new DerObjectIdentifier("1.3.14.3.2.7"); + public static readonly DerObjectIdentifier IdeaCbc = MiscObjectIdentifiers.as_sys_sec_alg_ideaCBC; + public static readonly DerObjectIdentifier Cast5Cbc = MiscObjectIdentifiers.cast5CBC; + public static readonly DerObjectIdentifier DesCbc = OiwObjectIdentifiers.DesCbc; public static readonly DerObjectIdentifier DesEde3Cbc = PkcsObjectIdentifiers.DesEde3Cbc; public static readonly DerObjectIdentifier RC2Cbc = PkcsObjectIdentifiers.RC2Cbc; diff --git a/crypto/src/asn1/smime/SMIMECapability.cs b/crypto/src/asn1/smime/SMIMECapability.cs index 9b30c6dba..7b9255a46 100644 --- a/crypto/src/asn1/smime/SMIMECapability.cs +++ b/crypto/src/asn1/smime/SMIMECapability.cs @@ -1,6 +1,7 @@ using System; using Org.BouncyCastle.Asn1; +using Org.BouncyCastle.Asn1.Oiw; using Org.BouncyCastle.Asn1.Pkcs; namespace Org.BouncyCastle.Asn1.Smime @@ -18,7 +19,7 @@ namespace Org.BouncyCastle.Asn1.Smime /** * encryption algorithms preferences */ - public static readonly DerObjectIdentifier DesCbc = new DerObjectIdentifier("1.3.14.3.2.7"); + public static readonly DerObjectIdentifier DesCbc = OiwObjectIdentifiers.DesCbc; public static readonly DerObjectIdentifier DesEde3Cbc = PkcsObjectIdentifiers.DesEde3Cbc; public static readonly DerObjectIdentifier RC2Cbc = PkcsObjectIdentifiers.RC2Cbc; |