jwt

package
v0.0.0-...-c9eef47 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2018 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Signature

func Signature(header string, playload string, privatekey string) (string, error)

func Token

func Token(file string) (string, error)

Types

type EcdsaSignature

type EcdsaSignature struct {
	R, S *big.Int
}

type JwtApple

type JwtApple struct {
	TeamId     string `json:"teamid"`
	PrivateKey string `json:"privatekey"`
}

type JwtHeader

type JwtHeader struct {
	Alg string `json:"alg"`
	Kid string `json:"kid"`
}

func (JwtHeader) Base64Content

func (h JwtHeader) Base64Content() (string, error)

type JwtPlayload

type JwtPlayload struct {
	Iss string `json:"iss"`
	Iat int64  `json:"iat"`
	Exp int64  `json:"exp"`
}

func (JwtPlayload) Base64Content

func (p JwtPlayload) Base64Content() (string, error)

type Toml

type Toml struct {
	Header   JwtHeader
	Playload JwtPlayload
	Apple    JwtApple
}

Jump to

Keyboard shortcuts

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