Skip to content

Commit

Permalink
Merge "sun.security.pkcs: type tyding. Port from jdk8u60"
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergio Giro authored and Gerrit Code Review committed Dec 2, 2016
2 parents c878a4f + b721e58 commit 51c6d48
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions ojluni/src/main/java/sun/security/pkcs/PKCS9Attribute.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -331,11 +331,11 @@ public class PKCS9Attribute implements DerEncoder {
{new Byte(DerValue.tag_Sequence)} // SignatureTimestampToken
};

private static final Class[] VALUE_CLASSES = new Class[18];
private static final Class<?>[] VALUE_CLASSES = new Class<?>[18];

static {
try {
Class str = Class.forName("[Ljava.lang.String;");
Class<?> str = Class.forName("[Ljava.lang.String;");

VALUE_CLASSES[0] = null; // not used
VALUE_CLASSES[1] = str; // EMailAddress
Expand Down Expand Up @@ -489,8 +489,8 @@ public PKCS9Attribute(DerValue derVal) throws IOException {

if (val.length != 2)
throw new IOException("PKCS9Attribute doesn't have two components");
// get the oid

// get the oid
oid = val[0].getOID();
byte[] content = val[1].toByteArray();
DerValue[] elems = new DerInputStream(content).getSet(1);
Expand Down
2 changes: 1 addition & 1 deletion ojluni/src/main/java/sun/security/pkcs/SignerInfo.java
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ SignerInfo verify(PKCS7 block, InputStream inputStream)
authenticatedAttributes.getAttributeValue(
PKCS9Attribute.CONTENT_TYPE_OID);
if (contentType == null ||
!contentType.equals(content.contentType))
!contentType.equals((Object)content.contentType))
return null; // contentType does not match, bad SignerInfo

// now, check message digest
Expand Down

0 comments on commit 51c6d48

Please sign in to comment.