jwsprovider

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 24, 2023 License: MPL-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type JWSProvider

type JWSProvider interface {
	Sign(ctx context.Context, token []byte) ([]byte, error)
	Verify(ctx context.Context, token []byte) error
	GetKeySet(ctx context.Context) ([]byte, error)
}

JWSProvider is used to sign and verify JWT payloads

type MockJWSProvider

type MockJWSProvider struct {
	mock.Mock
}

MockJWSProvider is an autogenerated mock type for the JWSProvider type

func NewMockJWSProvider

func NewMockJWSProvider(t mockConstructorTestingTNewMockJWSProvider) *MockJWSProvider

NewMockJWSProvider creates a new instance of MockJWSProvider. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*MockJWSProvider) GetKeySet

func (_m *MockJWSProvider) GetKeySet(ctx context.Context) ([]byte, error)

GetKeySet provides a mock function with given fields: ctx

func (*MockJWSProvider) Sign

func (_m *MockJWSProvider) Sign(ctx context.Context, token []byte) ([]byte, error)

Sign provides a mock function with given fields: ctx, token

func (*MockJWSProvider) Verify

func (_m *MockJWSProvider) Verify(ctx context.Context, token []byte) error

Verify provides a mock function with given fields: ctx, token

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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