diff options
author | David Hook <dgh@bouncycastle.org> | 2015-10-24 16:31:54 +1100 |
---|---|---|
committer | David Hook <dgh@bouncycastle.org> | 2015-10-24 16:31:54 +1100 |
commit | 0178c1bb391ac346c6a75b4ad7a6bed73843c704 (patch) | |
tree | 2dee4de4e4f20cca632d3950fee17c59edf66db2 /crypto/src/x509 | |
parent | comment update (diff) | |
download | BouncyCastle.NET-ed25519-0178c1bb391ac346c6a75b4ad7a6bed73843c704.tar.xz |
Final naming refactor
Diffstat (limited to 'crypto/src/x509')
-rw-r--r-- | crypto/src/x509/X509Certificate.cs | 6 | ||||
-rw-r--r-- | crypto/src/x509/X509Crl.cs | 4 | ||||
-rw-r--r-- | crypto/src/x509/X509V1CertificateGenerator.cs | 10 | ||||
-rw-r--r-- | crypto/src/x509/X509V2AttributeCertificate.cs | 6 | ||||
-rw-r--r-- | crypto/src/x509/X509V2AttributeCertificateGenerator.cs | 10 | ||||
-rw-r--r-- | crypto/src/x509/X509V2CRLGenerator.cs | 10 | ||||
-rw-r--r-- | crypto/src/x509/X509V3CertificateGenerator.cs | 10 |
7 files changed, 28 insertions, 28 deletions
diff --git a/crypto/src/x509/X509Certificate.cs b/crypto/src/x509/X509Certificate.cs index c323fc8f1..a0c102e98 100644 --- a/crypto/src/x509/X509Certificate.cs +++ b/crypto/src/x509/X509Certificate.cs @@ -547,7 +547,7 @@ namespace Org.BouncyCastle.X509 public virtual void Verify( AsymmetricKeyParameter key) { - CheckSignature(new Asn1SignatureVerifier(c.SignatureAlgorithm, key)); + CheckSignature(new Asn1VerifierFactory(c.SignatureAlgorithm, key)); } /// <summary> @@ -557,13 +557,13 @@ namespace Org.BouncyCastle.X509 /// <returns>True if the signature is valid.</returns> /// <exception cref="Exception">If verifier provider is not appropriate or the certificate algorithm is invalid.</exception> public virtual void Verify( - ISignatureVerifierProvider verifierProvider) + IVerifierFactoryProvider verifierProvider) { CheckSignature(verifierProvider.CreateSignatureVerifier (c.SignatureAlgorithm)); } protected virtual void CheckSignature( - ISignatureVerifier verifier) + IVerifierFactory verifier) { if (!IsAlgIDEqual(c.SignatureAlgorithm, c.TbsCertificate.Signature)) throw new CertificateException("signature algorithm in TBS cert not same as outer cert"); diff --git a/crypto/src/x509/X509Crl.cs b/crypto/src/x509/X509Crl.cs index 0679cb240..0492720a2 100644 --- a/crypto/src/x509/X509Crl.cs +++ b/crypto/src/x509/X509Crl.cs @@ -94,13 +94,13 @@ namespace Org.BouncyCastle.X509 /// <returns>True if the signature is valid.</returns> /// <exception cref="Exception">If verifier provider is not appropriate or the CRL algorithm is invalid.</exception> public virtual void Verify( - ISignatureVerifierProvider verifierProvider) + IVerifierFactoryProvider verifierProvider) { CheckSignature(verifierProvider.CreateSignatureVerifier(c.SignatureAlgorithm)); } protected virtual void CheckSignature( - ISignatureVerifier verifier) + IVerifierFactory verifier) { if (!c.SignatureAlgorithm.Equals(c.TbsCertList.Signature)) { diff --git a/crypto/src/x509/X509V1CertificateGenerator.cs b/crypto/src/x509/X509V1CertificateGenerator.cs index a311d823a..79e3862e4 100644 --- a/crypto/src/x509/X509V1CertificateGenerator.cs +++ b/crypto/src/x509/X509V1CertificateGenerator.cs @@ -121,7 +121,7 @@ namespace Org.BouncyCastle.X509 /// This can be either a name or an OID, names are treated as case insensitive. /// </summary> /// <param name="signatureAlgorithm">string representation of the algorithm name</param> - [Obsolete("Not needed if Generate used with an ISignatureCalculatorFactory")] + [Obsolete("Not needed if Generate used with an ISignatureFactory")] public void SetSignatureAlgorithm( string signatureAlgorithm) { @@ -146,7 +146,7 @@ namespace Org.BouncyCastle.X509 /// </summary> /// <param name="privateKey">The private key of the issuer used to sign this certificate.</param> /// <returns>An X509Certificate.</returns> - [Obsolete("Use Generate with an ISignatureCalculatorFactory")] + [Obsolete("Use Generate with an ISignatureFactory")] public X509Certificate Generate( AsymmetricKeyParameter privateKey) { @@ -159,12 +159,12 @@ namespace Org.BouncyCastle.X509 /// <param name="privateKey">The private key of the issuer used to sign this certificate.</param> /// <param name="random">The Secure Random you want to use.</param> /// <returns>An X509Certificate.</returns> - [Obsolete("Use Generate with an ISignatureCalculatorFactory")] + [Obsolete("Use Generate with an ISignatureFactory")] public X509Certificate Generate( AsymmetricKeyParameter privateKey, SecureRandom random) { - return Generate(new Asn1SignatureCalculatorFactory(signatureAlgorithm, privateKey, random)); + return Generate(new Asn1SignatureFactory(signatureAlgorithm, privateKey, random)); } /// <summary> @@ -172,7 +172,7 @@ namespace Org.BouncyCastle.X509 /// </summary> /// <param name="signatureCalculatorFactory">A signature calculator factory with the necessary algorithm details.</param> /// <returns>An X509Certificate.</returns> - public X509Certificate Generate(ISignatureCalculatorFactory signatureCalculatorFactory) + public X509Certificate Generate(ISignatureFactory signatureCalculatorFactory) { tbsGen.SetSignature ((AlgorithmIdentifier)signatureCalculatorFactory.AlgorithmDetails); diff --git a/crypto/src/x509/X509V2AttributeCertificate.cs b/crypto/src/x509/X509V2AttributeCertificate.cs index cc72c23bb..ad9c467c6 100644 --- a/crypto/src/x509/X509V2AttributeCertificate.cs +++ b/crypto/src/x509/X509V2AttributeCertificate.cs @@ -155,7 +155,7 @@ namespace Org.BouncyCastle.X509 public virtual void Verify( AsymmetricKeyParameter key) { - CheckSignature(new Asn1SignatureVerifier(cert.SignatureAlgorithm, key)); + CheckSignature(new Asn1VerifierFactory(cert.SignatureAlgorithm, key)); } /// <summary> @@ -165,13 +165,13 @@ namespace Org.BouncyCastle.X509 /// <returns>True if the signature is valid.</returns> /// <exception cref="Exception">If verifier provider is not appropriate or the certificate algorithm is invalid.</exception> public virtual void Verify( - ISignatureVerifierProvider verifierProvider) + IVerifierFactoryProvider verifierProvider) { CheckSignature(verifierProvider.CreateSignatureVerifier(cert.SignatureAlgorithm)); } protected virtual void CheckSignature( - ISignatureVerifier verifier) + IVerifierFactory verifier) { if (!cert.SignatureAlgorithm.Equals(cert.ACInfo.Signature)) { diff --git a/crypto/src/x509/X509V2AttributeCertificateGenerator.cs b/crypto/src/x509/X509V2AttributeCertificateGenerator.cs index 195030554..8fd5dfdb9 100644 --- a/crypto/src/x509/X509V2AttributeCertificateGenerator.cs +++ b/crypto/src/x509/X509V2AttributeCertificateGenerator.cs @@ -73,7 +73,7 @@ namespace Org.BouncyCastle.X509 /// are treated as case insensitive. /// </summary> /// <param name="signatureAlgorithm">The algorithm name.</param> - [Obsolete("Not needed if Generate used with an ISignatureCalculatorFactory")] + [Obsolete("Not needed if Generate used with an ISignatureFactory")] public void SetSignatureAlgorithm( string signatureAlgorithm) { @@ -133,7 +133,7 @@ namespace Org.BouncyCastle.X509 /// <summary> /// Generate an X509 certificate, based on the current issuer and subject. /// </summary> - [Obsolete("Use Generate with an ISignatureCalculatorFactory")] + [Obsolete("Use Generate with an ISignatureFactory")] public IX509AttributeCertificate Generate( AsymmetricKeyParameter privateKey) { @@ -144,12 +144,12 @@ namespace Org.BouncyCastle.X509 /// Generate an X509 certificate, based on the current issuer and subject, /// using the supplied source of randomness, if required. /// </summary> - [Obsolete("Use Generate with an ISignatureCalculatorFactory")] + [Obsolete("Use Generate with an ISignatureFactory")] public IX509AttributeCertificate Generate( AsymmetricKeyParameter privateKey, SecureRandom random) { - return Generate(new Asn1SignatureCalculatorFactory(signatureAlgorithm, privateKey, random)); + return Generate(new Asn1SignatureFactory(signatureAlgorithm, privateKey, random)); } /// <summary> @@ -157,7 +157,7 @@ namespace Org.BouncyCastle.X509 /// </summary> /// <param name="signatureCalculatorFactory">A signature calculator factory with the necessary algorithm details.</param> /// <returns>An IX509AttributeCertificate.</returns> - public IX509AttributeCertificate Generate(ISignatureCalculatorFactory signatureCalculatorFactory) + public IX509AttributeCertificate Generate(ISignatureFactory signatureCalculatorFactory) { if (!extGenerator.IsEmpty) { diff --git a/crypto/src/x509/X509V2CRLGenerator.cs b/crypto/src/x509/X509V2CRLGenerator.cs index 4cfd1b6d9..6c9ffe7e5 100644 --- a/crypto/src/x509/X509V2CRLGenerator.cs +++ b/crypto/src/x509/X509V2CRLGenerator.cs @@ -134,7 +134,7 @@ namespace Org.BouncyCastle.X509 /// Set the signature algorithm that will be used to sign this CRL. /// </summary> /// <param name="signatureAlgorithm"/> - [Obsolete("Not needed if Generate used with an ISignatureCalculatorFactory")] + [Obsolete("Not needed if Generate used with an ISignatureFactory")] public void SetSignatureAlgorithm( string signatureAlgorithm) { @@ -203,7 +203,7 @@ namespace Org.BouncyCastle.X509 /// </summary> /// <param name="privateKey">The private key of the issuer that is signing this certificate.</param> /// <returns>An X509Crl.</returns> - [Obsolete("Use Generate with an ISignatureCalculatorFactory")] + [Obsolete("Use Generate with an ISignatureFactory")] public X509Crl Generate( AsymmetricKeyParameter privateKey) { @@ -216,12 +216,12 @@ namespace Org.BouncyCastle.X509 /// <param name="privateKey">The private key of the issuer that is signing this certificate.</param> /// <param name="random">Your Secure Random instance.</param> /// <returns>An X509Crl.</returns> - [Obsolete("Use Generate with an ISignatureCalculatorFactory")] + [Obsolete("Use Generate with an ISignatureFactory")] public X509Crl Generate( AsymmetricKeyParameter privateKey, SecureRandom random) { - return Generate(new Asn1SignatureCalculatorFactory(signatureAlgorithm, privateKey, random)); + return Generate(new Asn1SignatureFactory(signatureAlgorithm, privateKey, random)); } /// <summary> @@ -229,7 +229,7 @@ namespace Org.BouncyCastle.X509 /// </summary> /// <param name="signatureCalculatorFactory">A signature calculator factory with the necessary algorithm details.</param> /// <returns>An X509Crl.</returns> - public X509Crl Generate(ISignatureCalculatorFactory signatureCalculatorFactory) + public X509Crl Generate(ISignatureFactory signatureCalculatorFactory) { tbsGen.SetSignature((AlgorithmIdentifier)signatureCalculatorFactory.AlgorithmDetails); diff --git a/crypto/src/x509/X509V3CertificateGenerator.cs b/crypto/src/x509/X509V3CertificateGenerator.cs index f19016f84..51488bd2a 100644 --- a/crypto/src/x509/X509V3CertificateGenerator.cs +++ b/crypto/src/x509/X509V3CertificateGenerator.cs @@ -112,7 +112,7 @@ namespace Org.BouncyCastle.X509 /// Set the signature algorithm that will be used to sign this certificate. /// </summary> /// <param name="signatureAlgorithm"/> - [Obsolete("Not needed if Generate used with an ISignatureCalculatorFactory")] + [Obsolete("Not needed if Generate used with an ISignatureFactory")] public void SetSignatureAlgorithm( string signatureAlgorithm) { @@ -277,7 +277,7 @@ namespace Org.BouncyCastle.X509 /// </summary> /// <param name="privateKey">The private key of the issuer that is signing this certificate.</param> /// <returns>An X509Certificate.</returns> - [Obsolete("Use Generate with an ISignatureCalculatorFactory")] + [Obsolete("Use Generate with an ISignatureFactory")] public X509Certificate Generate( AsymmetricKeyParameter privateKey) { @@ -290,12 +290,12 @@ namespace Org.BouncyCastle.X509 /// <param name="privateKey">The private key of the issuer that is signing this certificate.</param> /// <param name="random">You Secure Random instance.</param> /// <returns>An X509Certificate.</returns> - [Obsolete("Use Generate with an ISignatureCalculatorFactory")] + [Obsolete("Use Generate with an ISignatureFactory")] public X509Certificate Generate( AsymmetricKeyParameter privateKey, SecureRandom random) { - return Generate(new Asn1SignatureCalculatorFactory(signatureAlgorithm, privateKey, random)); + return Generate(new Asn1SignatureFactory(signatureAlgorithm, privateKey, random)); } /// <summary> @@ -303,7 +303,7 @@ namespace Org.BouncyCastle.X509 /// </summary> /// <param name="signatureCalculatorFactory">A signature calculator factory with the necessary algorithm details.</param> /// <returns>An X509Certificate.</returns> - public X509Certificate Generate(ISignatureCalculatorFactory signatureCalculatorFactory) + public X509Certificate Generate(ISignatureFactory signatureCalculatorFactory) { tbsGen.SetSignature ((AlgorithmIdentifier)signatureCalculatorFactory.AlgorithmDetails); |