Versions in this module Expand all Collapse all v1 v1.0.0 May 19, 2024 v0 v0.0.1 Dec 12, 2022 Changes in this version + func Decrypt(s string, key, iv []byte) ([]byte, error) + func Encrypt(key, plaintext, iv []byte) ([]byte, error) + func PKCS5Padding(src []byte, blockSize int) []byte + func PKCS5UnPadding(src []byte) []byte + type Config struct + HashIV string + HashKey string + MerchantID string + type Credit struct + CreditInst string + CreditRed string + Date string + MerchantID string + UseInfo string + type Invoice struct + InvoiceTransNo string + MerchantID string + MerchantOrderNo string + RandomNum string + TotalAmt int + type OrderCheckCode struct + Amt int + MerchantID string + MerchantOrderNo string + TradeNo string + type OrderCheckValue struct + Amt int + MerchantID string + MerchantOrderNo string + TimeStamp string + Version string + type Store struct + HashIV string + HashKey string + MerchantID string + func New(config Config) *Store + func (s *Store) CreditCheckCode(credit Credit) string + func (s *Store) InvoiceCheckCode(invoice Invoice) string + func (s *Store) OrderCheckCode(order OrderCheckCode) string + func (s *Store) OrderCheckValue(order OrderCheckValue) string + func (s *Store) TradeInfoDecrypter(data string) (string, error) + func (s *Store) TradeInfoEncrypter(tradeInfo interface{}) (string, error) + func (s *Store) TradeSha(tradeInfo string) string