signature

package
v0.0.0-...-9935dc6 Latest Latest
Warning

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

Go to latest
Published: Apr 9, 2019 License: BSD-3-Clause Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CheckTLSSignatureResult

type CheckTLSSignatureResult struct {
	Valid       bool
	ExpireAfter time.Duration
	InitTime    time.Time
}

type Signer

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

func NewSigner

func NewSigner(appId int, accountType int, privKeyStr string) (*Signer, error)

func (*Signer) Sign

func (s *Signer) Sign(identifier string, expireAfter time.Duration) (TLSSignature, error)

func (*Signer) Verify

func (s *Signer) Verify(urlSig string, identifier string) (CheckTLSSignatureResult, error)

type TLSSignature

type TLSSignature struct {
	Valid      bool
	UrlSig     string
	ExpireTime time.Time
	InitTime   time.Time
}

Jump to

Keyboard shortcuts

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