添加文件: api_key.go

This commit is contained in:
renzhiyuan 2026-07-21 18:16:24 +08:00
parent 9c6cf762cc
commit 18462ef94a
1 changed files with 15 additions and 0 deletions

15
api_key.go Normal file
View File

@ -0,0 +1,15 @@
package xyshanghai
// APIKey 存储SM4密钥和SM3盐值
type APIKey struct {
SM4Key []byte
SM3Salt []byte
}
// NewAPIKey 创建APIKey实例
func NewAPIKey(sm4Key, sm3Salt []byte) *APIKey {
return &APIKey{
SM4Key: sm4Key,
SM3Salt: sm3Salt,
}
}