smbencryption

package
v0.0.0-...-c8c792b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 19, 2019 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package smbencryption defines structures and identifiers for SMB encryption.

Index

Constants

View Source
const (
	AES128CCM = 0x0001
	AES128GCM = 0x0002
)

Possible encryption ciphers.

Variables

This section is empty.

Functions

This section is empty.

Types

type Capabilities

type Capabilities []byte

Capabilities interprets a slice of bytes as a set of encryption capabilities during SMB 3.1.1 protocol negotiation.

https://docs.microsoft.com/en-us/openspecs/windows_protocols/ms-smb2/16693be7-2b27-4d3b-804b-f605bde5bcdd

func (Capabilities) CipherCount

func (c Capabilities) CipherCount() uint16

CipherCount returns the number of supported encryption ciphers.

func (Capabilities) Ciphers

func (c Capabilities) Ciphers() List

Ciphers returns the list of supported encryption ciphers.

func (Capabilities) SetCipherCount

func (c Capabilities) SetCipherCount(count uint16)

SetCipherCount sets the number of supported encryption ciphers.

type Cipher

type Cipher uint16

Cipher identifies a cryptographic cipher used for encryption.

https://docs.microsoft.com/en-us/openspecs/windows_protocols/ms-smb2/16693be7-2b27-4d3b-804b-f605bde5bcdd

func (Cipher) String

func (c Cipher) String() string

String returns a string representation of the encryption cipher.

type List

type List []byte

List interprets a slice of bytes as an SMB encryption cipher list.

func (List) Contains

func (k List) Contains(c Cipher) bool

Contains returns true if the list contains c.

func (List) Count

func (k List) Count() int

Count returns the number of ciphers present in the list.

func (List) Member

func (k List) Member(i int) Cipher

Member returns the list member at position i.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL