Documentation ¶
Index ¶
- Constants
- func HandleConnectionNegotiationClient(conn *net.TCPConn, serverAddr *net.TCPAddr, uname, pword string)
- func HandleConnectionNegotiationServer(conn *net.TCPConn, users map[string]string, udata chan DataUsage)
- func HandleMethodSelectionClient(req []byte) []byte
- func HandleMethodSelectionServer(req []byte) ([]byte, byte)
- func HandleRequestClient(rqst []byte, conn, connToServer *net.TCPConn, mCipher GFWCipher)
- func HandleRequestServer(rqst []byte, conn *net.TCPConn, mCipher GFWCipher, username string, ...) ([]byte, error)
- func NewAESCTRCipher(key []byte, initialVector []byte) (aESCTRCipher, error)
- func NewShiftCipher(key byte) shiftCipher
- type Authenticator
- type CustomAuthenticator
- type DataUsage
- type GFWCipher
- type GFWLogger
- type MethodSelectionRequest
- type MethodSelectionResponse
- type UnamePwordHandler
Constants ¶
View Source
const ( CipherTypeAES256 = iota CipherTypeSimple )
View Source
const ( AES256KEY = "Internat" InvalidPassword = "iNvaLIDpAsSwoRd" )
View Source
const ( INFO = iota DEBUG ERROR )
View Source
const ( AuthenticatingMethodNo = 0x00 AuthenticatingMethodGSSAPI = 0x01 AuthenticatingMethodUsernamePassword = 0x02 AuthenticatingMethodCustom = 0x0C AuthenticatingMethodNotSupported = 0xff )
View Source
const (
CipherTypeInUse = CipherTypeSimple
)
Variables ¶
This section is empty.
Functions ¶
func HandleRequestClient ¶
func HandleRequestServer ¶
func NewAESCTRCipher ¶
func NewShiftCipher ¶
func NewShiftCipher(key byte) shiftCipher
Types ¶
type Authenticator ¶
type CustomAuthenticator ¶
type CustomAuthenticator struct { }
type GFWLogger ¶
type GFWLogger struct {
// contains filtered or unexported fields
}
func (*GFWLogger) DisableTag ¶
type MethodSelectionRequest ¶
type MethodSelectionResponse ¶
type UnamePwordHandler ¶
type UnamePwordHandler struct { }
func (UnamePwordHandler) Authenticate ¶
func (h UnamePwordHandler) Authenticate(p []byte) ([]byte, bool, error)
Click to show internal directories.
Click to hide internal directories.