Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/quite/humla-spongycastle.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Dettman <peter.dettman@bouncycastle.org>2013-09-01 18:29:49 +0400
committerPeter Dettman <peter.dettman@bouncycastle.org>2013-09-01 18:29:49 +0400
commit0a46c92ae767c0be4af1f744a20afe9b8ca6a51f (patch)
tree00a04965636b2361f06e2765e3128b4e0bd2ffb8 /core/src/main/java/org/bouncycastle/crypto/signers
parenteb0d42c50803770e61e2666f9b91ecd6961cd04a (diff)
Add new constructor to take the OID explicitly, to allow use with
NullDigest
Diffstat (limited to 'core/src/main/java/org/bouncycastle/crypto/signers')
-rw-r--r--core/src/main/java/org/bouncycastle/crypto/signers/RSADigestSigner.java10
1 files changed, 8 insertions, 2 deletions
diff --git a/core/src/main/java/org/bouncycastle/crypto/signers/RSADigestSigner.java b/core/src/main/java/org/bouncycastle/crypto/signers/RSADigestSigner.java
index f33ed317..aaae0645 100644
--- a/core/src/main/java/org/bouncycastle/crypto/signers/RSADigestSigner.java
+++ b/core/src/main/java/org/bouncycastle/crypto/signers/RSADigestSigner.java
@@ -57,9 +57,15 @@ public class RSADigestSigner
public RSADigestSigner(
Digest digest)
{
- this.digest = digest;
+ this(digest, (ASN1ObjectIdentifier)oidMap.get(digest.getAlgorithmName()));
+ }
- algId = new AlgorithmIdentifier((ASN1ObjectIdentifier)oidMap.get(digest.getAlgorithmName()), DERNull.INSTANCE);
+ public RSADigestSigner(
+ Digest digest,
+ ASN1ObjectIdentifier digestOid)
+ {
+ this.digest = digest;
+ this.algId = new AlgorithmIdentifier(digestOid, DERNull.INSTANCE);
}
/**