Documentation ¶
Index ¶
- Variables
- func AddDelTag(delTime *time.Time, target string) string
- func AesDecrypt(encrypted string) (string, error)
- func AesEncrypt(origData string) (string, error)
- func DecodeString(base64Str string) (string, error)
- func GetDuplicate(c []string) []string
- func HasPrefix(s, prefix string, caseSensitive bool) bool
- func HasSuffix(s, suffix string, caseSensitive bool) bool
- func JoinUintSliceToString(s []uint, sep string) string
- func Md5String(data string) string
- func NewEncryptor(key []byte) *encryptor
- func NvlString(param *string) string
- func ParseAuditPlanName(tokenString string) (string, error)
- func RemoveDuplicate(c []string) []string
- func RemoveDuplicateUint(c []uint) []uint
- func Round(f float64, dec int) float64
- func SetSecretKey(key []byte) error
- func SupplementalQuotationMarks(s string) string
- type CustomClaimOption
- type JWT
- type Password
Constants ¶
This section is empty.
Variables ¶
View Source
var JWTSecretKey = []byte("secret")
View Source
var SecretKey = []byte("471F77D078C5994BD06B65B8B5B1935B")
Functions ¶
func AesDecrypt ¶
func AesEncrypt ¶
func DecodeString ¶
func GetDuplicate ¶
func JoinUintSliceToString ¶ added in v1.2202.0
sep example: ", "
func NewEncryptor ¶ added in v1.2206.0
func NewEncryptor(key []byte) *encryptor
func ParseAuditPlanName ¶
ParseAuditPlanName used by echo middleware which only verify api request to audit plan related.
func RemoveDuplicate ¶
func RemoveDuplicateUint ¶ added in v1.2209.0
func SetSecretKey ¶ added in v1.2203.0
func SupplementalQuotationMarks ¶ added in v1.2205.0
If there are no quotation marks (', ", `) at the beginning and end of the string, the string will be wrapped with "`" Need to be wary of the presence of "`" in the string do nothing if s is an empty string
Types ¶
type CustomClaimOption ¶
type CustomClaimOption interface {
// contains filtered or unexported methods
}
func WithAuditPlanName ¶
func WithAuditPlanName(name string) CustomClaimOption
Click to show internal directories.
Click to hide internal directories.