|
Oracle Fusion Middleware Java API Reference for Oracle WebLogic Server 12c (12.1.2) Part Number E27170-01 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object weblogic.xml.security.keyinfo.KeyInfo
public class KeyInfo
KeyInfo is an optional element that enables the recipient(s) to obtain the key needed to validate the signature. KeyInfo may contain keys, names, certificates and other public key management information, such as in-band key distribution or key agreement data.
Field Summary |
---|
Constructor Summary | |
---|---|
KeyInfo(EncryptedKey encryptedKey)
|
|
KeyInfo(String keyName)
|
|
KeyInfo(Token token)
|
|
KeyInfo(X509Certificate cert)
Constructs a KeyInfo from a certificate. |
|
KeyInfo(XMLInputStream in,
String ns)
|
Method Summary | |
---|---|
void |
addEncryptedKey(EncryptedKey encryptedKey)
Adds an EncryptedKey to the KeyInfo element. |
void |
addKeyName(String keyName)
Adds a KeyName to the KeyInfo element. |
void |
addKeyValue(KeyValue keyValue)
Adds a KeyValue to the KeyInfo element. |
void |
addSecurityTokenReference(SecurityTokenReference ref)
Adds an SecurityTokenReference to the KeyInfo element. |
void |
addSecurityTokenReference(Token token)
|
void |
addX509Data(X509Data x509Data)
Adds an X509Data to the KeyInfo element. |
Iterator |
getCertificates()
Gets all of the Certificate contained in this
KeyInfo . |
Iterator |
getEncryptedKeys()
|
String |
getKeyName()
|
Iterator |
getKeyNames()
|
Iterator |
getKeyValues()
|
Iterator |
getPublicKeys()
Returns the PublicKeys contained in the KeyInfo
element. |
Iterator |
getSecurityTokenReferences()
|
Iterator |
getSubjectNames()
Gets all of the Certificate contained in this
KeyInfo . |
Iterator |
getX509Data()
|
static void |
main(String[] args)
|
void |
removeEncryptedKey(EncryptedKey encryptedKey)
Removes an EncryptedKey from the KeyInfo element. |
void |
removeKeyName(String keyName)
Removes a KeyName from the KeyInfo element. |
void |
removeKeyValue(KeyValue keyValue)
Removes a KeyValue from the KeyInfo element. |
void |
removeSecurityTokenReference(SecurityTokenReference ref)
Removes a SecurityTokenReference from the KeyInfo element. |
void |
removeX509Data(X509Data x509Data)
Removes a KeyValue from the KeyInfo element. |
String |
toString()
|
void |
toXML(XMLOutputStream os,
int indent)
|
void |
toXML(XMLOutputStream os,
String ns,
int indent)
|
void |
validate()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public KeyInfo(String keyName)
public KeyInfo(X509Certificate cert) throws KeyInfoException
KeyInfo
from a certificate. The KeyName is
set to the certificate's subject DN.
KeyInfoException
public KeyInfo(Token token)
public KeyInfo(EncryptedKey encryptedKey)
public KeyInfo(XMLInputStream in, String ns) throws XMLStreamException
XMLStreamException
Method Detail |
---|
public void addKeyName(String keyName)
public void removeKeyName(String keyName)
public String getKeyName()
public Iterator getKeyNames()
public void addKeyValue(KeyValue keyValue)
public void removeKeyValue(KeyValue keyValue)
public Iterator getKeyValues()
public void addX509Data(X509Data x509Data)
X509Data
to the KeyInfo element.
public void removeX509Data(X509Data x509Data)
public Iterator getX509Data()
public void addEncryptedKey(EncryptedKey encryptedKey)
EncryptedKey
to the KeyInfo element.
public void removeEncryptedKey(EncryptedKey encryptedKey)
public Iterator getEncryptedKeys()
public void addSecurityTokenReference(SecurityTokenReference ref)
SecurityTokenReference
to the KeyInfo element.
public void addSecurityTokenReference(Token token)
public void removeSecurityTokenReference(SecurityTokenReference ref)
public Iterator getSecurityTokenReferences()
public Iterator getSubjectNames() throws KeyInfoValidationException
Certificate
contained in this
KeyInfo
.
Certificate
, or null
if this
KeyInfo
contains no certificates
KeyInfoValidationException
public Iterator getCertificates() throws KeyInfoValidationException
Certificate
contained in this
KeyInfo
.
Certificate
, or null
if this
KeyInfo
contains no certificates
KeyInfoValidationException
public Iterator getPublicKeys() throws KeyInfoValidationException
PublicKeys
contained in the KeyInfo
element.
NOTE: This PublicKey
should not be used to perform
signature validation since there is no way to verify that the
key is valid. Instead, use the PublicKey contained in the
certificate, if one is available.
KeyInfoValidationException
public void validate() throws KeyInfoValidationException
KeyInfoValidationException
public void toXML(XMLOutputStream os, int indent) throws XMLStreamException
XMLStreamException
public void toXML(XMLOutputStream os, String ns, int indent) throws XMLStreamException
XMLStreamException
public static void main(String[] args) throws Exception
Exception
public String toString()
toString
in class Object
|
Copyright 1996, 2013, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Oracle Fusion Middleware Java API Reference for Oracle WebLogic Server 12c (12.1.2) Part Number E27170-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |