Documentation ¶
Index ¶
- func EncryptMailMessage(key, body []byte) ([]byte, error)
- func EncryptRC4(data []byte, ciph *CipherRC4) []byte
- func FileExists(filename string) bool
- func FileStringReplace(FilePath string, Original string, Replace string) error
- func FileStringReplaceRegEx(FilePath string, RegEx string, Replace string) error
- func FileWriteBytes(FilePath string, Data []byte) error
- func FolderExist(path string) (bool, error)
- func GenerateApiError(w http.ResponseWriter, message string, data map[string]interface{}, code int)
- func GenerateApiErrorJson(message string, data map[string]interface{}) string
- func GenerateApiRespond(w http.ResponseWriter, status bool, message string, ...)
- func GenerateApiRespondJson(status bool, message string, data map[string]interface{}) string
- func GenerateUrlHash() string
- func GetMD5Hash(text string) string
- func GetMD5HashByte(text []byte) string
- func GetProxyDial(proxyModel *ProxyModel) proxy.Dialer
- func GetRequest(url string) ([]byte, int, error)
- func GetRequestTimeout(url string, timeout int, token string) ([]byte, int, error)
- func GetRequestWithToken(url string, token string) ([]byte, int, error)
- func InsertIntoString(s string, interval int, sep rune) string
- func MakeSecureString(text string) string
- func MattermostSendMessage(url, hook, message string, isCode bool, warning bool, proxyModel *ProxyModel) (string, error)
- func Message(status bool, message string) map[string]interface{}
- func PgpDecryptMessage(text string, key string, pass string) (string, error)
- func PgpEncrypt(publicKeyring string, secretString string) (string, error)
- func PgpEncryptMessage(key, body []byte) ([]byte, error)
- func RandIntBytes(n int) string
- func RandStringBytes(n int) string
- func RandStringBytesAllLower(n int) string
- func Respond(w http.ResponseWriter, data map[string]interface{})
- func ReverseFloat64(input []float64) []float64
- func ReverseInts(input []int) []int
- func ReverseStrings(input []string) []string
- func RunCMD(Command string, Home string) (string, error)
- func SendGetTorRequest(url string) ([]byte, error)
- func SendPostTorRequest(url string, postData url.Values) ([]byte, error)
- func SliceHaveString(s []string, str string) bool
- func StringBase64Rc4(data string, keyString string) string
- func StringToFloat32(text string) (float32, error)
- func StringToFloat64(text string) (float64, error)
- func StringToUint(text string) (uint, error)
- func StringToUint64(text string) (uint64, error)
- type CipherRC4
- type KeySizeError
- type ProxyModel
- type RespondApi
- func (respond *RespondApi) Create(status bool, message string)
- func (respond *RespondApi) Respond(w http.ResponseWriter)
- func (respond *RespondApi) ReturnHashMap() map[string]interface{}
- func (respond *RespondApi) ReturnJson() string
- func (respond *RespondApi) SetCode(code int)
- func (respond *RespondApi) SetMessage(message string)
- func (respond *RespondApi) SetPayload(data map[string]interface{})
- func (respond *RespondApi) SetStatus(status bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EncryptMailMessage ¶
EncryptMailMessage encrypts a mail with given public key.
func EncryptRC4 ¶
func FileStringReplace ¶
func FileStringReplaceRegEx ¶
func FileWriteBytes ¶
func FolderExist ¶
func GenerateApiError ¶ added in v0.0.6
func GenerateApiError(w http.ResponseWriter, message string, data map[string]interface{}, code int)
func GenerateApiErrorJson ¶ added in v0.0.6
func GenerateApiRespond ¶ added in v0.0.6
func GenerateApiRespond(w http.ResponseWriter, status bool, message string, data map[string]interface{})
func GenerateApiRespondJson ¶ added in v0.0.6
func GenerateUrlHash ¶
func GenerateUrlHash() string
func GetMD5HashByte ¶
GetMD5Hash generate md5 hash from []byte
func GetProxyDial ¶ added in v0.1.0
func GetProxyDial(proxyModel *ProxyModel) proxy.Dialer
func GetRequestTimeout ¶ added in v0.0.9
func GetRequestWithToken ¶ added in v0.0.9
func MakeSecureString ¶
func MattermostSendMessage ¶
func PgpDecryptMessage ¶ added in v0.0.2
PgpDecryptMessage decrypt message with private key (password optional)
func PgpEncryptMessage ¶ added in v0.0.2
PgpEncryptMessage encrypt message with public pgp key
func RandIntBytes ¶
func RandStringBytes ¶
func RandStringBytesAllLower ¶ added in v0.0.8
func Respond ¶
func Respond(w http.ResponseWriter, data map[string]interface{})
Respond add headers to respond
func ReverseFloat64 ¶
func ReverseInts ¶
func ReverseStrings ¶
func SendGetTorRequest ¶
func SliceHaveString ¶ added in v0.0.3
func StringBase64Rc4 ¶ added in v0.1.0
StringBase64Rc4 encrypt string with key
func StringToFloat32 ¶
func StringToFloat64 ¶
func StringToUint ¶
func StringToUint64 ¶
Types ¶
type CipherRC4 ¶
type CipherRC4 struct {
// contains filtered or unexported fields
}
func NewCipherRC4 ¶
func (*CipherRC4) XorKeyStreamGeneric ¶
type KeySizeError ¶
type KeySizeError int
func (KeySizeError) Error ¶
func (k KeySizeError) Error() string
type ProxyModel ¶ added in v0.1.0
type RespondApi ¶ added in v0.0.6
type RespondApi struct {
// contains filtered or unexported fields
}
func (*RespondApi) Create ¶ added in v0.0.6
func (respond *RespondApi) Create(status bool, message string)
func (*RespondApi) Respond ¶ added in v0.0.6
func (respond *RespondApi) Respond(w http.ResponseWriter)
Return to browser
func (*RespondApi) ReturnHashMap ¶ added in v0.0.6
func (respond *RespondApi) ReturnHashMap() map[string]interface{}
func (*RespondApi) ReturnJson ¶ added in v0.0.6
func (respond *RespondApi) ReturnJson() string
func (*RespondApi) SetCode ¶ added in v0.0.7
func (respond *RespondApi) SetCode(code int)
Optional func
func (*RespondApi) SetMessage ¶ added in v0.0.6
func (respond *RespondApi) SetMessage(message string)
Optional func
func (*RespondApi) SetPayload ¶ added in v0.0.6
func (respond *RespondApi) SetPayload(data map[string]interface{})
Optional func
func (*RespondApi) SetStatus ¶ added in v0.0.6
func (respond *RespondApi) SetStatus(status bool)
Optional func
Click to show internal directories.
Click to hide internal directories.