z1crypto

package module
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

README

z1crypto

介绍

golang for crypto

软件架构

软件架构说明

安装教程
  1. go get gitee.com/z1gotool/z1crypto
  2. go get gitee.com/z1gotool/z1crypto@1.0.0
  3. xxxx
使用说明
  1. read test/case_test.go
  2. xxxx
  3. xxxx
参与贡献
  1. Fork 本仓库
  2. 新建 Feat_xxx 分支
  3. 提交代码
  4. 新建 Pull Request
特技
  1. 使用 Readme_XXX.md 来支持不同的语言,例如 Readme_en.md, Readme_zh.md
  2. Gitee 官方博客 blog.gitee.com
  3. 你可以 https://gitee.com/explore 这个地址来了解 Gitee 上的优秀开源项目
  4. GVP 全称是 Gitee 最有价值开源项目,是综合评定出的优秀开源项目
  5. Gitee 官方提供的使用手册 https://gitee.com/help
  6. Gitee 封面人物是一档用来展示 Gitee 会员风采的栏目 https://gitee.com/gitee-stars/

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AesDecrypt

func AesDecrypt(encrypted, key string, ivs ...string) (ret string, err error)

func AesEncrypt

func AesEncrypt(plaintext, key string, ivs ...string) (ret string, err error)

func Base64Decode added in v1.2.0

func Base64Decode(base64Str string, inUrl ...bool) (msg string, err error)

func Base64Encode added in v1.2.0

func Base64Encode(msg string, inUrl ...bool) (base64Str string)

func Md5 added in v1.2.0

func Md5(str string) (encode string)

func PKCS5UnPadding added in v1.0.3

func PKCS5UnPadding(src []byte) []byte

PKCS5UnPadding用必要的数据来填充某个数据团,以用于AES块状密码。

func RsaDecrypt

func RsaDecrypt(ciphertextBase64, privateKeyStr string) (origData string, err error)

func RsaEncrypt

func RsaEncrypt(origDataStr, publicKeyStr string) (ciphertextBase64 string, err error)

func RsaKeyClean added in v1.2.0

func RsaKeyClean(key string) (base64 string)

Types

This section is empty.

Directories

Path Synopsis
test
rs

Jump to

Keyboard shortcuts

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