Documentation ¶
Index ¶
- Constants
- type BasicHttpAuthState
- type BasicHttpAuthenticator
- func (a *BasicHttpAuthenticator) Authenticate(req *http.Request, resp *http.Response) error
- func (a *BasicHttpAuthenticator) IsComplete() bool
- func (a *BasicHttpAuthenticator) IsConnectionBased() bool
- func (a *BasicHttpAuthenticator) PreAuthenticate(req *http.Request) error
- func (a *BasicHttpAuthenticator) Reset()
- type DialFunc
- type DigestHeaders
- type DigestHttpAuthState
- type DigestHttpAuthenticator
- func (a *DigestHttpAuthenticator) Authenticate(req *http.Request, resp *http.Response) error
- func (a *DigestHttpAuthenticator) IsComplete() bool
- func (a *DigestHttpAuthenticator) IsConnectionBased() bool
- func (a *DigestHttpAuthenticator) PreAuthenticate(req *http.Request) error
- func (a *DigestHttpAuthenticator) Reset()
- type Error
- type HttpAuthState
- type HttpAuthenticator
- type NTLMHttpAuthState
- type NTLMHttpAuthenticator
- func (a *NTLMHttpAuthenticator) Authenticate(req *http.Request, resp *http.Response) error
- func (a *NTLMHttpAuthenticator) IsComplete() bool
- func (a *NTLMHttpAuthenticator) IsConnectionBased() bool
- func (a *NTLMHttpAuthenticator) PreAuthenticate(req *http.Request) error
- func (a *NTLMHttpAuthenticator) Reset()
- type ProxyAuthTransport
- type UpstreamProxyConfig
Constants ¶
View Source
const HTTP_STAT_LINE_LENGTH = 12
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BasicHttpAuthState ¶
type BasicHttpAuthState int
const ( BASIC_HTTP_AUTH_STATE_CHALLENGE_RECEIVED BasicHttpAuthState = iota BASIC_HTTP_AUTH_STATE_RESPONSE_GENERATED )
type BasicHttpAuthenticator ¶
type BasicHttpAuthenticator struct {
// contains filtered or unexported fields
}
func (*BasicHttpAuthenticator) Authenticate ¶
func (*BasicHttpAuthenticator) IsComplete ¶
func (a *BasicHttpAuthenticator) IsComplete() bool
func (*BasicHttpAuthenticator) IsConnectionBased ¶
func (a *BasicHttpAuthenticator) IsConnectionBased() bool
func (*BasicHttpAuthenticator) PreAuthenticate ¶
func (a *BasicHttpAuthenticator) PreAuthenticate(req *http.Request) error
func (*BasicHttpAuthenticator) Reset ¶
func (a *BasicHttpAuthenticator) Reset()
type DialFunc ¶
func NewProxyDialFunc ¶
func NewProxyDialFunc(config *UpstreamProxyConfig) DialFunc
type DigestHeaders ¶
type DigestHeaders struct { Realm string Qop string Method string Nonce string Opaque string Algorithm string HA1 string HA2 string Cnonce string Uri string Nc int16 Username string Password string }
func (*DigestHeaders) ApplyAuth ¶
func (d *DigestHeaders) ApplyAuth(req *http.Request)
ApplyAuth adds proper auth header to the passed request
type DigestHttpAuthState ¶
type DigestHttpAuthState int
const ( DIGEST_HTTP_AUTH_STATE_CHALLENGE_RECEIVED DigestHttpAuthState = iota DIGEST_HTTP_AUTH_STATE_RESPONSE_GENERATED )
type DigestHttpAuthenticator ¶
type DigestHttpAuthenticator struct {
// contains filtered or unexported fields
}
func (*DigestHttpAuthenticator) Authenticate ¶
func (*DigestHttpAuthenticator) IsComplete ¶
func (a *DigestHttpAuthenticator) IsComplete() bool
func (*DigestHttpAuthenticator) IsConnectionBased ¶
func (a *DigestHttpAuthenticator) IsConnectionBased() bool
func (*DigestHttpAuthenticator) PreAuthenticate ¶
func (a *DigestHttpAuthenticator) PreAuthenticate(req *http.Request) error
func (*DigestHttpAuthenticator) Reset ¶
func (a *DigestHttpAuthenticator) Reset()
type HttpAuthState ¶
type HttpAuthState int
const ( HTTP_AUTH_STATE_UNCHALLENGED HttpAuthState = iota HTTP_AUTH_STATE_CHALLENGED HTTP_AUTH_STATE_FAILURE HTTP_AUTH_STATE_SUCCESS )
type HttpAuthenticator ¶
type HttpAuthenticator interface { PreAuthenticate(req *http.Request) error Authenticate(req *http.Request, resp *http.Response) error IsConnectionBased() bool IsComplete() bool Reset() }
func NewHttpAuthenticator ¶
func NewHttpAuthenticator(resp *http.Response, username, password string) (HttpAuthenticator, error)
type NTLMHttpAuthState ¶
type NTLMHttpAuthState int
const ( NTLM_HTTP_AUTH_STATE_CHALLENGE_RECEIVED NTLMHttpAuthState = iota NTLM_HTTP_AUTH_STATE_RESPONSE_TYPE1_GENERATED NTLM_HTTP_AUTH_STATE_RESPONSE_TYPE3_GENERATED )
type NTLMHttpAuthenticator ¶
type NTLMHttpAuthenticator struct {
// contains filtered or unexported fields
}
func (*NTLMHttpAuthenticator) Authenticate ¶
func (*NTLMHttpAuthenticator) IsComplete ¶
func (a *NTLMHttpAuthenticator) IsComplete() bool
func (*NTLMHttpAuthenticator) IsConnectionBased ¶
func (a *NTLMHttpAuthenticator) IsConnectionBased() bool
func (*NTLMHttpAuthenticator) PreAuthenticate ¶
func (a *NTLMHttpAuthenticator) PreAuthenticate(req *http.Request) error
func (*NTLMHttpAuthenticator) Reset ¶
func (a *NTLMHttpAuthenticator) Reset()
type ProxyAuthTransport ¶
type ProxyAuthTransport struct { *http.Transport Dial DialFunc Username string Password string Authenticator HttpAuthenticator // contains filtered or unexported fields }
ProxyAuthTransport provides support for proxy authentication when doing plain HTTP by tapping into HTTP conversation and adding authentication headers to the requests when requested by server
func NewProxyAuthTransport ¶
func NewProxyAuthTransport(rawTransport *http.Transport) (*ProxyAuthTransport, error)
type UpstreamProxyConfig ¶
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
go-ntlm
|
|
ntlm
Package NTLM implements the interfaces used for interacting with NTLMv1 and NTLMv2.
|
Package NTLM implements the interfaces used for interacting with NTLMv1 and NTLMv2. |
ntlm/md4
Package md4 implements the MD4 hash algorithm as defined in RFC 1320.
|
Package md4 implements the MD4 hash algorithm as defined in RFC 1320. |
Click to show internal directories.
Click to hide internal directories.