- java.lang.Object
-
- com.sun.xml.ws.security.impl.DerivedKeyTokenImpl
-
- All Implemented Interfaces:
DerivedKeyToken,Token
public class DerivedKeyTokenImpl extends Object implements DerivedKeyToken
- 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
Constructors Constructor Description DerivedKeyTokenImpl(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
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SecretKeygenerateSymmetricKey(String algorithm)URIgetAlgorithm()longgetGeneration()StringgetLabel()longgetLength()byte[]getNonce()longgetOffset()ObjectgetTokenValue()The token ValueStringgetType()The type of the Token
-
-
-
Constructor Detail
-
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
public DerivedKeyTokenImpl(long offset, long length, byte[] secret, byte[] nonce, String label)
-
DerivedKeyTokenImpl
public DerivedKeyTokenImpl(long generation, byte[] secret)
-
-
Method Detail
-
getAlgorithm
public URI getAlgorithm()
- Specified by:
getAlgorithmin interfaceDerivedKeyToken
-
getLength
public long getLength()
- Specified by:
getLengthin interfaceDerivedKeyToken
-
getOffset
public long getOffset()
- Specified by:
getOffsetin interfaceDerivedKeyToken
-
getTokenValue
public Object getTokenValue()
Description copied from interface:TokenThe token Value- Specified by:
getTokenValuein interfaceToken
-
getGeneration
public long getGeneration()
- Specified by:
getGenerationin interfaceDerivedKeyToken
-
getLabel
public String getLabel()
- Specified by:
getLabelin interfaceDerivedKeyToken
-
getNonce
public byte[] getNonce()
- Specified by:
getNoncein interfaceDerivedKeyToken
-
generateSymmetricKey
public SecretKey generateSymmetricKey(String algorithm) throws InvalidKeyException, NoSuchAlgorithmException, UnsupportedEncodingException
- Specified by:
generateSymmetricKeyin interfaceDerivedKeyToken- Throws:
InvalidKeyExceptionNoSuchAlgorithmExceptionUnsupportedEncodingException
-
-