helpers

package
v0.0.0-...-96bc9f9 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrBadJSONPayload       = errors.New("bad json payload")
	ErrResponseBadSignature = errors.New("bad response signature")
)

Functions

func GetJWSKID

func GetJWSKID(payload []byte) (string, error)

func ParseJWS

func ParseJWS(response []byte, history []json.RawMessage) (msg []byte, err error)

func PrepareJWS

func PrepareJWS(req map[string]interface{}, kid string, sk ed25519.PrivateKey) ([]byte, error)

func PrepareRecipients

func PrepareRecipients(recipients, excludedDevices []string, api RestTransport) ([]string, error)

Types

type RestTransport

type RestTransport interface {
	Get(path string) ([]byte, error)
}

Jump to

Keyboard shortcuts

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