utils

package
v1.1.6 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2021 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Name    = "flowdownloader"
	Version = "1.1.6"
	Author  = "Gianluca 'Matrix86' Braga"
)

Variables

This section is empty.

Functions

func AesDecrypt

func AesDecrypt(key []byte, encrypted []byte, iv []byte) (decoded []byte, err error)

func DecryptFileAppend

func DecryptFileAppend(output *os.File, file string, key []byte, iv []byte) error

func FileAppend

func FileAppend(output *os.File, file string) error

func GetBaseUrl

func GetBaseUrl(url string) string

func GetFileFromUrl

func GetFileFromUrl(url string) string

func GetMD5Hash added in v1.1.2

func GetMD5Hash(text string) string

func HttpRequest

func HttpRequest(method string, url string, cookies []*http.Cookie, referer string) (*http.Response, error)

func ParseCookieFile

func ParseCookieFile(filename string) ([]*http.Cookie, error)

ParseCookieFile transforms JSON file in slice of http.Cookie

Types

type Cookies

type Cookies []struct {
	Domain         string  `json:"domain"`
	ExpirationDate float64 `json:"expirationDate,omitempty"`
	HostOnly       bool    `json:"hostOnly"`
	HTTPOnly       bool    `json:"httpOnly"`
	Name           string  `json:"name"`
	Path           string  `json:"path"`
	SameSite       string  `json:"sameSite"`
	Secure         bool    `json:"secure"`
	Session        bool    `json:"session"`
	StoreID        string  `json:"storeId"`
	Value          string  `json:"value"`
	ID             int     `json:"id"`
}

Cookies maps the json file exported from Chrome containing the cookies

Jump to

Keyboard shortcuts

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