sign

package
v0.0.20 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2024 License: AGPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var VersionMismatchError = errors.New("sign version mismatch")

Functions

This section is empty.

Types

type Client added in v0.0.16

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

func NewSignClient added in v0.0.16

func NewSignClient(appinfo *auth.AppInfo, log func(string), signServers ...string) *Client

func (*Client) AddRequestHeader added in v0.0.16

func (c *Client) AddRequestHeader(header map[string]string)

func (*Client) AddSignServer added in v0.0.16

func (c *Client) AddSignServer(signServers ...string)

func (*Client) GetSignServer added in v0.0.16

func (c *Client) GetSignServer() []string

func (*Client) Sign added in v0.0.16

func (c *Client) Sign(cmd string, seq uint32, data []byte) (*Response, error)

type Instance added in v0.0.16

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

type Provider

type Provider interface {
	Sign(cmd string, seq uint32, data []byte) (*Response, error)
}

type Response added in v0.0.16

type Response struct {
	Platform string `json:"platform"`
	Version  string `json:"version"`
	Value    struct {
		Sign  string `json:"sign"`
		Extra string `json:"extra"`
		Token string `json:"token"`
	} `json:"value"`
}

type Status added in v0.0.16

type Status uint32
const (
	OK Status = iota
	Down
)

Jump to

Keyboard shortcuts

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