java.lang.Object
org.codelibs.jcifs.smb.spnego.SpnegoToken
- Direct Known Subclasses:
NegTokenInit,NegTokenTarg
Abstract base class for SPNEGO authentication tokens used in GSS-API negotiation
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedProtected constructor for SPNEGO token implementations. -
Method Summary
Modifier and TypeMethodDescriptionbyte[]Gets the mechanism list MIC (Message Integrity Code) for integrity protectionbyte[]Gets the inner mechanism token wrapped in this SPNEGO tokenprotected abstract voidparse(byte[] token) Parses the provided token bytes to populate this SPNEGO tokenvoidsetMechanismListMIC(byte[] mechanismListMIC) Sets the mechanism list MIC (Message Integrity Code) for integrity protectionvoidsetMechanismToken(byte[] mechanismToken) Sets the inner mechanism token to be wrapped in this SPNEGO tokenabstract byte[]Encodes this SPNEGO token to a byte array
-
Constructor Details
-
SpnegoToken
protected SpnegoToken()Protected constructor for SPNEGO token implementations.
-
-
Method Details
-
getMechanismToken
public byte[] getMechanismToken()Gets the inner mechanism token wrapped in this SPNEGO token- Returns:
- the mechanism token bytes
-
setMechanismToken
public void setMechanismToken(byte[] mechanismToken) Sets the inner mechanism token to be wrapped in this SPNEGO token- Parameters:
mechanismToken- the mechanism token bytes
-
getMechanismListMIC
public byte[] getMechanismListMIC()Gets the mechanism list MIC (Message Integrity Code) for integrity protection- Returns:
- the mechanism list MIC bytes
-
setMechanismListMIC
public void setMechanismListMIC(byte[] mechanismListMIC) Sets the mechanism list MIC (Message Integrity Code) for integrity protection- Parameters:
mechanismListMIC- the mechanism list MIC bytes
-
toByteArray
public abstract byte[] toByteArray()Encodes this SPNEGO token to a byte array- Returns:
- the encoded token bytes
-
parse
Parses the provided token bytes to populate this SPNEGO token- Parameters:
token- the token bytes to parse- Throws:
IOException- if parsing fails
-