Documentation ¶
Index ¶
- Constants
- Variables
- func AppendString(filename, content string) error
- func Base64Encode(braw []byte) []byte
- func Between(v1, o1, v, o2, v2 string) bool
- func BufferWriteAppend(filename string, param string) error
- func Compare(v1, operator, v2 string) bool
- func CreateRandomString(len int) string
- func Exists(path string) bool
- func GetNowDate() string
- func GetNowDateTime() string
- func GetNowDateTimeReportName() string
- func GetNumberText(number int) string
- func GetRandomIntWithAll(min, max int) int
- func GetRandomIntWithMin(min, max int) int
- func GetRandomTips() string
- func GetYsoserial(payload, command, encodeType string) string
- func HexDecode(s string) []byte
- func HexEncode(s string) []byte
- func IsBlank(value string) bool
- func IsDir(path string) bool
- func IsNotBlank(value string) bool
- func IsSeverityMatchingCvssScore(severity string, score float64) string
- func IsURL(input string) bool
- func Mmh3Hash32(raw []byte) int32
- func OpenFile(fileName string) *os.File
- func ParseUrl(u *url.URL) *proto.UrlType
- func Pkcs5padding(ciphertext []byte, blockSize int, after int) []byte
- func RandFromChoices(n int, choices string) string
- func RandLetterNumbers(n int) string
- func RandLetters(n int) string
- func RandLowLetterNumber(n int) string
- func RandSleep(millisencond int)
- func RandomStr(randSource *rand.Rand, letterBytes string, n int) string
- func RandomUA() string
- func ReadFileLineByLine(filename string) ([]string, error)
- func ReadFromFile(filename string) ([]byte, error)
- func ReadFromPathOrURL(templatePath string) (data []byte, err error)
- func ReverseString(s string) string
- func Str2UTF8(str string) string
- func StringSliceContains(slice []string, item string) bool
- func Tcp(addr string, data []byte) ([]byte, error)
- func ToString(slice []string) string
- func UrlTypeToString(u *proto.UrlType) string
- func WriteFile(filename string, data []byte) error
- type Severity
- type StringSlice
- type Syncfile
- type Unzip
Constants ¶
View Source
const ( // URLDNS URLDNS = "URLDNS" // Click1 Click1 = "Click1" // Clojure Clojure = "Clojure" // CommonsBeanutils1 CommonsBeanutils1 = "CommonsBeanutils1" // CommonsBeanutils2 CommonsBeanutils2 = "CommonsBeanutils2" // CommonsCollections1 CommonsCollections1 = "CommonsCollections1" // CommonsCollections2 CommonsCollections2 = "CommonsCollections2" // CommonsCollections3 CommonsCollections3 = "CommonsCollections3" // CommonsCollections4 CommonsCollections4 = "CommonsCollections4" // CommonsCollections5 CommonsCollections5 = "CommonsCollections5" // CommonsCollections6 CommonsCollections6 = "CommonsCollections6" // CommonsCollections7 CommonsCollections7 = "CommonsCollections7" // CommonsCollections8 CommonsCollections8 = "CommonsCollections8" // CommonsCollections9 CommonsCollections9 = "CommonsCollections9" // CommonsCollections10 CommonsCollections10 = "CommonsCollections10" // CommonsCollections11 CommonsCollections11 = "CommonsCollections11" // CommonsCollections12 CommonsCollections12 = "CommonsCollections12" // CommonsCollectionsK1 CommonsCollectionsK1 = "CommonsCollectionsK1" // CommonsCollectionsK2 CommonsCollectionsK2 = "CommonsCollectionsK2" // Fastjson1 Fastjson1 = "Fastjson1" // Fastjson2 Fastjson2 = "Fastjson2" // Groovy1 Groovy1 = "Groovy1" // Jdk7u21 Jdk7u21 = "Jdk7u21" // Jdk8u20 Jdk8u20 = "Jdk8u20" // ROME ROME = "ROME" // ROME2 ROME2 = "ROME2" // ROME3 ROME3 = "ROME3" // Spring1 Spring1 = "Spring1" // Spring2 Spring2 = "Spring2" )
枚举
View Source
const ( Base64Type = "base64" HexType = "hex" )
View Source
const (
NEW_FILE_PERM = 0666
)
Variables ¶
Functions ¶
func AppendString ¶
AppendString appends the contents of the string to filename.
func BufferWriteAppend ¶
func CreateRandomString ¶
func GetNowDate ¶
func GetNowDate() string
func GetNowDateTime ¶
func GetNowDateTime() string
func GetNowDateTimeReportName ¶
func GetNowDateTimeReportName() string
func GetNumberText ¶
func GetRandomTips ¶
func GetRandomTips() string
func GetYsoserial ¶
func IsNotBlank ¶
func RandFromChoices ¶
RandFromChoices 从choices里面随机获取
func ReadFileLineByLine ¶
func ReadFromFile ¶
func ReadFromPathOrURL ¶
ReadFromPathOrURL reads and returns the contents of a file or url.
func ReverseString ¶
func StringSliceContains ¶
StringSliceContains checks if a string slice contains a string.
func UrlTypeToString ¶
Types ¶
type StringSlice ¶
type StringSlice []string
StringSlice is a slice of strings
func (StringSlice) GetKey ¶
func (stringSlice StringSlice) GetKey(value string) int
func (StringSlice) Modify ¶
func (stringSlice StringSlice) Modify(value string)
func (*StringSlice) Set ¶
func (stringSlice *StringSlice) Set(value string)
Set appends a value to the string slice.
func (StringSlice) String ¶
func (stringSlice StringSlice) String() string
type Syncfile ¶
func NewSyncfile ¶
Click to show internal directories.
Click to hide internal directories.