oauth2

package
v0.0.0-...-2583610 Latest Latest
Warning

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

Go to latest
Published: May 31, 2024 License: Apache-2.0, BSD-3-Clause Imports: 2 Imported by: 0

README

This oauth2 folder contains a oauth2 package with a partial client OAuth2 implementation.

It has been copied over from the original for our use. A lot of the original code and dependencies have been deleted, and the rest reshuffled.

Original Project: Go OAuth2 - pkg.go.dev/golang.org/x/oauth2

Note: The original authors are not aware of this fork, and do not endorse it in any way.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Transport

type Transport struct {
	// Source supplies the token to add to outgoing requests'
	// Authorization headers.
	Source TokenSource

	// Base is the base RoundTripper used to make HTTP requests.
	// If nil, http.DefaultTransport is used.
	Base http.RoundTripper
}

Transport is an http.RoundTripper that makes OAuth 2.0 HTTP requests, wrapping a base RoundTripper and adding an Authorization header with a token from the supplied Sources.

Transport is a low-level mechanism. Most code will use the higher-level Config.Client method instead.

func (*Transport) RoundTrip

func (t *Transport) RoundTrip(req *http.Request) (*http.Response, error)

RoundTrip authorizes and authenticates the request with an access token from Transport's Source.

Directories

Path Synopsis
Package internal contains support packages for oauth2 package.
Package internal contains support packages for oauth2 package.

Jump to

Keyboard shortcuts

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