Documentation ¶
Index ¶
- type DingTalkCrypto
- func (c *DingTalkCrypto) CreateSignature(token, timestamp, nonce, msg string) string
- func (c *DingTalkCrypto) GetDecryptMsg(signature, timestamp, nonce, secretMsg string) (string, error)
- func (c *DingTalkCrypto) GetEncryptMsg(msg string) (map[string]string, error)
- func (c *DingTalkCrypto) GetEncryptMsgDetail(msg, timestamp, nonce string) (string, string, error)
- func (c *DingTalkCrypto) VerificationSignature(token, timestamp, nonce, msg, sigture string) bool
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DingTalkCrypto ¶
type DingTalkCrypto struct { Token string EncodingAESKey string SuiteKey string BKey []byte Block cipher.Block }
func NewDingTalkCrypto ¶
func NewDingTalkCrypto(token, encodingAESKey, suiteKey string) *DingTalkCrypto
func (*DingTalkCrypto) CreateSignature ¶
func (c *DingTalkCrypto) CreateSignature(token, timestamp, nonce, msg string) string
数据签名
func (*DingTalkCrypto) GetDecryptMsg ¶
func (c *DingTalkCrypto) GetDecryptMsg(signature, timestamp, nonce, secretMsg string) (string, error)
func (*DingTalkCrypto) GetEncryptMsg ¶
func (c *DingTalkCrypto) GetEncryptMsg(msg string) (map[string]string, error)
func (*DingTalkCrypto) GetEncryptMsgDetail ¶
func (c *DingTalkCrypto) GetEncryptMsgDetail(msg, timestamp, nonce string) (string, string, error)
func (*DingTalkCrypto) VerificationSignature ¶
func (c *DingTalkCrypto) VerificationSignature(token, timestamp, nonce, msg, sigture string) bool
验证数据签名
Click to show internal directories.
Click to hide internal directories.