APIdia Launch Partner
Top Description Inners Fields Constructors Methods
sun.security.x509

public Class OIDMap

extends Object
Class Inheritance
Imports
java.util.*, java.io.IOException, java.security.cert.CertificateException, sun.security.util.*

This class defines the mapping from OID & name to class and vice versa. Used by CertificateExtensions & PKCS10 to get the java classes associated with a particular OID/name.
Authors
Amit Kapoor, Hemma Prafullchandra, Andreas Sterbenz

Nested and Inner Type Summary

Modifier and TypeClass and Description
private static class
OIDMap.OIDInfo

Inner class encapsulating the mapping info and Class loading.

Field Summary

Modifier and TypeField and Description
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final Map<String, OIDMap.OIDInfo>
nameMap

Map String(friendly name) -> OIDInfo(info)

private static final String
private static final String
private static final Map<ObjectIdentifier, OIDMap.OIDInfo>
oidMap

Map ObjectIdentifier(oid) -> OIDInfo(info)

private static final String
private static final String
private static final String
private static final String
private static final String
private static final String
private static final String

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static void
addAttribute(String
the name of the attr
name
,
String
the string representation of the object identifier for the class.
oid
,
Class<?>
the Class object associated with this attribute
clazz
)

Add a name to lookup table.

private static void
addInternal(String name, ObjectIdentifier oid, String className)

Add attributes to the table.

public static Class<?>
getClass(String
the user-friendly name.
name
)

Return the java class object associated with the user-friendly name.

public static Class<?>
getClass(ObjectIdentifier
the name of the object identifier to be returned.
oid
)

Return the java class object associated with the object identifier.

public static String

Returns:

the user-friendly name or null if no name is registered for this oid.
getName
(ObjectIdentifier
the name of the object identifier to be returned.
oid
)

Return user-friendly name associated with the OID.

public static ObjectIdentifier

Returns:

the Object Identifier or null if no oid is registered for this name.
getOID
(String
the user-friendly name.
name
)

Return Object identifier for user friendly name.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

AUTH_INFO_ACCESSback to summary
private static final String AUTH_INFO_ACCESS
AUTH_KEY_IDENTIFIERback to summary
private static final String AUTH_KEY_IDENTIFIER
BASIC_CONSTRAINTSback to summary
private static final String BASIC_CONSTRAINTS
CERT_ISSUERback to summary
private static final String CERT_ISSUER
CERT_POLICIESback to summary
private static final String CERT_POLICIES
CRL_DIST_POINTSback to summary
private static final String CRL_DIST_POINTS
CRL_NUMBERback to summary
private static final String CRL_NUMBER
CRL_REASONback to summary
private static final String CRL_REASON
DELTA_CRL_INDICATORback to summary
private static final String DELTA_CRL_INDICATOR
EXT_KEY_USAGEback to summary
private static final String EXT_KEY_USAGE
FRESHEST_CRLback to summary
private static final String FRESHEST_CRL
INHIBIT_ANY_POLICYback to summary
private static final String INHIBIT_ANY_POLICY
ISSUER_ALT_NAMEback to summary
private static final String ISSUER_ALT_NAME
ISSUING_DIST_POINTback to summary
private static final String ISSUING_DIST_POINT
KEY_USAGEback to summary
private static final String KEY_USAGE
NAME_CONSTRAINTSback to summary
private static final String NAME_CONSTRAINTS
nameMapback to summary
private static final Map<String, OIDMap.OIDInfo> nameMap

Map String(friendly name) -> OIDInfo(info)

NETSCAPE_CERTback to summary
private static final String NETSCAPE_CERT
OCSPNOCHECKback to summary
private static final String OCSPNOCHECK
oidMapback to summary
private static final Map<ObjectIdentifier, OIDMap.OIDInfo> oidMap

Map ObjectIdentifier(oid) -> OIDInfo(info)

POLICY_CONSTRAINTSback to summary
private static final String POLICY_CONSTRAINTS
POLICY_MAPPINGSback to summary
private static final String POLICY_MAPPINGS
PRIVATE_KEY_USAGEback to summary
private static final String PRIVATE_KEY_USAGE
ROOTback to summary
private static final String ROOT
SUB_ALT_NAMEback to summary
private static final String SUB_ALT_NAME
SUB_KEY_IDENTIFIERback to summary
private static final String SUB_KEY_IDENTIFIER
SUBJECT_INFO_ACCESSback to summary
private static final String SUBJECT_INFO_ACCESS

Constructor Detail

OIDMapback to summary
private OIDMap()

Method Detail

addAttributeback to summary
public static void addAttribute(String name, String oid, Class<?> clazz) throws CertificateException

Add a name to lookup table.

Parameters
name:String

the name of the attr

oid:String

the string representation of the object identifier for the class.

clazz:Class<?>

the Class object associated with this attribute

Exceptions
CertificateException:
on errors.
addInternalback to summary
private static void addInternal(String name, ObjectIdentifier oid, String className)

Add attributes to the table. For internal use in the static initializer.

getClassback to summary
public static Class<?> getClass(String name) throws CertificateException

Return the java class object associated with the user-friendly name.

Parameters
name:String

the user-friendly name.

Exceptions
CertificateException:
if class cannot be instantiated.
getClassback to summary
public static Class<?> getClass(ObjectIdentifier oid) throws CertificateException

Return the java class object associated with the object identifier.

Parameters
oid:ObjectIdentifier

the name of the object identifier to be returned.

Exceptions
CertificateException:
if class cannot be instantiated.
getNameback to summary
public static String getName(ObjectIdentifier oid)

Return user-friendly name associated with the OID.

Parameters
oid:ObjectIdentifier

the name of the object identifier to be returned.

Returns:String

the user-friendly name or null if no name is registered for this oid.

getOIDback to summary
public static ObjectIdentifier getOID(String name)

Return Object identifier for user friendly name.

Parameters
name:String

the user-friendly name.

Returns:ObjectIdentifier

the Object Identifier or null if no oid is registered for this name.

sun.security.x509 back to summary

private Class OIDMap.OIDInfo

extends Object
Class Inheritance

Inner class encapsulating the mapping info and Class loading.

Field Summary

Modifier and TypeField and Description
pack-priv final String
private volatile Class<?>
pack-priv final String
pack-priv final ObjectIdentifier

Constructor Summary

AccessConstructor and Description
pack-priv
OIDInfo(String name, ObjectIdentifier oid, String className)

pack-priv
OIDInfo(String name, ObjectIdentifier oid, Class<?> clazz)

Method Summary

Modifier and TypeMethod and Description
pack-priv Class<?>
getClazz()

Return the Class object associated with this attribute.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

classNameback to summary
pack-priv final String className
clazzback to summary
private volatile Class<?> clazz
nameback to summary
pack-priv final String name
oidback to summary
pack-priv final ObjectIdentifier oid

Constructor Detail

OIDInfoback to summary
pack-priv OIDInfo(String name, ObjectIdentifier oid, String className)
OIDInfoback to summary
pack-priv OIDInfo(String name, ObjectIdentifier oid, Class<?> clazz)

Method Detail

getClazzback to summary
pack-priv Class<?> getClazz() throws CertificateException

Return the Class object associated with this attribute.