s2s

package
v0.0.0-...-d69ff1e Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2025 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HTTPSignatureTransport

type HTTPSignatureTransport struct {
	Base http.RoundTripper

	Key   crypto.PrivateKey
	Actor *vocab.Actor
	// contains filtered or unexported fields
}

func New

func New(initFns ...OptionFn) *HTTPSignatureTransport

func (*HTTPSignatureTransport) RoundTrip

func (s *HTTPSignatureTransport) RoundTrip(req *http.Request) (*http.Response, error)

RoundTrip dispatches the received request after signing it

type OptionFn

type OptionFn func(transport *HTTPSignatureTransport) error

func WithActor

func WithActor(act *vocab.Actor, prv crypto.PrivateKey) OptionFn

func WithLogger

func WithLogger(l lw.Logger) OptionFn

func WithTransport

func WithTransport(tr http.RoundTripper) OptionFn

Jump to

Keyboard shortcuts

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