Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewSignatureChecker ¶
func NewSignatureChecker(publicKey string) (*SignatureChecker, *Error)
NewSignatureChecker creates a new SignatureChecker. Please do not create a SignatureChecker directly. "publicKey" - RSA public key
Types ¶
type SignatureChecker ¶
type SignatureChecker struct {
// contains filtered or unexported fields
}
SignatureChecker is a special crypto component to verify signature of data. It uses x.509 specification for RSA protocol. A valid RSA public key should be provided. This component is independent.
func (SignatureChecker) CheckSignature ¶
func (checker SignatureChecker) CheckSignature(data, signature string) *Error
CheckSignature verifies the signature of a "data" string with "signature" by RSASSA-PKCS1-v1_5 scheme. "data" - string to verify "signature" - string containing the signature of data that was signed with the private key of the developer.
Click to show internal directories.
Click to hide internal directories.