diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2023-10-23 20:05:22 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2023-10-23 20:05:22 +0700 |
commit | e9b60023b5a5e21395c9d43080eaba0455e257fb (patch) | |
tree | db6f0208eddd01eab6e9aef9ee191aab712e4561 /crypto/src/pqc | |
parent | additional EC regression test (diff) | |
download | BouncyCastle.NET-ed25519-e9b60023b5a5e21395c9d43080eaba0455e257fb.tar.xz |
Clean up warnings
Diffstat (limited to 'crypto/src/pqc')
-rw-r--r-- | crypto/src/pqc/crypto/sphincsplus/SPHINCSPlusParameters.cs | 2 | ||||
-rw-r--r-- | crypto/src/pqc/crypto/utils/PqcPublicKeyFactory.cs | 2 | ||||
-rw-r--r-- | crypto/src/pqc/crypto/utils/PqcUtilities.cs | 2 |
3 files changed, 5 insertions, 1 deletions
diff --git a/crypto/src/pqc/crypto/sphincsplus/SPHINCSPlusParameters.cs b/crypto/src/pqc/crypto/sphincsplus/SPHINCSPlusParameters.cs index 4fbd62735..40e7059bf 100644 --- a/crypto/src/pqc/crypto/sphincsplus/SPHINCSPlusParameters.cs +++ b/crypto/src/pqc/crypto/sphincsplus/SPHINCSPlusParameters.cs @@ -131,6 +131,7 @@ namespace Org.BouncyCastle.Pqc.Crypto.SphincsPlus static SphincsPlusParameters() { +#pragma warning disable CS0618 // Type or member is obsolete SphincsPlusParameters[] all = new SphincsPlusParameters[]{ SphincsPlusParameters.sha2_128f, SphincsPlusParameters.sha2_128s, SphincsPlusParameters.sha2_192f, SphincsPlusParameters.sha2_192s, @@ -151,6 +152,7 @@ namespace Org.BouncyCastle.Pqc.Crypto.SphincsPlus SphincsPlusParameters.haraka_192f_simple, SphincsPlusParameters.haraka_192s_simple, SphincsPlusParameters.haraka_256f_simple, SphincsPlusParameters.haraka_256s_simple, }; +#pragma warning restore CS0618 // Type or member is obsolete for (int i = 0; i < all.Length; ++i) { diff --git a/crypto/src/pqc/crypto/utils/PqcPublicKeyFactory.cs b/crypto/src/pqc/crypto/utils/PqcPublicKeyFactory.cs index 0b5cf0031..32321f30b 100644 --- a/crypto/src/pqc/crypto/utils/PqcPublicKeyFactory.cs +++ b/crypto/src/pqc/crypto/utils/PqcPublicKeyFactory.cs @@ -240,7 +240,7 @@ namespace Org.BouncyCastle.Pqc.Crypto.Utilities return new SphincsPlusPublicKeyParameters(spParams, Arrays.CopyOfRange(keyEnc, 4, keyEnc.Length)); } - catch (Exception e) + catch (Exception) { byte[] keyEnc = keyInfo.PublicKey.GetOctets(); diff --git a/crypto/src/pqc/crypto/utils/PqcUtilities.cs b/crypto/src/pqc/crypto/utils/PqcUtilities.cs index b7cac6203..f3097c721 100644 --- a/crypto/src/pqc/crypto/utils/PqcUtilities.cs +++ b/crypto/src/pqc/crypto/utils/PqcUtilities.cs @@ -215,6 +215,7 @@ namespace Org.BouncyCastle.Pqc.Crypto.Utilities hqcOids[HqcParameters.hqc192] = BCObjectIdentifiers.hqc192; hqcOids[HqcParameters.hqc256] = BCObjectIdentifiers.hqc256; +#pragma warning disable CS0618 // Type or member is obsolete sphincsPlusOids[SphincsPlusParameters.sha2_128s] = BCObjectIdentifiers.sphincsPlus_sha2_128s_r3; sphincsPlusOids[SphincsPlusParameters.sha2_128f] = BCObjectIdentifiers.sphincsPlus_sha2_128f_r3; sphincsPlusOids[SphincsPlusParameters.shake_128s] = BCObjectIdentifiers.sphincsPlus_shake_128s_r3; @@ -277,6 +278,7 @@ namespace Org.BouncyCastle.Pqc.Crypto.Utilities sphincsPlusParams[BCObjectIdentifiers.sphincsPlus_sha2_256f] = SphincsPlusParameters.sha2_256f_simple; sphincsPlusParams[BCObjectIdentifiers.sphincsPlus_shake_256s] = SphincsPlusParameters.shake_256s_simple; sphincsPlusParams[BCObjectIdentifiers.sphincsPlus_shake_256f] = SphincsPlusParameters.shake_256f_simple; +#pragma warning restore CS0618 // Type or member is obsolete } internal static DerObjectIdentifier McElieceOidLookup(CmceParameters parameters) |