tool

package
v0.0.0-...-f9b5f64 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	PublicKeyFilePath  = config.Viper.GetString("rsa.tiktok_message_encrypt_public_key")
	PrivateKeyFilePath = config.Viper.GetString("rsa.tiktok_message_decrypt_private_key")
)

Functions

func Base64Decode

func Base64Decode(src []byte) ([]byte, error)

func Base64Encode

func Base64Encode(src []byte) []byte

func Md5Encrypt

func Md5Encrypt(data string) string

func ReadKeyFromFile

func ReadKeyFromFile(filePath string) (string, error)

func RsaDecrypt

func RsaDecrypt(ciphertext []byte, privateKey string) ([]byte, error)

func RsaEncrypt

func RsaEncrypt(origData []byte, publicKey string) ([]byte, error)

func Sha256Encrypt

func Sha256Encrypt(data string, salt string) string

Types

This section is empty.

Jump to

Keyboard shortcuts

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