Documentation ¶
Overview ¶
**************************************************
** @Desc : This file for ... ** @Time : 2018-8-30 13:50 ** @Author : Joker ** @File : ACE_ECB ** @Last Modified by : Joker ** @Last Modified time: 2018-8-30 13:50 ** @Software: GoLand
***************************************************
**************************************************
** @Desc : This file for ... ** @Time : 2019/8/21 10:21 ** @Author : yuebin ** @File : date_time ** @Last Modified by : yuebin ** @Last Modified time: 2019/8/21 10:21 ** @Software: GoLand
***************************************************
**************************************************
** @Desc : generate login verify code image ** @Time : 2019/8/7 17:14 ** @Author : yuebin ** @File : login_verify_code ** @Last Modified by : yuebin ** @Last Modified time: 2019/8/7 17:14 ** @Software: GoLand
***************************************************
**************************************************
** @Desc : 获取一个md5的字符串 ** @Time : 2019/8/9 16:06 ** @Author : yuebin ** @File : md5 ** @Last Modified by : yuebin ** @Last Modified time: 2019/8/9 16:06 ** @Software: GoLand
***************************************************
**************************************************
** @Desc : This file for ... ** @Time : 2019/10/26 11:08 ** @Author : yuebin ** @File : sign_verify ** @Last Modified by : yuebin ** @Last Modified time: 2019/10/26 11:08 ** @Software: GoLand
***************************************************
**************************************************
** @Desc : This file for ... ** @Time : 2019/10/26 11:17 ** @Author : yuebin ** @File : sort_go ** @Last Modified by : yuebin ** @Last Modified time: 2019/10/26 11:17 ** @Software: GoLand
***************************************************
Index ¶
- Constants
- Variables
- func AesDecrypt(src, key []byte) []byte
- func AesEncrypt(src []byte, key string) []byte
- func GetBasicDateTime() string
- func GetDate() string
- func GetDateBeforeDays(days int) string
- func GetDateTimeBeforeDays(days int) string
- func GetDateTimeBeforeHours(hour int) string
- func GetDateTimeNot() string
- func GetMD5LOWER(s string) string
- func GetMD5Sign(params map[string]string, keys []string, paySecret string) string
- func GetMD5Upper(s string) string
- func GetNowTimesTamp() string
- func Md5Verify(params map[string]string, paySecret string) bool
- func New() string
- func NewECBDecrypter(b cipher.Block) cipher.BlockMode
- func NewECBEncrypter(b cipher.Block) cipher.BlockMode
- func NewLen(length int) string
- func NewLenChars(length int, chars []byte) string
- func PKCS5Padding(ciphertext []byte, blockSize int) []byte
- func PKCS5UnPadding(origData []byte) []byte
- func SortMap(m map[string]string) []string
- type Image
Constants ¶
const ( // Standard length of uniuri string to achive ~95 bits of entropy. StdLen = 16 // Length of uniurl string to achive ~119 bits of entropy, closest // to what can be losslessly converted to UUIDv4 (122 bits). UUIDLen = 20 )
Variables ¶
var StdChars = []byte("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789")
Functions ¶
func AesDecrypt ¶
aes解码 crypted:要加密的字符串 key:用来加密的密钥 密钥长度可以是128bit、192bit、256bit中的任意一个 16位key对应128bit
func GetBasicDateTime ¶
func GetBasicDateTime() string
func GetDateBeforeDays ¶
func GetDateTimeBeforeDays ¶
func GetDateTimeBeforeHours ¶
func GetDateTimeNot ¶
func GetDateTimeNot() string
func GetNowTimesTamp ¶
func GetNowTimesTamp() string
func NewECBDecrypter ¶
NewECBDecrypter returns a BlockMode which decrypts in electronic code book mode, using the given Block.
func NewECBEncrypter ¶
NewECBEncrypter returns a BlockMode which encrypts in electronic code book mode, using the given Block.