Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ParseAllowedProto ¶
ParseAllowedProto parses a curl --proto value and returns which protocols are allowed. Curl syntax: "=https" means only HTTPS; "http,https" or "+http" adds to defaults; "-http" removes from defaults. Returns (allowHTTP, allowHTTPS).
Types ¶
type DataValue ¶
type DataValue struct {
Value string
IsRaw bool // No @file expansion.
IsURLEncode bool // URL-encode the value (or file contents for @file/name@file forms).
}
DataValue represents a single data value with flags indicating how the value should be processed.
type Result ¶
type Result struct {
URL string
Method string
Headers []header
DataValues []DataValue
BasicAuth string
AWSSigv4 string
Bearer string
FormFields []formField
UploadFile string
Head bool
Insecure bool
Output string
RemoteName bool
RemoteHeaderName bool
FollowRedirects bool
MaxRedirects int
Timeout float64
ConnectTimeout float64
Proxy string
DoHURL string
HTTPVersion string
TLSVersion string
CACert string
Cert string
Key string
UnixSocket string
Ranges []string
Retry int
RetryDelay float64
GetFlag bool
Verbose int
Silent bool
UserAgent string
Referer string
Cookie string
HasContentType bool
HasAccept bool
AllowedProto string // raw --proto value, e.g. "=https" or "http,https"
}
Result is the intermediate representation of a parsed curl command.
Click to show internal directories.
Click to hide internal directories.