Package com.hierynomus.spnego
Class NegTokenTarg
- java.lang.Object
-
- com.hierynomus.spnego.SpnegoToken
-
- com.hierynomus.spnego.NegTokenTarg
-
public class NegTokenTarg extends SpnegoToken
This class can encode and decode the SPNEGO negTokenInit Token. The entire token is an ASN.1 DER encoded sequence of bytes in little endian byte encoding. The following if the ASN.1 specification of the full structure of the token:NegotiationToken ::= CHOICE { negTokenInit [0] NegTokenInit, negTokenTarg [1] NegTokenTarg } NegTokenTarg ::= SEQUENCE { negResult [0] ENUMERATED { accept_completed (0), accept_incomplete (1), rejected (2) } OPTIONAL, supportedMech [1] MechType OPTIONAL, responseToken [2] OCTET STRING OPTIONAL, mechListMIC [3] OCTET STRING OPTIONAL } MechType ::= OBJECT IDENTIFIERIn the context of this class only the NegTokenTarg is covered.
-
-
Constructor Summary
Constructors Constructor Description NegTokenTarg()
-
Method Summary
Modifier and Type Method Description byte[]getMechListMic()java.math.BigIntegergetNegotiationResult()byte[]getResponseToken()com.hierynomus.asn1.types.primitive.ASN1ObjectIdentifiergetSupportedMech()protected voidparseTagged(com.hierynomus.asn1.types.constructed.ASN1TaggedObject asn1TaggedObject)NegTokenTargread(byte[] bytes)voidsetMechListMic(byte[] mechListMic)voidsetNegotiationResult(java.math.BigInteger negotiationResult)voidsetResponseToken(byte[] responseToken)voidsetSupportedMech(com.hierynomus.asn1.types.primitive.ASN1ObjectIdentifier supportedMech)voidwrite(Buffer<?> buffer)protected voidwriteGss(Buffer<?> buffer, com.hierynomus.asn1.types.ASN1Object<?> negToken)-
Methods inherited from class com.hierynomus.spnego.SpnegoToken
parseSpnegoToken
-
-
-
-
Method Detail
-
writeGss
protected void writeGss(Buffer<?> buffer, com.hierynomus.asn1.types.ASN1Object<?> negToken) throws java.io.IOException
- Overrides:
writeGssin classSpnegoToken- Throws:
java.io.IOException
-
write
public void write(Buffer<?> buffer) throws SpnegoException
- Specified by:
writein classSpnegoToken- Throws:
SpnegoException
-
read
public NegTokenTarg read(byte[] bytes) throws SpnegoException
- Throws:
SpnegoException
-
parseTagged
protected void parseTagged(com.hierynomus.asn1.types.constructed.ASN1TaggedObject asn1TaggedObject) throws SpnegoException- Specified by:
parseTaggedin classSpnegoToken- Throws:
SpnegoException
-
getNegotiationResult
public java.math.BigInteger getNegotiationResult()
-
setNegotiationResult
public void setNegotiationResult(java.math.BigInteger negotiationResult)
-
getSupportedMech
public com.hierynomus.asn1.types.primitive.ASN1ObjectIdentifier getSupportedMech()
-
setSupportedMech
public void setSupportedMech(com.hierynomus.asn1.types.primitive.ASN1ObjectIdentifier supportedMech)
-
getResponseToken
public byte[] getResponseToken()
-
setResponseToken
public void setResponseToken(byte[] responseToken)
-
getMechListMic
public byte[] getMechListMic()
-
setMechListMic
public void setMechListMic(byte[] mechListMic)
-
-