mirror of
https://github.com/xiaoqidun/ofdgo.git
synced 2026-10-30 01:27:26 +08:00
1 parent
5e0da3da28
commit
ee6c9f6a16
82 files changed
+4316
-4310
No files matched your search
@@ -37,6 +37,13 @@ import (
|
||||
"github.com/emmansun/gmsm/smx509"
|
||||
)
|
||||
|
||||
// signatureWriteKey 已验证签署身份
|
||||
type signatureWriteKey struct {
|
||||
cert *smx509.Certificate
|
||||
method string
|
||||
digest string
|
||||
}
|
||||
|
||||
// ParseSignatureIdentity 解析签署私钥和证书,并检查公私钥对应关系
|
||||
// 支持普通PKCS8、SEC1、PKCS1以及加密PKCS8,不支持传统加密PEM
|
||||
// 不加载系统信任或暗中信任该证书,返回的SM2/RSA私钥同时实现crypto.Decrypter
|
||||
@@ -97,13 +104,6 @@ func ParseSignatureIdentity(certificate, privateKey []byte, password ...[]byte)
|
||||
return signer, bytes.Clone(cert.Raw), nil
|
||||
}
|
||||
|
||||
// signatureWriteKey 已验证签署身份
|
||||
type signatureWriteKey struct {
|
||||
cert *smx509.Certificate
|
||||
method string
|
||||
digest string
|
||||
}
|
||||
|
||||
// signatureWriteIdentity 检查签署身份、证书信任与印章授权
|
||||
// 制章证书按制章时间验证,不以签署时间代替制章时间
|
||||
// 入参: options 签署选项
|
||||
|
||||
Reference in new issue
Block a user