|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjavax.xml.crypto.dsig.keyinfo.KeyInfoFactory
org.jcp.xml.dsig.internal.dom.DOMKeyInfoFactory
public final class DOMKeyInfoFactory
Disabled: no SafeJ information.
DOM-based implementation of KeyInfoFactory.
Constructor Summary | |
---|---|
DOMKeyInfoFactory()
|
Method Summary | |
---|---|
URIDereferencer |
getURIDereferencer()
Returns a reference to the URIDereferencer that is used by
default to dereference URIs in RetrievalMethod objects. |
boolean |
isFeatureSupported(String feature)
Indicates whether a specified feature is supported. |
KeyInfo |
newKeyInfo(List content)
Creates a KeyInfo containing the specified list of
key information types. |
KeyInfo |
newKeyInfo(List content,
String id)
Creates a KeyInfo containing the specified list of key
information types and optional id. |
KeyName |
newKeyName(String name)
Creates a KeyName from the specified name. |
KeyValue |
newKeyValue(PublicKey key)
Creates a KeyValue from the specified public key. |
PGPData |
newPGPData(byte[] keyId)
Creates a PGPData from the specified PGP public key
identifier. |
PGPData |
newPGPData(byte[] keyId,
byte[] keyPacket,
List other)
Creates a PGPData from the specified PGP public key
identifier, and optional key material packet and list of external
elements. |
PGPData |
newPGPData(byte[] keyPacket,
List other)
Creates a PGPData from the specified PGP key material
packet and optional list of external elements. |
RetrievalMethod |
newRetrievalMethod(String uri)
Creates a RetrievalMethod from the specified URI. |
RetrievalMethod |
newRetrievalMethod(String uri,
String type,
List transforms)
Creates a RetrievalMethod from the specified parameters. |
X509Data |
newX509Data(List content)
Creates a X509Data containing the specified list of
X.509 content. |
X509IssuerSerial |
newX509IssuerSerial(String issuerName,
BigInteger serialNumber)
Creates an X509IssuerSerial from the specified X.500 issuer
distinguished name and serial number. |
KeyInfo |
unmarshalKeyInfo(XMLStructure xmlStructure)
Unmarshals a new KeyInfo instance from a
mechanism-specific XMLStructure (ex: DOMStructure )
instance. |
Methods inherited from class javax.xml.crypto.dsig.keyinfo.KeyInfoFactory |
---|
getInstance, getInstance, getInstance, getInstance, getMechanismType, getProvider |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DOMKeyInfoFactory()
Method Detail |
---|
public KeyInfo newKeyInfo(List content)
KeyInfoFactory
KeyInfo
containing the specified list of
key information types.
newKeyInfo
in class KeyInfoFactory
content
- a list of one or more XMLStructure
s representing
key information types. The list is defensively copied to protect
against subsequent modification.
KeyInfo
public KeyInfo newKeyInfo(List content, String id)
KeyInfoFactory
KeyInfo
containing the specified list of key
information types and optional id. The
id
parameter represents the value of an XML
ID
attribute and is useful for referencing
the KeyInfo
from other XML structures.
newKeyInfo
in class KeyInfoFactory
content
- a list of one or more XMLStructure
s representing
key information types. The list is defensively copied to protect
against subsequent modification.id
- the value of an XML ID
(may be null
)
KeyInfo
public KeyName newKeyName(String name)
KeyInfoFactory
KeyName
from the specified name.
newKeyName
in class KeyInfoFactory
name
- the name that identifies the key
KeyName
public KeyValue newKeyValue(PublicKey key) throws KeyException
KeyInfoFactory
KeyValue
from the specified public key.
newKeyValue
in class KeyInfoFactory
key
- the public key
KeyValue
KeyException
- if the key
's algorithm is not
recognized or supported by this KeyInfoFactory
public PGPData newPGPData(byte[] keyId)
KeyInfoFactory
PGPData
from the specified PGP public key
identifier.
newPGPData
in class KeyInfoFactory
keyId
- a PGP public key identifier as defined in RFC 2440, section 11.2.
The array is cloned to protect against subsequent modification.
PGPData
public PGPData newPGPData(byte[] keyId, byte[] keyPacket, List other)
KeyInfoFactory
PGPData
from the specified PGP public key
identifier, and optional key material packet and list of external
elements.
newPGPData
in class KeyInfoFactory
keyId
- a PGP public key identifier as defined in RFC 2440, section 11.2.
The array is cloned to protect against subsequent modification.keyPacket
- a PGP key material packet as defined in RFC 2440, section 5.5.
The array is cloned to protect against subsequent modification. May
be null
.other
- a list of XMLStructure
s representing elements from
an external namespace. The list is defensively copied to protect
against subsequent modification. May be null
or empty.
PGPData
public PGPData newPGPData(byte[] keyPacket, List other)
KeyInfoFactory
PGPData
from the specified PGP key material
packet and optional list of external elements.
newPGPData
in class KeyInfoFactory
keyPacket
- a PGP key material packet as defined in RFC 2440, section 5.5.
The array is cloned to protect against subsequent modification.other
- a list of XMLStructure
s representing elements from
an external namespace. The list is defensively copied to protect
against subsequent modification. May be null
or empty.
PGPData
public RetrievalMethod newRetrievalMethod(String uri)
KeyInfoFactory
RetrievalMethod
from the specified URI.
newRetrievalMethod
in class KeyInfoFactory
uri
- the URI that identifies the KeyInfo
information
to be retrieved
RetrievalMethod
public RetrievalMethod newRetrievalMethod(String uri, String type, List transforms)
KeyInfoFactory
RetrievalMethod
from the specified parameters.
newRetrievalMethod
in class KeyInfoFactory
uri
- the URI that identifies the KeyInfo
information
to be retrievedtype
- a URI that identifies the type of KeyInfo
information to be retrieved (may be null
)transforms
- a list of Transform
s. The list is defensively
copied to protect against subsequent modification. May be
null
or empty.
RetrievalMethod
public X509Data newX509Data(List content)
KeyInfoFactory
X509Data
containing the specified list of
X.509 content.
newX509Data
in class KeyInfoFactory
content
- a list of one or more X.509 content types. Valid types are
String
(subject names), byte[]
(subject key ids),
X509Certificate
, X509CRL
,
or XMLStructure
(X509IssuerSerial
objects or elements from an external namespace). Subject names are
distinguished names in RFC 2253 String format. Implementations MUST
support the attribute type keywords defined in RFC 2253 (CN, L, ST,
O, OU, C, STREET, DC and UID). Implementations MAY support additional
keywords. The list is defensively copied to protect against
subsequent modification.
X509Data
public X509IssuerSerial newX509IssuerSerial(String issuerName, BigInteger serialNumber)
KeyInfoFactory
X509IssuerSerial
from the specified X.500 issuer
distinguished name and serial number.
newX509IssuerSerial
in class KeyInfoFactory
issuerName
- the issuer's distinguished name in RFC 2253 String
format. Implementations MUST support the attribute type keywords
defined in RFC 2253 (CN, L, ST, O, OU, C, STREET, DC and UID).
Implementations MAY support additional keywords.serialNumber
- the serial number
X509IssuerSerial
public boolean isFeatureSupported(String feature)
KeyInfoFactory
isFeatureSupported
in class KeyInfoFactory
feature
- the feature name (as an absolute URI)
true
if the specified feature is supported,
false
otherwisepublic URIDereferencer getURIDereferencer()
KeyInfoFactory
URIDereferencer
that is used by
default to dereference URIs in RetrievalMethod
objects.
getURIDereferencer
in class KeyInfoFactory
URIDereferencer
public KeyInfo unmarshalKeyInfo(XMLStructure xmlStructure) throws MarshalException
KeyInfoFactory
KeyInfo
instance from a
mechanism-specific XMLStructure
(ex: DOMStructure
)
instance.
unmarshalKeyInfo
in class KeyInfoFactory
xmlStructure
- a mechanism-specific XML structure from which to
unmarshal the keyinfo from
KeyInfo
MarshalException
- if an unrecoverable exception occurs during
unmarshalling
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |