Documentation ¶
Index ¶
- Constants
- type Capabilities
- type Cipher
- type Command
- type CompressionAlgorithm
- type CompressionCapability
- type ContextType
- type Dialect
- type EncryptionCapability
- type FLAGS
- type HashAlgorithm
- type NegotiateContext
- func (c NegotiateContext) ContextType() ContextType
- func (c NegotiateContext) Data() []byte
- func (c NegotiateContext) DataLength() uint16
- func (c NegotiateContext) Reserved() uint32
- func (c NegotiateContext) SetContextType(t ContextType)
- func (c NegotiateContext) SetData(d []byte)
- func (c NegotiateContext) SetDataLength(l uint16)
- func (c NegotiateContext) SetReserved(r uint32)
- type NegotiateRequest
- func (p NegotiateRequest) Capabilities() uint32
- func (p NegotiateRequest) ClientGuid() []byte
- func (p NegotiateRequest) DialectCount() uint16
- func (p NegotiateRequest) Dialects() []Dialect
- func (p NegotiateRequest) IsInvalid() bool
- func (p NegotiateRequest) NegotiateContextCount() uint16
- func (p NegotiateRequest) NegotiateContextList() []NegotiateContext
- func (p NegotiateRequest) NegotiateContextOffset() uint32
- func (p NegotiateRequest) SecurityMode() NegotiateSigning
- func (p NegotiateRequest) SetCapabilities(v uint32)
- func (p NegotiateRequest) SetClientGuid(v []byte)
- func (p NegotiateRequest) SetDialectCount(v uint16)
- func (p NegotiateRequest) SetDialects(v []Dialect)
- func (p NegotiateRequest) SetNegotiateContextCount(v uint16)
- func (p NegotiateRequest) SetNegotiateContextOffset(v uint32)
- func (p NegotiateRequest) SetSecurityMode(v NegotiateSigning)
- func (p NegotiateRequest) SetStructureSize()
- func (p NegotiateRequest) StructureSize() uint16
- type NegotiateResponse
- func (r NegotiateResponse) Buffer() []byte
- func (r NegotiateResponse) Capabilities() Capabilities
- func (r NegotiateResponse) DialectRevision() Dialect
- func (p NegotiateResponse) IsInvalid() bool
- func (r NegotiateResponse) MaxReadSize() uint32
- func (r NegotiateResponse) MaxTransactSize() uint32
- func (r NegotiateResponse) MaxWriteSize() uint32
- func (r NegotiateResponse) NegotiateContextCount() uint16
- func (r NegotiateResponse) NegotiateContextOffset() uint32
- func (r NegotiateResponse) NegotiateContexts() []NegotiateContext
- func (r NegotiateResponse) SecurityBufferLength() uint16
- func (r NegotiateResponse) SecurityBufferOffset() uint16
- func (r NegotiateResponse) SecurityMode() NegotiateSigning
- func (r NegotiateResponse) ServerGuid() []byte
- func (r NegotiateResponse) ServerStartTime() time.Time
- func (r NegotiateResponse) SetBuffer(v []byte)
- func (r NegotiateResponse) SetCapabilities(v Capabilities)
- func (r NegotiateResponse) SetDialectRevision(v Dialect)
- func (r NegotiateResponse) SetMaxReadSize(v uint32)
- func (r NegotiateResponse) SetMaxTransactSize(v uint32)
- func (r NegotiateResponse) SetMaxWriteSize(v uint32)
- func (r NegotiateResponse) SetNegotiateContextCount(v uint16)
- func (r NegotiateResponse) SetNegotiateContextOffset(v uint32)
- func (r NegotiateResponse) SetNegotiateContexts(v []NegotiateContext)
- func (r NegotiateResponse) SetSecurityBufferLength(v uint16)
- func (r NegotiateResponse) SetSecurityBufferOffset(v uint16)
- func (r NegotiateResponse) SetSecurityMode(v NegotiateSigning)
- func (r NegotiateResponse) SetServerGuid(v []byte)
- func (r NegotiateResponse) SetServerStartTime(v time.Time)
- func (r NegotiateResponse) SetStructureSize(v uint16)
- func (r NegotiateResponse) SetSystemTime(v time.Time)
- func (r NegotiateResponse) StructureSize() uint16
- func (r NegotiateResponse) SystemTime() time.Time
- type NegotiateSigning
- type NetnameNegotitateContentID
- type PacketCodec
- func (p PacketCodec) AsyncId() uint64
- func (p PacketCodec) ChannelSequence() uint16
- func (p PacketCodec) Command() Command
- func (p PacketCodec) CreditCharge() uint16
- func (p PacketCodec) CreditRequestResponse() uint16
- func (p PacketCodec) Flags() FLAGS
- func (p PacketCodec) IsInvalid() bool
- func (p PacketCodec) MessageId() uint64
- func (p PacketCodec) NextCommand() uint32
- func (p PacketCodec) ProtocolId() []byte
- func (p PacketCodec) Reserved() uint16
- func (p PacketCodec) SessionId() uint64
- func (p PacketCodec) SetAsyncId(v uint64)
- func (p PacketCodec) SetChannelSequence(v uint16)
- func (p PacketCodec) SetCommand(v Command)
- func (p PacketCodec) SetCreditCharge(v uint16)
- func (p PacketCodec) SetCreditRequestResponse(v uint16)
- func (p PacketCodec) SetFlags(v FLAGS)
- func (p PacketCodec) SetMessageId(v uint64)
- func (p PacketCodec) SetNextCommand(v uint32)
- func (p PacketCodec) SetProtocolId()
- func (p PacketCodec) SetReserved(v uint16)
- func (p PacketCodec) SetSessionId(v uint64)
- func (p PacketCodec) SetSignature(v []byte)
- func (p PacketCodec) SetStatus(v uint32)
- func (p PacketCodec) SetStructureSize()
- func (p PacketCodec) SetTreeId(v uint32)
- func (p PacketCodec) Signature() []byte
- func (p PacketCodec) Status() uint32
- func (p PacketCodec) StructureSize() uint16
- func (p PacketCodec) TreeId() uint32
- type PreauthIntegrityCapability
- func (p PreauthIntegrityCapability) HashAlgorithmCount() uint16
- func (p PreauthIntegrityCapability) HashAlgorithms() []HashAlgorithm
- func (p PreauthIntegrityCapability) Salt() []byte
- func (p PreauthIntegrityCapability) SaltLength() uint16
- func (p PreauthIntegrityCapability) SetHashAlgorithmCount(c uint16)
- func (p PreauthIntegrityCapability) SetHashAlgorithms(a []HashAlgorithm)
- func (p PreauthIntegrityCapability) SetSalt(s []byte)
- func (p PreauthIntegrityCapability) SetSaltLength(l uint16)
- type RDMATransform
- type RDMATransformCapability
- type Server
- type SessionFlags
- type SessionSetupRequest
- func (p SessionSetupRequest) Buffer() []byte
- func (p SessionSetupRequest) Capabilities() Capabilities
- func (p SessionSetupRequest) Channel() uint32
- func (p SessionSetupRequest) Flags() SessionFlags
- func (p SessionSetupRequest) IsInvalid() bool
- func (p SessionSetupRequest) PreviousSessionId() uint64
- func (p SessionSetupRequest) SecurityBufferLength() uint16
- func (p SessionSetupRequest) SecurityBufferOffset() uint16
- func (p SessionSetupRequest) SecurityMode() NegotiateSigning
- func (p SessionSetupRequest) SetBuffer(v []byte)
- func (p SessionSetupRequest) SetCapabilities(v Capabilities)
- func (p SessionSetupRequest) SetChannel(v uint32)
- func (p SessionSetupRequest) SetFlags(v SessionFlags)
- func (p SessionSetupRequest) SetPreviousSessionId(v uint64)
- func (p SessionSetupRequest) SetSecurityBufferLength(v uint16)
- func (p SessionSetupRequest) SetSecurityBufferOffset(v uint16)
- func (p SessionSetupRequest) SetSecurityMode(v NegotiateSigning)
- func (p SessionSetupRequest) SetStructureSize()
- func (p SessionSetupRequest) StructureSize() uint16
- type SessionSetupResponse
- func (p SessionSetupResponse) Buffer() []byte
- func (p SessionSetupResponse) IsInvalid() bool
- func (p SessionSetupResponse) SecurityBufferLength() uint16
- func (p SessionSetupResponse) SecurityBufferOffset() uint16
- func (p SessionSetupResponse) SessionFlags() SessionSetupSessionFlags
- func (p SessionSetupResponse) SetBuffer(v []byte)
- func (p SessionSetupResponse) SetSecurityBufferLength(v uint16)
- func (p SessionSetupResponse) SetSecurityBufferOffset(v uint16)
- func (p SessionSetupResponse) SetSessionFlags(v SessionSetupSessionFlags)
- func (p SessionSetupResponse) SetStructureSize()
- func (p SessionSetupResponse) StructureSize() uint16
- type SessionSetupSessionFlags
- type SigningCapability
- type SingingAlgorithm
- type TransportCapability
- type TransportFlag
Constants ¶
View Source
const ( STATUS_MORE_PROCESSING_REQUIRED uint32 = 0xC0000016 STATUS_LOGON_FAILURE uint32 = 0xC000006D )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Capabilities ¶
type Capabilities uint32
const ( // MS-SMB2 - v20211006 page 53/481 SMB2_GLOBAL_CAP_DFS Capabilities = 0x00000001 SMB2_GLOBAL_CAP_LEASING Capabilities = 0x00000002 SMB2_GLOBAL_CAP_LARGE_MTU Capabilities = 0x00000004 SMB2_GLOBAL_CAP_MULTI_CHANNEL Capabilities = 0x00000008 SMB2_GLOBAL_CAP_PERSISTENT_HANDLES Capabilities = 0x00000010 SMB2_GLOBAL_CAP_DIRECTORY_LEASING Capabilities = 0x00000020 SMB2_GLOBAL_CAP_ENCRYPTION Capabilities = 0x00000040 )
type Command ¶
type Command uint16
const ( // MS-SMB2 - v20211006 page 33/481 SMB2_NEGOTIATE Command = 0x0000 SMB2_SESSION_SETUP Command = 0x0001 SMB2_LOGOFF Command = 0x0002 SMB2_TREE_CONNECT Command = 0x0003 SMB2_TREE_DISCONNECT Command = 0x0004 SMB2_CREATE Command = 0x0005 SMB2_CLOSE Command = 0x0006 SMB2_FLUSH Command = 0x0007 SMB2_READ Command = 0x0008 SMB2_WRITE Command = 0x0009 SMB2_LOCK Command = 0x000A SMB2_IOCTL Command = 0x000B SMB2_CANCEL Command = 0x000C SMB2_ECHO Command = 0x000D SMB2_QUERY_DIRECTORY Command = 0x000E SMB2_CHANGE_NOTIFY Command = 0x000F SMB2_QUERY_INFO Command = 0x0010 SMB2_SET_INFO Command = 0x0011 SMB2_OPLOCK_BREAK Command = 0x0012 )
type CompressionAlgorithm ¶
type CompressionAlgorithm uint16
const ( // MS-SMB2 - v20211006 page 49/481 SMB2_COMPRESSION_CAPABILITIES_NONE CompressionAlgorithm = 0x0000 SMB2_COMPRESSION_CAPABILITIES_LZNT1 CompressionAlgorithm = 0x0001 SMB2_COMPRESSION_CAPABILITIES_LZ77 CompressionAlgorithm = 0x0002 SMB2_COMPRESSION_CAPABILITIES_LZ77_HUFF CompressionAlgorithm = 0x0003 SMB2_COMPRESSION_CAPABILITIES_PATTERN_V1 CompressionAlgorithm = 0x0004 )
type CompressionCapability ¶
type CompressionCapability []byte
func (CompressionCapability) CompressionAlgorithmCount ¶
func (c CompressionCapability) CompressionAlgorithmCount() uint16
func (CompressionCapability) CompressionAlgorithms ¶
func (c CompressionCapability) CompressionAlgorithms() []CompressionAlgorithm
func (CompressionCapability) SetCompressionAlgorithmCount ¶
func (c CompressionCapability) SetCompressionAlgorithmCount(v uint16)
type ContextType ¶
type ContextType uint16
const ( // MS-SMB2 - v20211006 page 47/481 SMB2_PREAUTH_INTEGRITY_CAPABILITIES ContextType = 0x0001 SMB2_ENCRYPTION_CAPABILITIES ContextType = 0x0002 SMB2_COMPRESSION_CAPABILITIES ContextType = 0x0003 SMB2_NETNAME_NEGOTIATE_CONTEXT_ID ContextType = 0x0005 SMB2_TRANSPORT_CAPABILITIES ContextType = 0x0006 SMB2_RDMA_TRANSFORM_CAPABILITIES ContextType = 0x0007 SMB2_SIGNING_CAPABILITIES ContextType = 0x0008 )
func (ContextType) String ¶
func (c ContextType) String() string
type EncryptionCapability ¶
type EncryptionCapability []byte
func (EncryptionCapability) CipherCount ¶
func (e EncryptionCapability) CipherCount() uint16
func (EncryptionCapability) Ciphers ¶
func (e EncryptionCapability) Ciphers() []Cipher
func (EncryptionCapability) SetCipherCount ¶
func (e EncryptionCapability) SetCipherCount(c uint16)
type FLAGS ¶
type FLAGS uint32
const ( // MS-SMB2 - v20211006 page 33/481 SMB2_FLAGS_SERVER_TO_REDIR FLAGS = 0x00000001 SMB2_FLAGS_ASYNC_COMMAND FLAGS = 0x00000002 SMB2_FLAGS_RELATED_OPERATIONS FLAGS = 0x00000004 SMB2_FLAGS_SIGNED FLAGS = 0x00000008 SMB2_FLAGS_PRIORITY_MASK FLAGS = 0x00000070 SMB2_FLAGS_DFS_OPERATIONS FLAGS = 0x10000000 SMB2_FLAGS_REPLAY_OPERATION FLAGS = 0x20000000 )
type HashAlgorithm ¶
type HashAlgorithm uint16
const ( // MS-SMB2 - v20211006 page 48/481 SMB2_PREAUTH_INTEGRITY_SHA512 HashAlgorithm = 0x0001 )
type NegotiateContext ¶
type NegotiateContext []byte
func (NegotiateContext) ContextType ¶
func (c NegotiateContext) ContextType() ContextType
func (NegotiateContext) Data ¶
func (c NegotiateContext) Data() []byte
func (NegotiateContext) DataLength ¶
func (c NegotiateContext) DataLength() uint16
func (NegotiateContext) Reserved ¶
func (c NegotiateContext) Reserved() uint32
func (NegotiateContext) SetContextType ¶
func (c NegotiateContext) SetContextType(t ContextType)
func (NegotiateContext) SetData ¶
func (c NegotiateContext) SetData(d []byte)
func (NegotiateContext) SetDataLength ¶
func (c NegotiateContext) SetDataLength(l uint16)
func (NegotiateContext) SetReserved ¶
func (c NegotiateContext) SetReserved(r uint32)
type NegotiateRequest ¶
type NegotiateRequest []byte
func (NegotiateRequest) Capabilities ¶
func (p NegotiateRequest) Capabilities() uint32
func (NegotiateRequest) ClientGuid ¶
func (p NegotiateRequest) ClientGuid() []byte
func (NegotiateRequest) DialectCount ¶
func (p NegotiateRequest) DialectCount() uint16
func (NegotiateRequest) Dialects ¶
func (p NegotiateRequest) Dialects() []Dialect
func (NegotiateRequest) IsInvalid ¶
func (p NegotiateRequest) IsInvalid() bool
func (NegotiateRequest) NegotiateContextCount ¶
func (p NegotiateRequest) NegotiateContextCount() uint16
func (NegotiateRequest) NegotiateContextList ¶
func (p NegotiateRequest) NegotiateContextList() []NegotiateContext
func (NegotiateRequest) NegotiateContextOffset ¶
func (p NegotiateRequest) NegotiateContextOffset() uint32
func (NegotiateRequest) SecurityMode ¶
func (p NegotiateRequest) SecurityMode() NegotiateSigning
func (NegotiateRequest) SetCapabilities ¶
func (p NegotiateRequest) SetCapabilities(v uint32)
func (NegotiateRequest) SetClientGuid ¶
func (p NegotiateRequest) SetClientGuid(v []byte)
func (NegotiateRequest) SetDialectCount ¶
func (p NegotiateRequest) SetDialectCount(v uint16)
func (NegotiateRequest) SetDialects ¶
func (p NegotiateRequest) SetDialects(v []Dialect)
func (NegotiateRequest) SetNegotiateContextCount ¶
func (p NegotiateRequest) SetNegotiateContextCount(v uint16)
func (NegotiateRequest) SetNegotiateContextOffset ¶
func (p NegotiateRequest) SetNegotiateContextOffset(v uint32)
func (NegotiateRequest) SetSecurityMode ¶
func (p NegotiateRequest) SetSecurityMode(v NegotiateSigning)
func (NegotiateRequest) SetStructureSize ¶
func (p NegotiateRequest) SetStructureSize()
func (NegotiateRequest) StructureSize ¶
func (p NegotiateRequest) StructureSize() uint16
type NegotiateResponse ¶
type NegotiateResponse []byte
func (NegotiateResponse) Buffer ¶
func (r NegotiateResponse) Buffer() []byte
func (NegotiateResponse) Capabilities ¶
func (r NegotiateResponse) Capabilities() Capabilities
func (NegotiateResponse) DialectRevision ¶
func (r NegotiateResponse) DialectRevision() Dialect
func (NegotiateResponse) IsInvalid ¶
func (p NegotiateResponse) IsInvalid() bool
func (NegotiateResponse) MaxReadSize ¶
func (r NegotiateResponse) MaxReadSize() uint32
func (NegotiateResponse) MaxTransactSize ¶
func (r NegotiateResponse) MaxTransactSize() uint32
func (NegotiateResponse) MaxWriteSize ¶
func (r NegotiateResponse) MaxWriteSize() uint32
func (NegotiateResponse) NegotiateContextCount ¶
func (r NegotiateResponse) NegotiateContextCount() uint16
func (NegotiateResponse) NegotiateContextOffset ¶
func (r NegotiateResponse) NegotiateContextOffset() uint32
3.1.1 only
func (NegotiateResponse) NegotiateContexts ¶
func (r NegotiateResponse) NegotiateContexts() []NegotiateContext
func (NegotiateResponse) SecurityBufferLength ¶
func (r NegotiateResponse) SecurityBufferLength() uint16
func (NegotiateResponse) SecurityBufferOffset ¶
func (r NegotiateResponse) SecurityBufferOffset() uint16
func (NegotiateResponse) SecurityMode ¶
func (r NegotiateResponse) SecurityMode() NegotiateSigning
func (NegotiateResponse) ServerGuid ¶
func (r NegotiateResponse) ServerGuid() []byte
func (NegotiateResponse) ServerStartTime ¶
func (r NegotiateResponse) ServerStartTime() time.Time
func (NegotiateResponse) SetBuffer ¶
func (r NegotiateResponse) SetBuffer(v []byte)
func (NegotiateResponse) SetCapabilities ¶
func (r NegotiateResponse) SetCapabilities(v Capabilities)
func (NegotiateResponse) SetDialectRevision ¶
func (r NegotiateResponse) SetDialectRevision(v Dialect)
func (NegotiateResponse) SetMaxReadSize ¶
func (r NegotiateResponse) SetMaxReadSize(v uint32)
func (NegotiateResponse) SetMaxTransactSize ¶
func (r NegotiateResponse) SetMaxTransactSize(v uint32)
func (NegotiateResponse) SetMaxWriteSize ¶
func (r NegotiateResponse) SetMaxWriteSize(v uint32)
func (NegotiateResponse) SetNegotiateContextCount ¶
func (r NegotiateResponse) SetNegotiateContextCount(v uint16)
func (NegotiateResponse) SetNegotiateContextOffset ¶
func (r NegotiateResponse) SetNegotiateContextOffset(v uint32)
3.1.1 only
func (NegotiateResponse) SetNegotiateContexts ¶
func (r NegotiateResponse) SetNegotiateContexts(v []NegotiateContext)
func (NegotiateResponse) SetSecurityBufferLength ¶
func (r NegotiateResponse) SetSecurityBufferLength(v uint16)
func (NegotiateResponse) SetSecurityBufferOffset ¶
func (r NegotiateResponse) SetSecurityBufferOffset(v uint16)
func (NegotiateResponse) SetSecurityMode ¶
func (r NegotiateResponse) SetSecurityMode(v NegotiateSigning)
func (NegotiateResponse) SetServerGuid ¶
func (r NegotiateResponse) SetServerGuid(v []byte)
func (NegotiateResponse) SetServerStartTime ¶
func (r NegotiateResponse) SetServerStartTime(v time.Time)
func (NegotiateResponse) SetStructureSize ¶
func (r NegotiateResponse) SetStructureSize(v uint16)
func (NegotiateResponse) SetSystemTime ¶
func (r NegotiateResponse) SetSystemTime(v time.Time)
func (NegotiateResponse) StructureSize ¶
func (r NegotiateResponse) StructureSize() uint16
func (NegotiateResponse) SystemTime ¶
func (r NegotiateResponse) SystemTime() time.Time
type NegotiateSigning ¶
type NegotiateSigning uint16
const ( // MS-SMB2 - v20211006 page 53/481 SMB2_NEGOTIATE_SIGNING_ENABLED NegotiateSigning = 0x0001 SMB2_NEGOTIATE_SIGNING_REQUIRED NegotiateSigning = 0x0002 )
type NetnameNegotitateContentID ¶
type NetnameNegotitateContentID string
type PacketCodec ¶
type PacketCodec []byte
func (PacketCodec) AsyncId ¶
func (p PacketCodec) AsyncId() uint64
If the SMB2_FLAGS_ASYNC_COMMAND flag is set in the Flags field, this field will be AsyncId
func (PacketCodec) ChannelSequence ¶
func (p PacketCodec) ChannelSequence() uint16
In SMB 3.x, this field is ChannelSequence field followed by Reserved field
func (PacketCodec) Command ¶
func (p PacketCodec) Command() Command
func (PacketCodec) CreditCharge ¶
func (p PacketCodec) CreditCharge() uint16
func (PacketCodec) CreditRequestResponse ¶
func (p PacketCodec) CreditRequestResponse() uint16
func (PacketCodec) Flags ¶
func (p PacketCodec) Flags() FLAGS
func (PacketCodec) IsInvalid ¶
func (p PacketCodec) IsInvalid() bool
func (PacketCodec) MessageId ¶
func (p PacketCodec) MessageId() uint64
func (PacketCodec) NextCommand ¶
func (p PacketCodec) NextCommand() uint32
func (PacketCodec) ProtocolId ¶
func (p PacketCodec) ProtocolId() []byte
func (PacketCodec) Reserved ¶
func (p PacketCodec) Reserved() uint16
func (PacketCodec) SessionId ¶
func (p PacketCodec) SessionId() uint64
func (PacketCodec) SetAsyncId ¶
func (p PacketCodec) SetAsyncId(v uint64)
If SMB2_FLAGS_ASYNC_COMMAND set
func (PacketCodec) SetChannelSequence ¶
func (p PacketCodec) SetChannelSequence(v uint16)
func (PacketCodec) SetCommand ¶
func (p PacketCodec) SetCommand(v Command)
func (PacketCodec) SetCreditCharge ¶
func (p PacketCodec) SetCreditCharge(v uint16)
func (PacketCodec) SetCreditRequestResponse ¶
func (p PacketCodec) SetCreditRequestResponse(v uint16)
func (PacketCodec) SetFlags ¶
func (p PacketCodec) SetFlags(v FLAGS)
func (PacketCodec) SetMessageId ¶
func (p PacketCodec) SetMessageId(v uint64)
func (PacketCodec) SetNextCommand ¶
func (p PacketCodec) SetNextCommand(v uint32)
func (PacketCodec) SetProtocolId ¶
func (p PacketCodec) SetProtocolId()
func (PacketCodec) SetReserved ¶
func (p PacketCodec) SetReserved(v uint16)
func (PacketCodec) SetSessionId ¶
func (p PacketCodec) SetSessionId(v uint64)
func (PacketCodec) SetSignature ¶
func (p PacketCodec) SetSignature(v []byte)
func (PacketCodec) SetStatus ¶
func (p PacketCodec) SetStatus(v uint32)
func (PacketCodec) SetStructureSize ¶
func (p PacketCodec) SetStructureSize()
func (PacketCodec) SetTreeId ¶
func (p PacketCodec) SetTreeId(v uint32)
func (PacketCodec) Signature ¶
func (p PacketCodec) Signature() []byte
func (PacketCodec) Status ¶
func (p PacketCodec) Status() uint32
In SMB 2.0.2 and SMB 2.1 dialects, this field is Status field
func (PacketCodec) StructureSize ¶
func (p PacketCodec) StructureSize() uint16
func (PacketCodec) TreeId ¶
func (p PacketCodec) TreeId() uint32
If SMB2_FLAGS_ASYNC_COMMAND not set
type PreauthIntegrityCapability ¶
type PreauthIntegrityCapability []byte
func (PreauthIntegrityCapability) HashAlgorithmCount ¶
func (p PreauthIntegrityCapability) HashAlgorithmCount() uint16
func (PreauthIntegrityCapability) HashAlgorithms ¶
func (p PreauthIntegrityCapability) HashAlgorithms() []HashAlgorithm
func (PreauthIntegrityCapability) Salt ¶
func (p PreauthIntegrityCapability) Salt() []byte
func (PreauthIntegrityCapability) SaltLength ¶
func (p PreauthIntegrityCapability) SaltLength() uint16
func (PreauthIntegrityCapability) SetHashAlgorithmCount ¶
func (p PreauthIntegrityCapability) SetHashAlgorithmCount(c uint16)
func (PreauthIntegrityCapability) SetHashAlgorithms ¶
func (p PreauthIntegrityCapability) SetHashAlgorithms(a []HashAlgorithm)
func (PreauthIntegrityCapability) SetSalt ¶
func (p PreauthIntegrityCapability) SetSalt(s []byte)
func (PreauthIntegrityCapability) SetSaltLength ¶
func (p PreauthIntegrityCapability) SetSaltLength(l uint16)
type RDMATransform ¶
type RDMATransform uint16
const ( // MS-SMB2 - v20211006 page 50/481 SMB2_RDMA_TRANSFORM_NONE RDMATransform = 0x0000 SMB2_RDMA_TRANSFORM_ENCRYPTION RDMATransform = 0x0001 SMB2_RDMA_TRANSFORM_SIGNING RDMATransform = 0x0002 )
type RDMATransformCapability ¶
type RDMATransformCapability []byte
func (RDMATransformCapability) RDMATransforms ¶
func (c RDMATransformCapability) RDMATransforms() []RDMATransform
func (RDMATransformCapability) SetRDMATransforms ¶
func (c RDMATransformCapability) SetRDMATransforms(v []RDMATransform)
func (RDMATransformCapability) SetTransformCount ¶
func (c RDMATransformCapability) SetTransformCount(v uint16)
func (RDMATransformCapability) TransformCount ¶
func (c RDMATransformCapability) TransformCount() uint16
type SessionFlags ¶
type SessionFlags uint8
const ( // MS-SMB2 - v20211006 page 56/481 SMB2_SESSION_FLAG_BINDING SessionFlags = 0x01 )
type SessionSetupRequest ¶
type SessionSetupRequest []byte
func (SessionSetupRequest) Buffer ¶
func (p SessionSetupRequest) Buffer() []byte
func (SessionSetupRequest) Capabilities ¶
func (p SessionSetupRequest) Capabilities() Capabilities
func (SessionSetupRequest) Channel ¶
func (p SessionSetupRequest) Channel() uint32
func (SessionSetupRequest) Flags ¶
func (p SessionSetupRequest) Flags() SessionFlags
func (SessionSetupRequest) IsInvalid ¶
func (p SessionSetupRequest) IsInvalid() bool
func (SessionSetupRequest) PreviousSessionId ¶
func (p SessionSetupRequest) PreviousSessionId() uint64
func (SessionSetupRequest) SecurityBufferLength ¶
func (p SessionSetupRequest) SecurityBufferLength() uint16
func (SessionSetupRequest) SecurityBufferOffset ¶
func (p SessionSetupRequest) SecurityBufferOffset() uint16
func (SessionSetupRequest) SecurityMode ¶
func (p SessionSetupRequest) SecurityMode() NegotiateSigning
func (SessionSetupRequest) SetBuffer ¶
func (p SessionSetupRequest) SetBuffer(v []byte)
func (SessionSetupRequest) SetCapabilities ¶
func (p SessionSetupRequest) SetCapabilities(v Capabilities)
func (SessionSetupRequest) SetChannel ¶
func (p SessionSetupRequest) SetChannel(v uint32)
func (SessionSetupRequest) SetFlags ¶
func (p SessionSetupRequest) SetFlags(v SessionFlags)
func (SessionSetupRequest) SetPreviousSessionId ¶
func (p SessionSetupRequest) SetPreviousSessionId(v uint64)
func (SessionSetupRequest) SetSecurityBufferLength ¶
func (p SessionSetupRequest) SetSecurityBufferLength(v uint16)
func (SessionSetupRequest) SetSecurityBufferOffset ¶
func (p SessionSetupRequest) SetSecurityBufferOffset(v uint16)
func (SessionSetupRequest) SetSecurityMode ¶
func (p SessionSetupRequest) SetSecurityMode(v NegotiateSigning)
func (SessionSetupRequest) SetStructureSize ¶
func (p SessionSetupRequest) SetStructureSize()
func (SessionSetupRequest) StructureSize ¶
func (p SessionSetupRequest) StructureSize() uint16
type SessionSetupResponse ¶
type SessionSetupResponse []byte
MS-SMB2 2.2.6 SMB2 SESSION_SETUP Response
func (SessionSetupResponse) Buffer ¶
func (p SessionSetupResponse) Buffer() []byte
func (SessionSetupResponse) IsInvalid ¶
func (p SessionSetupResponse) IsInvalid() bool
func (SessionSetupResponse) SecurityBufferLength ¶
func (p SessionSetupResponse) SecurityBufferLength() uint16
func (SessionSetupResponse) SecurityBufferOffset ¶
func (p SessionSetupResponse) SecurityBufferOffset() uint16
func (SessionSetupResponse) SessionFlags ¶
func (p SessionSetupResponse) SessionFlags() SessionSetupSessionFlags
func (SessionSetupResponse) SetBuffer ¶
func (p SessionSetupResponse) SetBuffer(v []byte)
func (SessionSetupResponse) SetSecurityBufferLength ¶
func (p SessionSetupResponse) SetSecurityBufferLength(v uint16)
func (SessionSetupResponse) SetSecurityBufferOffset ¶
func (p SessionSetupResponse) SetSecurityBufferOffset(v uint16)
func (SessionSetupResponse) SetSessionFlags ¶
func (p SessionSetupResponse) SetSessionFlags(v SessionSetupSessionFlags)
func (SessionSetupResponse) SetStructureSize ¶
func (p SessionSetupResponse) SetStructureSize()
func (SessionSetupResponse) StructureSize ¶
func (p SessionSetupResponse) StructureSize() uint16
type SessionSetupSessionFlags ¶
type SessionSetupSessionFlags uint16
const ( // MS-SMB2 - v20211006 page 57/481 // MS-SMB2 - v20230920 page 59/488 SMB2_SESSION_FLAG_IS_GUEST SessionSetupSessionFlags = 0x0001 SMB2_SESSION_FLAG_IS_NULL SessionSetupSessionFlags = 0x0002 SMB2_SESSION_FLAG_ENCRYPT_DATA SessionSetupSessionFlags = 0x0004 )
type SigningCapability ¶
type SigningCapability []byte
func (SigningCapability) SetSigningAlgorithmCount ¶
func (c SigningCapability) SetSigningAlgorithmCount(v uint16)
func (SigningCapability) SetSigningAlgorithms ¶
func (c SigningCapability) SetSigningAlgorithms(v []SingingAlgorithm)
func (SigningCapability) SigningAlgorithmCount ¶
func (c SigningCapability) SigningAlgorithmCount() uint16
func (SigningCapability) SigningAlgorithms ¶
func (c SigningCapability) SigningAlgorithms() []SingingAlgorithm
type SingingAlgorithm ¶
type SingingAlgorithm uint16
const ( // MS-SMB2 - v20211006 page 51/481 SMB2_SIGNING_ALGORITHM_HMAC_SHA256 SingingAlgorithm = 0x0000 SMB2_SIGNING_ALGORITHM_AES_CMAC SingingAlgorithm = 0x0001 SMB2_SIGNING_ALGORITHM_AES_GMAC SingingAlgorithm = 0x0002 )
type TransportCapability ¶
type TransportCapability []byte
func (TransportCapability) Capabilities ¶
func (c TransportCapability) Capabilities() TransportFlag
func (TransportCapability) SetCapabilities ¶
func (c TransportCapability) SetCapabilities(f TransportFlag)
type TransportFlag ¶
type TransportFlag uint32
const ( // MS-SMB2 - v20211006 page 50/481 SMB2_ACCEPT_TRANSPORT_LEVEL_SECURITY TransportFlag = 0x00000001 )
Source Files ¶
Click to show internal directories.
Click to hide internal directories.