Package com.sun.xml.ws.security.impl
Class DerivedKeyTokenImpl
java.lang.Object
com.sun.xml.ws.security.impl.DerivedKeyTokenImpl
- All Implemented Interfaces:
DerivedKeyToken
,Token
- Author:
- Ashutosh Shahi
-
Field Summary
Fields inherited from interface com.sun.xml.ws.security.DerivedKeyToken
DEFAULT_DERIVED_KEY_TOKEN_ALGORITHM, DEFAULT_DERIVEDKEYTOKEN_LABEL, DERIVED_KEY_TOKEN_TYPE
-
Constructor Summary
ConstructorDescriptionDerivedKeyTokenImpl
(long generation, byte[] secret) DerivedKeyTokenImpl
(long offset, long length, byte[] secret) Creates a new instance of DerivedKeyTokenImplDerivedKeyTokenImpl
(long offset, long length, byte[] secret, byte[] nonce) DerivedKeyTokenImpl
(long offset, long length, byte[] secret, byte[] nonce, String label) -
Method Summary
Modifier and TypeMethodDescriptiongenerateSymmetricKey
(String algorithm) long
getLabel()
long
byte[]
getNonce()
long
The token ValuegetType()
The type of the Token
-
Constructor Details
-
DerivedKeyTokenImpl
public DerivedKeyTokenImpl(long offset, long length, byte[] secret) Creates a new instance of DerivedKeyTokenImpl -
DerivedKeyTokenImpl
public DerivedKeyTokenImpl(long offset, long length, byte[] secret, byte[] nonce) -
DerivedKeyTokenImpl
-
DerivedKeyTokenImpl
public DerivedKeyTokenImpl(long generation, byte[] secret)
-
-
Method Details
-
getAlgorithm
- Specified by:
getAlgorithm
in interfaceDerivedKeyToken
-
getLength
public long getLength()- Specified by:
getLength
in interfaceDerivedKeyToken
-
getOffset
public long getOffset()- Specified by:
getOffset
in interfaceDerivedKeyToken
-
getType
Description copied from interface:Token
The type of the Token -
getTokenValue
Description copied from interface:Token
The token Value- Specified by:
getTokenValue
in interfaceToken
-
getGeneration
public long getGeneration()- Specified by:
getGeneration
in interfaceDerivedKeyToken
-
getLabel
- Specified by:
getLabel
in interfaceDerivedKeyToken
-
getNonce
public byte[] getNonce()- Specified by:
getNonce
in interfaceDerivedKeyToken
-
generateSymmetricKey
public SecretKey generateSymmetricKey(String algorithm) throws InvalidKeyException, NoSuchAlgorithmException, UnsupportedEncodingException - Specified by:
generateSymmetricKey
in interfaceDerivedKeyToken
- Throws:
InvalidKeyException
NoSuchAlgorithmException
UnsupportedEncodingException
-