digest_auth_client

package
v1.0.8 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2022 License: GPL-2.0 Imports: 13 Imported by: 0

README

声明: 该包下的代码来源于 github.com/xinsnake/go-http-digest-auth-client

因有些bug需要修复,故在源码的基础上做了修复。

等问题修复后,将删除该包的代码。

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DigestRequest

type DigestRequest struct {
	Body       string
	Method     string
	Password   string
	URI        string
	Username   string
	Header     http.Header
	Auth       *authorization
	Wa         *wwwAuthenticate
	CertVal    bool
	HTTPClient *http.Client
}

func NewRequest

func NewRequest(username, password, method, uri, body string) DigestRequest

NewRequest creates a new DigestRequest object

func (*DigestRequest) Execute

func (dr *DigestRequest) Execute() (resp *http.Response, err error)

Execute initialise the request and get a response

func (*DigestRequest) UpdateRequest

func (dr *DigestRequest) UpdateRequest(username, password, method, uri, body string) *DigestRequest

UpdateRequest is called when you want to reuse an existing

DigestRequest connection with new request information

type DigestTransport

type DigestTransport struct {
	Password   string
	Username   string
	HTTPClient *http.Client
}

func NewTransport

func NewTransport(username, password string) DigestTransport

NewTransport creates a new DigestTransport object

func (*DigestTransport) RoundTrip

func (dt *DigestTransport) RoundTrip(req *http.Request) (resp *http.Response, err error)

RoundTrip implements the http.RoundTripper interface

Jump to

Keyboard shortcuts

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