Package jcifs.internal.smb1.com
Class SmbComNegotiateResponse
- java.lang.Object
-
- jcifs.internal.smb1.ServerMessageBlock
-
- jcifs.internal.smb1.com.SmbComNegotiateResponse
-
- All Implemented Interfaces:
CommonServerMessageBlock
,CommonServerMessageBlockRequest
,CommonServerMessageBlockResponse
,RequestWithPath
,SmbNegotiationResponse
,Message
,Request
,Response
public class SmbComNegotiateResponse extends ServerMessageBlock implements SmbNegotiationResponse
-
-
Field Summary
-
Fields inherited from class jcifs.internal.smb1.ServerMessageBlock
batchLevel, byteCount, digest, errorCode, flags2, headerStart, length, mid, path, pid, SMB_COM_CHECK_DIRECTORY, SMB_COM_CLOSE, SMB_COM_CREATE_DIRECTORY, SMB_COM_DELETE, SMB_COM_DELETE_DIRECTORY, SMB_COM_ECHO, SMB_COM_FIND_CLOSE2, SMB_COM_LOCKING_ANDX, SMB_COM_LOGOFF_ANDX, SMB_COM_MOVE, SMB_COM_NEGOTIATE, SMB_COM_NT_CANCEL, SMB_COM_NT_CREATE_ANDX, SMB_COM_NT_TRANSACT, SMB_COM_NT_TRANSACT_SECONDARY, SMB_COM_OPEN_ANDX, SMB_COM_QUERY_INFORMATION, SMB_COM_READ_ANDX, SMB_COM_RENAME, SMB_COM_SEEK, SMB_COM_SESSION_SETUP_ANDX, SMB_COM_SET_INFORMATION, SMB_COM_TRANSACTION, SMB_COM_TRANSACTION_SECONDARY, SMB_COM_TRANSACTION2, SMB_COM_TREE_CONNECT_ANDX, SMB_COM_TREE_DISCONNECT, SMB_COM_WRITE, SMB_COM_WRITE_ANDX, tid, uid, wordCount
-
-
Constructor Summary
Constructors Constructor Description SmbComNegotiateResponse(CIFSContext ctx)
-
Method Summary
-
Methods inherited from class jcifs.internal.smb1.ServerMessageBlock
addFlags2, allowChain, clearReceived, createCancel, decode, encode, equals, error, exception, getByteCount, getCommand, getConfig, getCreditCost, getDigest, getDomain, getErrorCode, getException, getExpiration, getFlags, getFlags2, getFullUNCPath, getGrantedCredits, getLength, getMid, getNext, getNextResponse, getOverrideTimeout, getPath, getPid, getRawPayload, getResponse, getServer, getSignSeq, getTid, getUid, hashCode, ignoreDisconnect, isAsync, isCancel, isError, isExtendedSecurity, isForceUnicode, isReceived, isResolveInDfs, isResponse, isResponseAsync, isRetainPayload, isUseUnicode, isVerifyFailed, prepare, readHeaderWireFormat, readString, readString, readString, readStringLength, received, remFlags2, reset, retainPayload, setCommand, setDigest, setErrorCode, setExpiration, setExtendedSecurity, setFlags, setFlags2, setFullUNCPath, setMid, setOverrideTimeout, setPath, setPid, setRawPayload, setRequestCredits, setResolveInDfs, setResponse, setSessionId, setSignSeq, setTid, setUid, setUseUnicode, size, split, stringWireLength, verifySignature, writeHeaderWireFormat, writeString, writeString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface jcifs.internal.CommonServerMessageBlock
decode, encode, getCommand, getDigest, getMid, getResponse, reset, setCommand, setDigest, setExtendedSecurity, setMid, setResponse, setSessionId, setUid
-
Methods inherited from interface jcifs.util.transport.Message
getRawPayload, isRetainPayload, retainPayload, setRawPayload
-
Methods inherited from interface jcifs.util.transport.Response
clearReceived, error, exception, getErrorCode, getException, getExpiration, getGrantedCredits, getMid, isError, isReceived, isVerifyFailed, received, reset, setExpiration, setMid, verifySignature
-
-
-
-
Constructor Detail
-
SmbComNegotiateResponse
public SmbComNegotiateResponse(CIFSContext ctx)
- Parameters:
ctx
-
-
-
Method Detail
-
getSelectedDialect
public DialectVersion getSelectedDialect()
- Specified by:
getSelectedDialect
in interfaceSmbNegotiationResponse
- Returns:
- selected dialect
- See Also:
SmbNegotiationResponse.getSelectedDialect()
-
getTransactionBufferSize
public int getTransactionBufferSize()
- Specified by:
getTransactionBufferSize
in interfaceSmbNegotiationResponse
- Returns:
- the transaction buffer size
- See Also:
SmbNegotiationResponse.getTransactionBufferSize()
-
getInitialCredits
public int getInitialCredits()
- Specified by:
getInitialCredits
in interfaceSmbNegotiationResponse
- Returns:
- number of initial credits the server grants
- See Also:
SmbNegotiationResponse.getInitialCredits()
-
canReuse
public boolean canReuse(CIFSContext tc, boolean forceSigning)
- Specified by:
canReuse
in interfaceSmbNegotiationResponse
- Returns:
- whether a connection can be reused for this config
- See Also:
SmbNegotiationResponse.canReuse(jcifs.CIFSContext, boolean)
-
getDialectIndex
public int getDialectIndex()
- Returns:
- the dialectIndex
-
getNegotiatedCapabilities
public int getNegotiatedCapabilities()
- Returns:
- the negotiated capbilities
-
getNegotiatedSendBufferSize
public int getNegotiatedSendBufferSize()
- Returns:
- negotiated send buffer size
-
getNegotiatedMpxCount
public int getNegotiatedMpxCount()
- Returns:
- negotiated multiplex count
-
getNegotiatedSessionKey
public int getNegotiatedSessionKey()
- Returns:
- negotiated session key
-
getReceiveBufferSize
public int getReceiveBufferSize()
- Specified by:
getReceiveBufferSize
in interfaceSmbNegotiationResponse
- Returns:
- the receive buffer size
- See Also:
SmbNegotiationResponse.getReceiveBufferSize()
-
getSendBufferSize
public int getSendBufferSize()
- Specified by:
getSendBufferSize
in interfaceSmbNegotiationResponse
- Returns:
- the send buffer size
- See Also:
SmbNegotiationResponse.getSendBufferSize()
-
getNegotiatedFlags2
public int getNegotiatedFlags2()
- Returns:
- negotiated flags2
-
haveCapabilitiy
public boolean haveCapabilitiy(int cap)
- Specified by:
haveCapabilitiy
in interfaceSmbNegotiationResponse
- Returns:
- whether capability is negotiated
- See Also:
SmbNegotiationResponse.haveCapabilitiy(int)
-
isDFSSupported
public boolean isDFSSupported()
- Specified by:
isDFSSupported
in interfaceSmbNegotiationResponse
- Returns:
- whether the server supports DFS
- See Also:
SmbNegotiationResponse.isDFSSupported()
-
isSigningNegotiated
public boolean isSigningNegotiated()
- Specified by:
isSigningNegotiated
in interfaceSmbNegotiationResponse
- Returns:
- whether signing has been negotiated
- See Also:
SmbNegotiationResponse.isSigningNegotiated()
-
isValid
public boolean isValid(CIFSContext ctx, SmbNegotiationRequest req)
- Specified by:
isValid
in interfaceSmbNegotiationResponse
- Returns:
- whether the protocol negotiation was successful
-
setupRequest
public void setupRequest(CommonServerMessageBlock request)
- Specified by:
setupRequest
in interfaceSmbNegotiationResponse
- See Also:
SmbNegotiationResponse.setupRequest(jcifs.internal.CommonServerMessageBlock)
-
setupResponse
public void setupResponse(Response resp)
- Specified by:
setupResponse
in interfaceSmbNegotiationResponse
- See Also:
SmbNegotiationResponse.setupResponse(jcifs.util.transport.Response)
-
isSigningEnabled
public boolean isSigningEnabled()
- Specified by:
isSigningEnabled
in interfaceSmbNegotiationResponse
- Returns:
- whether the server has singing enabled
- See Also:
SmbNegotiationResponse.isSigningEnabled()
-
isSigningRequired
public boolean isSigningRequired()
- Specified by:
isSigningRequired
in interfaceSmbNegotiationResponse
- Returns:
- whether the server requires signing
- See Also:
SmbNegotiationResponse.isSigningRequired()
-
getServerData
public ServerData getServerData()
- Returns:
- the server
-
writeParameterWordsWireFormat
protected int writeParameterWordsWireFormat(byte[] dst, int dstIndex)
- Specified by:
writeParameterWordsWireFormat
in classServerMessageBlock
-
writeBytesWireFormat
protected int writeBytesWireFormat(byte[] dst, int dstIndex)
- Specified by:
writeBytesWireFormat
in classServerMessageBlock
-
readParameterWordsWireFormat
protected int readParameterWordsWireFormat(byte[] buffer, int bufferIndex)
- Specified by:
readParameterWordsWireFormat
in classServerMessageBlock
-
readBytesWireFormat
protected int readBytesWireFormat(byte[] buffer, int bufferIndex)
- Specified by:
readBytesWireFormat
in classServerMessageBlock
-
toString
public String toString()
- Overrides:
toString
in classServerMessageBlock
-
-