Author

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 21, 2020 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	KeySupplementary = []byte("[email protected]*") //密钥补充码
)

Functions

func AuthorizationCheck

func AuthorizationCheck(authCode string) (cnt int, username string, ok bool)

功能:检查校验授权码 输入:authCode:授权码 输出:cnt:授权数量

username:被授权用户名
ok:校验结果,true=通过,false=不通过

时间:2019年11月27日 作者:wang_jp

func AuthorizationCodeDecrypt

func AuthorizationCodeDecrypt(keycode, authCode string) (cnt int, username, mcode string, ok bool)

功能:授权码解码 输入:keycode:密钥

authCode:授权码

输出:cnt:授权数量

username:被授权用户名
mcode:从授权码中解析出来的被授权的机器码
bool:授权码解码结果,true=成功,false=失败

时间:2019年11月27日 作者:wang_jp

func AuthorizationCodeEncrypt

func AuthorizationCodeEncrypt(cnt int, username, mcode string) (string, bool)

功能:授权码编码 输入:cnt:授权数量

username:被授权用户名
mcode:机器码

输出:string:授权码

bool:机器码校验结果,true=成功,false=失败

时间:2019年11月27日 作者:wang_jp

func MachineCodeDecrypt

func MachineCodeDecrypt(mcode string) (string, string, bool)

功能:机器码解码 输入:机器码 输出:密钥,密文,密文的crc校验结果

func MachineCodeEncrypt

func MachineCodeEncrypt() string

功能:用网卡信息和硬盘信息生成机器码,并输出机器码 输出:机器码

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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