sign

package
v1.0.1005 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

README

使用方法

import "github.com/deatil/lakego-doak/lakego/facade/sign"

signData := sign.Sign("md5").
    WithData("test", "测试测试").
    WithAppID("API123456").
    GetSignMap()

check, _ := sign.Check("md5").
    WithData(signData).
    WithTimeout(1000).
    CheckData()

data := sign.Check("md5").
    WithDatas(signData).
    GetDataWithoutSign()

signData2, _ := sign.Sign("md5").
    WithDatas(data).
    GetSignDataString()

checkData := sign.Check("md5").
    CheckSign(signData2, signData["sign"])

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Check

func Check(name string) *sign.Check

检测

func GetDefaultCrypt

func GetDefaultCrypt() string

默认签名

func GetDriver

func GetDriver(name string) (interfaces.Driver, map[string]any)

func NewCheck

func NewCheck() *sign.Check

检测

func NewSign

func NewSign() *sign.Sign

签名

func Register

func Register()

注册

func Sign

func Sign(name string) *sign.Sign

签名

Types

This section is empty.

Jump to

Keyboard shortcuts

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