diff options
author | Peter Dettman <peter.dettman@bouncycastle.org> | 2020-07-17 22:07:12 +0700 |
---|---|---|
committer | Peter Dettman <peter.dettman@bouncycastle.org> | 2020-07-17 22:07:12 +0700 |
commit | 2db28a5b63aadd34fb3ef350d69eb4db4e4580b4 (patch) | |
tree | 119f0a21af644d1e5e2e2ba9ab4658f2fd69dcaf /crypto/src/security/PublicKeyFactory.cs | |
parent | Spelling (diff) | |
download | BouncyCastle.NET-ed25519-2db28a5b63aadd34fb3ef350d69eb4db4e4580b4.tar.xz |
Straighten out ECGOST3410NamedCurves
- deprecate/replace methods returning ECDomainParameters
Diffstat (limited to 'crypto/src/security/PublicKeyFactory.cs')
-rw-r--r-- | crypto/src/security/PublicKeyFactory.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/src/security/PublicKeyFactory.cs b/crypto/src/security/PublicKeyFactory.cs index 6813452a6..15af90f91 100644 --- a/crypto/src/security/PublicKeyFactory.cs +++ b/crypto/src/security/PublicKeyFactory.cs @@ -154,7 +154,7 @@ namespace Org.BouncyCastle.Security return new ECPublicKeyParameters("EC", q, (DerObjectIdentifier)para.Parameters); } - ECDomainParameters dParams = new ECDomainParameters(x9.Curve, x9.G, x9.N, x9.H, x9.GetSeed()); + ECDomainParameters dParams = new ECDomainParameters(x9); return new ECPublicKeyParameters(q, dParams); } else if (algOid.Equals(CryptoProObjectIdentifiers.GostR3410x2001)) @@ -162,7 +162,7 @@ namespace Org.BouncyCastle.Security Gost3410PublicKeyAlgParameters gostParams = Gost3410PublicKeyAlgParameters.GetInstance(algID.Parameters); DerObjectIdentifier publicKeyParamSet = gostParams.PublicKeyParamSet; - ECDomainParameters ecP = ECGost3410NamedCurves.GetByOid(publicKeyParamSet); + X9ECParameters ecP = ECGost3410NamedCurves.GetByOidX9(publicKeyParamSet); if (ecP == null) return null; @@ -238,7 +238,7 @@ namespace Org.BouncyCastle.Security DerObjectIdentifier publicKeyParamSet = gostParams.PublicKeyParamSet; ECGost3410Parameters ecDomainParameters =new ECGost3410Parameters( - new ECNamedDomainParameters(publicKeyParamSet, ECGost3410NamedCurves.GetByOid(publicKeyParamSet)), + new ECNamedDomainParameters(publicKeyParamSet, ECGost3410NamedCurves.GetByOidX9(publicKeyParamSet)), publicKeyParamSet, gostParams.DigestParamSet, gostParams.EncryptionParamSet); |