summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJerome Poichet <jpoichet@google.com>2014-09-13 12:35:49 -0700
committerJerome Poichet <jpoichet@google.com>2014-09-13 12:35:49 -0700
commit450c5ad6a6efc16de0383f5aecdfdeac2736ca30 (patch)
treea4a051eb62bef191aa1ba93c3df18b2f08b6eabf
parent1b6f39a9b15773c496fd0fdc281db6e8ce3a4161 (diff)
downloadgoogle-tv-pairing-protocol-450c5ad6a6efc16de0383f5aecdfdeac2736ca30.tar.gz
- When we moved to the latest version of bouncycastle, it looks like I forgot this particular instance. Change-Id: I9822187707f4644250beed4817f03dc6401adfe3
-rw-r--r--java/src/com/google/polo/ssl/CsrUtil.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/java/src/com/google/polo/ssl/CsrUtil.java b/java/src/com/google/polo/ssl/CsrUtil.java
index d5ff7bc..f399dc4 100644
--- a/java/src/com/google/polo/ssl/CsrUtil.java
+++ b/java/src/com/google/polo/ssl/CsrUtil.java
@@ -7,11 +7,11 @@ import org.bouncycastle.asn1.x509.GeneralName;
import org.bouncycastle.asn1.x509.GeneralNames;
import org.bouncycastle.asn1.x509.KeyPurposeId;
import org.bouncycastle.asn1.x509.KeyUsage;
+import org.bouncycastle.asn1.x509.SubjectKeyIdentifier;
import org.bouncycastle.asn1.x509.X509Extensions;
import org.bouncycastle.asn1.x509.X509Name;
import org.bouncycastle.x509.X509V3CertificateGenerator;
import org.bouncycastle.x509.extension.AuthorityKeyIdentifierStructure;
-import org.bouncycastle.x509.extension.SubjectKeyIdentifierStructure;
import java.math.BigInteger;
import java.security.GeneralSecurityException;
@@ -83,7 +83,7 @@ public class CsrUtil {
certGen.addExtension(X509Extensions.AuthorityKeyIdentifier, true, authIdentifier);
certGen.addExtension(X509Extensions.SubjectKeyIdentifier, true,
- new SubjectKeyIdentifierStructure(rootPair.getPublic()));
+ SubjectKeyIdentifier.getInstance(rootPair.getPublic().getEncoded()));
certGen.addExtension(X509Extensions.SubjectAlternativeName, false, new GeneralNames(
new GeneralName(GeneralName.rfc822Name, EMAIL)));
@@ -139,7 +139,7 @@ public class CsrUtil {
new AuthorityKeyIdentifierStructure(rootCert));
// Use provided public key for the subject
certGen.addExtension(X509Extensions.SubjectKeyIdentifier, false,
- new SubjectKeyIdentifierStructure(publicKey));
+ SubjectKeyIdentifier.getInstance(publicKey.getEncoded()));
// This is not a CA certificate, do not allow
certGen.addExtension(X509Extensions.BasicConstraints, true, new BasicConstraints(false));
// This can be used for signature and encryption