httpDigestAuth

package module
v0.0.0-...-757f514 Latest Latest
Warning

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

Go to latest
Published: May 6, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

README

http-digest-auth-client

Go (golang) http digest authentication client.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DigestHeaders

type DigestHeaders struct {
	Realm     string
	Qop       string
	Method    string
	Nonce     string
	Opaque    string
	Algorithm string
	HA1       string
	HA2       string
	Cnonce    string
	Path      string
	Nc        int16
	Username  string
	Password  string
}

DigestHeaders tracks the state of authentication

func (*DigestHeaders) ApplyAuth

func (d *DigestHeaders) ApplyAuth(req *http.Request)

ApplyAuth adds proper auth header to the passed request

func (*DigestHeaders) Auth

func (d *DigestHeaders) Auth(username string, password string, uri string) (*DigestHeaders, error)

Auth authenticates against a given URI

Jump to

Keyboard shortcuts

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