Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PathSignatureValidator

type PathSignatureValidator interface {
	SignatureValid(method string, u *url.URL) bool
}

type PathSigner

type PathSigner interface {
	Sign(method string, path string, expires time.Time) string
}

type PathSignerValidator

type PathSignerValidator struct {
	Secret      string
	Clock       clock.Clock
	SigningKeys map[string]string
	ActiveKeyID string
}

func Validate

func Validate(signer *PathSignerValidator) *PathSignerValidator

func (*PathSignerValidator) Sign

func (signer *PathSignerValidator) Sign(method string, path string, expires time.Time) string

func (*PathSignerValidator) SignatureValid

func (signer *PathSignerValidator) SignatureValid(method string, u *url.URL) bool

Source Files