jcifs.ntlmssp
Class NtlmMessage

java.lang.Object
  extended byjcifs.ntlmssp.NtlmMessage
All Implemented Interfaces:
NtlmFlags
Direct Known Subclasses:
Type1Message, Type2Message, Type3Message

public abstract class NtlmMessage
extends java.lang.Object
implements NtlmFlags

Abstract superclass for all NTLMSSP messages.


Field Summary
protected static byte[] NTLMSSP_SIGNATURE
          The NTLMSSP "preamble".
 
Fields inherited from interface jcifs.ntlmssp.NtlmFlags
NTLMSSP_NEGOTIATE_128, NTLMSSP_NEGOTIATE_56, NTLMSSP_NEGOTIATE_ALWAYS_SIGN, NTLMSSP_NEGOTIATE_DATAGRAM_STYLE, NTLMSSP_NEGOTIATE_KEY_EXCH, NTLMSSP_NEGOTIATE_LM_KEY, NTLMSSP_NEGOTIATE_LOCAL_CALL, NTLMSSP_NEGOTIATE_NETWARE, NTLMSSP_NEGOTIATE_NTLM, NTLMSSP_NEGOTIATE_NTLM2, NTLMSSP_NEGOTIATE_OEM, NTLMSSP_NEGOTIATE_OEM_DOMAIN_SUPPLIED, NTLMSSP_NEGOTIATE_OEM_WORKSTATION_SUPPLIED, NTLMSSP_NEGOTIATE_SEAL, NTLMSSP_NEGOTIATE_SIGN, NTLMSSP_NEGOTIATE_TARGET_INFO, NTLMSSP_NEGOTIATE_UNICODE, NTLMSSP_REQUEST_ACCEPT_RESPONSE, NTLMSSP_REQUEST_INIT_RESPONSE, NTLMSSP_REQUEST_NON_NT_SESSION_KEY, NTLMSSP_REQUEST_TARGET, NTLMSSP_TARGET_TYPE_DOMAIN, NTLMSSP_TARGET_TYPE_SERVER, NTLMSSP_TARGET_TYPE_SHARE
 
Constructor Summary
NtlmMessage()
           
 
Method Summary
 boolean getFlag(int flag)
          Returns the status of the specified flag.
 int getFlags()
          Returns the flags currently in use for this message.
 void setFlag(int flag, boolean value)
          Sets or clears the specified flag.
 void setFlags(int flags)
          Sets the flags for this message.
abstract  byte[] toByteArray()
          Returns the raw byte representation of this message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NTLMSSP_SIGNATURE

protected static final byte[] NTLMSSP_SIGNATURE
The NTLMSSP "preamble".

Constructor Detail

NtlmMessage

public NtlmMessage()
Method Detail

getFlags

public int getFlags()
Returns the flags currently in use for this message.

Returns:
An int containing the flags in use for this message.

setFlags

public void setFlags(int flags)
Sets the flags for this message.

Parameters:
flags - The flags for this message.

getFlag

public boolean getFlag(int flag)
Returns the status of the specified flag.

Parameters:
flag - The flag to test (i.e., NTLMSSP_NEGOTIATE_OEM).
Returns:
A boolean indicating whether the flag is set.

setFlag

public void setFlag(int flag,
                    boolean value)
Sets or clears the specified flag.

Parameters:
flag - The flag to set/clear (i.e., NTLMSSP_NEGOTIATE_OEM).
value - Indicates whether to set (true) or clear (false) the specified flag.

toByteArray

public abstract byte[] toByteArray()
Returns the raw byte representation of this message.

Returns:
A byte[] containing the raw message material.