signers

package
v0.1.4-0...-328a6d7 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package signers 微信支付api v3 go http-client 签名生成器

Package signers 微信支付api v3 go http-client 签名生成器

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Sha256WithRsa

func Sha256WithRsa(source string, privateKey *rsa.PrivateKey) (signature string, err error)

Sha256WithRsa 通过私钥对字符串进行sha256rsa的方式加密,生成签名信息

Types

type Sha256WithRSASigner

type Sha256WithRSASigner struct {
	MchCertificateSerialNo string          // 商户证书序列号
	PrivateKey             *rsa.PrivateKey // 商户私钥
}

Sha256WithRSASigner Sha256WithRSA 签名器

func (*Sha256WithRSASigner) GetName

func (s *Sha256WithRSASigner) GetName() string

GetName 获取签名器的名称

func (*Sha256WithRSASigner) GetType

func (s *Sha256WithRSASigner) GetType() string

获取签名器的类型

func (*Sha256WithRSASigner) GetVersion

func (s *Sha256WithRSASigner) GetVersion() string

获取签名器的版本

func (*Sha256WithRSASigner) Sign

对信息使用Sha256WithRsa的方式进行签名

Jump to

Keyboard shortcuts

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