|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.security12.sun.security.pkcs.PKCS9Attribute
Class supporting any PKCS9 attributes.
Supports DER decoding and access to attribute values, but not
DER encoding or setting of values.
Type/Class Table
The following table shows the correspondence between
PKCS9 attribute types and value component classes.
Object Identifier | Attribute Name | Type | Value Class |
---|---|---|---|
1.2.840.113549.1.9.1 | EmailAddress | Multi-valued | String[] |
1.2.840.113549.1.9.2 | UnstructuredName | Multi-valued | String[] |
1.2.840.113549.1.9.3 | ContentType | Single-valued | ObjectIdentifier |
1.2.840.113549.1.9.4 | MessageDigest | Single-valued | byte[] |
1.2.840.113549.1.9.5 | SigningTime | Single-valued | Date |
1.2.840.113549.1.9.6 | Countersignature | Multi-valued | SignerInfo[] |
1.2.840.113549.1.9.7 | ChallengePassword | Single-valued | String |
1.2.840.113549.1.9.8 | UnstructuredAddress | Single-valued | String |
1.2.840.113549.1.9.9 | ExtendedCertificateAttributes | Multi-valued | (not supported) |
1.2.840.113549.1.9.10 | IssuerAndSerialNumber | Single-valued | (not supported) |
1.2.840.113549.1.9.{11,12} | RSA DSI proprietary | Single-valued | (not supported) |
1.2.840.113549.1.9.13 | S/MIME unused assignment | Single-valued | (not supported) |
1.2.840.113549.1.9.14 | ExtensionRequest | Single-valued | CertificateExtensions |
1.2.840.113549.1.9.15 | SMIMECapability | Single-valued | (not supported) |
Field Summary | |
static ObjectIdentifier |
CHALLENGE_PASSWORD_OID
|
static String |
CHALLENGE_PASSWORD_STR
|
static ObjectIdentifier |
CONTENT_TYPE_OID
|
static String |
CONTENT_TYPE_STR
|
static ObjectIdentifier |
COUNTERSIGNATURE_OID
|
static String |
COUNTERSIGNATURE_STR
|
static ObjectIdentifier |
EMAIL_ADDRESS_OID
|
static String |
EMAIL_ADDRESS_STR
|
static ObjectIdentifier |
EXTENDED_CERTIFICATE_ATTRIBUTES_OID
|
static String |
EXTENDED_CERTIFICATE_ATTRIBUTES_STR
|
static ObjectIdentifier |
EXTENSION_REQUEST_OID
|
static String |
EXTENSION_REQUEST_STR
|
static ObjectIdentifier |
ISSUER_SERIALNUMBER_OID
|
static String |
ISSUER_SERIALNUMBER_STR
|
static ObjectIdentifier |
MESSAGE_DIGEST_OID
|
static String |
MESSAGE_DIGEST_STR
|
static ObjectIdentifier |
SIGNING_TIME_OID
|
static String |
SIGNING_TIME_STR
|
static ObjectIdentifier |
SMIME_CAPABILITY_OID
|
static String |
SMIME_CAPABILITY_STR
|
static ObjectIdentifier |
UNSTRUCTURED_ADDRESS_OID
|
static String |
UNSTRUCTURED_ADDRESS_STR
|
static ObjectIdentifier |
UNSTRUCTURED_NAME_OID
|
static String |
UNSTRUCTURED_NAME_STR
|
Constructor Summary | |
PKCS9Attribute(DerValue derVal)
Construct a PKCS9Attribute from its encoding on an input stream. |
|
PKCS9Attribute(ObjectIdentifier oid,
Object value)
Construct an attribute object from the attribute's OID and value. |
|
PKCS9Attribute(String name,
Object value)
Construct an attribute object from the attribute's name and value. |
Method Summary | |
void |
derEncode(OutputStream out)
Write the DER encoding of this attribute to an output stream. |
String |
getName()
Return the name of this attribute. |
static String |
getName(ObjectIdentifier oid)
Return the attribute name for a given OID or null if we don't recognize the oid. |
ObjectIdentifier |
getOID()
Return the OID of this attribute. |
static ObjectIdentifier |
getOID(String name)
Return the OID for a given attribute name or null if we don't recognize the name. |
Object |
getValue()
Get the value of this attribute. |
boolean |
isSingleValued()
Show whether this attribute is single-valued. |
String |
toString()
Returns a string representation of this attribute. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
public static final ObjectIdentifier EMAIL_ADDRESS_OID
public static final ObjectIdentifier UNSTRUCTURED_NAME_OID
public static final ObjectIdentifier CONTENT_TYPE_OID
public static final ObjectIdentifier MESSAGE_DIGEST_OID
public static final ObjectIdentifier SIGNING_TIME_OID
public static final ObjectIdentifier COUNTERSIGNATURE_OID
public static final ObjectIdentifier CHALLENGE_PASSWORD_OID
public static final ObjectIdentifier UNSTRUCTURED_ADDRESS_OID
public static final ObjectIdentifier EXTENDED_CERTIFICATE_ATTRIBUTES_OID
public static final ObjectIdentifier ISSUER_SERIALNUMBER_OID
public static final ObjectIdentifier EXTENSION_REQUEST_OID
public static final ObjectIdentifier SMIME_CAPABILITY_OID
public static final String EMAIL_ADDRESS_STR
public static final String UNSTRUCTURED_NAME_STR
public static final String CONTENT_TYPE_STR
public static final String MESSAGE_DIGEST_STR
public static final String SIGNING_TIME_STR
public static final String COUNTERSIGNATURE_STR
public static final String CHALLENGE_PASSWORD_STR
public static final String UNSTRUCTURED_ADDRESS_STR
public static final String EXTENDED_CERTIFICATE_ATTRIBUTES_STR
public static final String ISSUER_SERIALNUMBER_STR
public static final String EXTENSION_REQUEST_STR
public static final String SMIME_CAPABILITY_STR
Constructor Detail |
public PKCS9Attribute(ObjectIdentifier oid, Object value) throws IllegalArgumentException
The
table gives the class that value
must have for a given attribute.
public PKCS9Attribute(String name, Object value) throws IllegalArgumentException
The
table gives the class that value
must have for a given attribute. Reasonable variants of these
attributes are accepted; in particular, case does not matter.
name
is not recognized of the
value
has the wrong type.public PKCS9Attribute(DerValue derVal) throws IOException
val
- the DerValue representing the DER encoding of the attribute.Method Detail |
public void derEncode(OutputStream out) throws IOException
N.B.: This method always encodes values of
ChallengePassword and UnstructuredAddress attributes as ASN.1
PrintableString
s, without checking whether they
should be encoded as T61String
s.
public Object getValue()
The table gives the class of the value returned, depending on the type of this attribute.
public boolean isSingleValued()
public ObjectIdentifier getOID()
public String getName()
public static ObjectIdentifier getOID(String name)
public static String getName(ObjectIdentifier oid)
public String toString()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |