verifier

package
v0.32.0 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2026 License: Apache-2.0 Imports: 9 Imported by: 10

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	RSA     []*scy.Resource `json:",omitempty" yaml:"RSA,omitempty"`
	HMAC    *scy.Resource   `json:",omitempty" yaml:"HMAC,omitempty"`
	CertURL string          `json:",omitempty" yaml:"CertURL,omitempty"`
	Rules   []*Rule         `json:",omitempty" yaml:"Rules,omitempty"`
}

type Rule added in v0.32.0

type Rule struct {
	Resource  []string        `json:",omitempty" yaml:"Resource,omitempty"`
	Algorithm string          `json:",omitempty" yaml:"Algorithm,omitempty"`
	RSA       []*scy.Resource `json:",omitempty" yaml:"RSA,omitempty"`
	HMAC      *scy.Resource   `json:",omitempty" yaml:"HMAC,omitempty"`
}

type Service

type Service struct {
	// contains filtered or unexported fields
}

func New

func New(config *Config) *Service

func (*Service) Init

func (s *Service) Init(ctx context.Context) error

func (*Service) ValidaToken added in v0.3.2

func (s *Service) ValidaToken(ctx context.Context, tokenString string) (*jwt.Token, error)

func (*Service) Validate

func (s *Service) Validate(ctx context.Context, tokenString string) (*jwt.Token, error)

Validate checks if jwt token is valid

func (*Service) VerifyClaims added in v0.2.0

func (s *Service) VerifyClaims(ctx context.Context, tokenString string) (*sjwt.Claims, error)

Jump to

Keyboard shortcuts

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