mirror of
https://github.com/Orange-OpenSource/hurl.git
synced 2024-11-23 20:12:09 +03:00
c6bc18570d
This is a feature provided by cURL that allows it to retrieve the username and password for a host from a .netrc file. https://curl.se/docs/manpage.html#-n
98 KiB
98 KiB
Grammar
Definitions
Short description:
- operator | denotes alternative,
- operator * denotes iteration (zero or more),
- operator + denotes iteration (one or more),
Syntax Grammar
General
request(used by entry)
method(used by request)
[A-Z]+
version(used by response)
HTTP/1.0
|HTTP/1.1
|HTTP/2
|HTTP
|HTTP/1.1
|HTTP/2
|HTTP
status(used by response)
[0-9]+
Sections
request-section(used by request)
response-section(used by response)
query-string-params-section(used by request-section)
form-params-section(used by request-section)
multipart-form-data-section(used by request-section)
(used by request-section)
captures-section(used by response-section)
asserts-section(used by response-section)
basic-auth-section(used by request-section)
options-section(used by request-section)
key-value(used by header, query-string-params-section, form-params-section, cookies-section, basic-auth-section, multipart-form-data-param)
multipart-form-data-param(used by multipart-form-data-section)
file-param(used by multipart-form-data-param)
file-value(used by file-param)
file-contenttype(used by file-value)
[a-zA-Z0-9/+-]+
capture(used by captures-section)
option(used by options-section)
lt*
(aws-sigv4-option|ca-certificate-option|client-certificate-option|client-key-option|compressed-option|connect-to-option|delay-option|follow-redirect-option|follow-redirect-trusted-option|http10-option|http11-option|http2-option|http3-option|insecure-option|ipv4-option|ipv6-option|max-redirs-option|netrc-option|netrc-file-option|netrc-optional-option|output-option|path-as-is-option|proxy-option|resolve-option|retry-option|retry-interval-option|skip-option|unix-socket-option|variable-option|verbose-option|very-verbose-option)
(aws-sigv4-option|ca-certificate-option|client-certificate-option|client-key-option|compressed-option|connect-to-option|delay-option|follow-redirect-option|follow-redirect-trusted-option|http10-option|http11-option|http2-option|http3-option|insecure-option|ipv4-option|ipv6-option|max-redirs-option|netrc-option|netrc-file-option|netrc-optional-option|output-option|path-as-is-option|proxy-option|resolve-option|retry-option|retry-interval-option|skip-option|unix-socket-option|variable-option|verbose-option|very-verbose-option)
aws-sigv4-option(used by option)
client-certificate-option(used by option)
client-key-option(used by option)
compressed-option(used by option)
connect-to-option(used by option)
delay-option(used by option)
follow-redirect-option(used by option)
follow-redirect-trusted-option(used by option)
http10-option(used by option)
http11-option(used by option)
http2-option(used by option)
http3-option(used by option)
insecure-option(used by option)
ipv4-option(used by option)
ipv6-option(used by option)
max-redirs-option(used by option)
netrc-option(used by option)
netrc-file-option(used by option)
netrc-optional-option(used by option)
output-option(used by option)
path-as-is-option(used by option)
proxy-option(used by option)
resolve-option(used by option)
retry-option(used by option)
retry-interval-option(used by option)
skip-option(used by option)
unix-socket-option(used by option)
variable-option(used by option)
verbose-option(used by option)
very-verbose-option(used by option)
variable-definition(used by variable-option)
boolean-option(used by compressed-option, follow-redirect-option, follow-redirect-trusted-option, http10-option, http11-option, http2-option, http3-option, insecure-option, ipv4-option, ipv6-option, netrc-option, netrc-optional-option, path-as-is-option, skip-option, verbose-option, very-verbose-option)
integer-option(used by delay-option, max-redirs-option, retry-option, retry-interval-option)
variable-value(used by variable-definition)
Query
status-query(used by query)
status
url-query(used by query)
url
header-query(used by query)
certificate-query(used by query)
(used by query)
body-query(used by query)
body
xpath-query(used by query)
jsonpath-query(used by query)
regex-query(used by query)
variable-query(used by query)
duration-query(used by query)
duration
sha256-query(used by query)
sha256
md5-query(used by query)
md5
bytes-query(used by query)
bytes
Predicates
predicate(used by assert)
predicate-func(used by predicate)
equal-predicate
|not-equal-predicate
|greater-predicate
|greater-or-equal-predicate
|less-predicate
|less-or-equal-predicate
|start-with-predicate
|end-with-predicate
|contain-predicate
|match-predicate
|exist-predicate
|is-empty-predicate
|include-predicate
|integer-predicate
|float-predicate
|boolean-predicate
|string-predicate
|collection-predicate
|date-predicate
|not-equal-predicate
|greater-predicate
|greater-or-equal-predicate
|less-predicate
|less-or-equal-predicate
|start-with-predicate
|end-with-predicate
|contain-predicate
|match-predicate
|exist-predicate
|is-empty-predicate
|include-predicate
|integer-predicate
|float-predicate
|boolean-predicate
|string-predicate
|collection-predicate
|date-predicate
equal-predicate(used by predicate-func)
not-equal-predicate(used by predicate-func)
greater-predicate(used by predicate-func)
greater-or-equal-predicate(used by predicate-func)
less-predicate(used by predicate-func)
less-or-equal-predicate(used by predicate-func)
start-with-predicate(used by predicate-func)
end-with-predicate(used by predicate-func)
contain-predicate(used by predicate-func)
match-predicate(used by predicate-func)
exist-predicate(used by predicate-func)
exists
is-empty-predicate(used by predicate-func)
isEmpty
include-predicate(used by predicate-func)
integer-predicate(used by predicate-func)
isInteger
float-predicate(used by predicate-func)
isFloat
boolean-predicate(used by predicate-func)
isBoolean
string-predicate(used by predicate-func)
isString
collection-predicate(used by predicate-func)
isCollection
date-predicate(used by predicate-func)
isDate
predicate-value(used by equal-predicate, not-equal-predicate, include-predicate)
Bytes
bytes(used by body)
xml(used by bytes)
< To Be Defined >
oneline-base64(used by start-with-predicate, end-with-predicate, predicate-value, bytes)
base64, [A-Z0-9+-= \n]+ ;
oneline-file(used by predicate-value, bytes)
oneline-hex(used by start-with-predicate, end-with-predicate, predicate-value, bytes)
Strings
quoted-string(used by variable-value, header-query, cookie-query, xpath-query, jsonpath-query, regex-query, variable-query, greater-predicate, greater-or-equal-predicate, less-predicate, less-or-equal-predicate, start-with-predicate, end-with-predicate, contain-predicate, match-predicate, predicate-value, jsonpath-filter, regex-filter, replace-filter, split-filter, xpath-filter)
quoted-string-content(used by quoted-string)
quoted-string-text(used by quoted-string-content)
~["\\]+
quoted-string-escaped-char(used by quoted-string-content)
key-string(used by key-value, file-param, capture, variable-value)
key-string-content(used by key-string)
key-string-text(used by key-string-content)
key-string-escaped-char(used by key-string-content)
value-string(used by request, key-value, aws-sigv4-option, client-certificate-option, client-key-option, connect-to-option, netrc-file-option, output-option, proxy-option, resolve-option, unix-socket-option)
value-string-content(used by value-string)
value-string-text(used by value-string-content)
~[#\n\\]+
value-string-escaped-char(used by value-string-content)
oneline-string(used by bytes)
oneline-string-content(used by oneline-string)
oneline-string-text(used by oneline-string-content)
~[#\n\\] ~`
oneline-string-escaped-char(used by oneline-string-content)
multiline-string(used by predicate-value, bytes)
multiline-string-type(used by multiline-string)
base64
|hex
|json
|xml
|graphql
|hex
|json
|xml
|graphql
multiline-string-content(used by multiline-string)
multiline-string-text(used by multiline-string-content)
~[\\]+ ~```
multiline-string-escaped-char(used by multiline-string-content)
filename(used by file-value, ca-certificate-option, oneline-file)
filename-content(used by filename)
filename-text(used by filename-content)
~[#; \n\\]+
filename-escaped-char(used by filename-content)
\ (;|#|[ ])
JSON
json-value(used by bytes, json-key-value, json-array)
json-object(used by json-value)
json-key-value(used by json-object)
json-array(used by json-value)
json-string(used by json-value, json-key-value)
json-string-content(used by json-string)
json-string-text(used by json-string-content)
~["\\]
json-string-escaped-char(used by json-string-content)
json-number(used by json-value)
Template / Expression
template(used by boolean-option, integer-option, predicate-value, quoted-string, key-string, value-string, oneline-string, multiline-string, filename, json-value, json-string)
expr(used by template)
variable-name(used by variable-definition, expr)
[A-Za-z] [A-Za-z_-0-9]*
Filter
count-filter(used by filter)
count
days-after-now-filter(used by filter)
daysAfterNow
days-before-now-filter(used by filter)
daysBeforeNow
decode-filter(used by filter)
decode
format-filter(used by filter)
format
html-escape-filter(used by filter)
htmlEscape
html-unescape-filter(used by filter)
htmlUnescape
jsonpath-filter(used by filter)
regex-filter(used by filter)
replace-filter(used by filter)
split-filter(used by filter)
to-date-filter(used by filter)
toDate
to-int-filter(used by filter)
toInt
url-decode-filter(used by filter)
urlDecode
url-encode-filter(used by filter)
urlEncode
xpath-filter(used by filter)
Lexical Grammar
boolean(used by boolean-option, variable-value, predicate-value, json-value)
true|false
null(used by variable-value, predicate-value, json-value)
null
alphanum(used by key-string-text)
[A-Za-z0-9]
integer(used by integer-option, variable-value, json-number, nth-filter, float, number)
float(used by variable-value, number)
number(used by greater-predicate, greater-or-equal-predicate, less-predicate, less-or-equal-predicate, predicate-value)
hexdigit(used by oneline-hex, unicode-char, json-string-escaped-char)
[0-9A-Fa-f]
fraction(used by json-number, float)
exponent(used by json-number)
sp(used by request, response, capture, assert, header-query, certificate-query, cookie-query, xpath-query, jsonpath-query, regex-query, variable-query, predicate, equal-predicate, not-equal-predicate, greater-predicate, greater-or-equal-predicate, less-predicate, less-or-equal-predicate, start-with-predicate, end-with-predicate, contain-predicate, match-predicate, include-predicate, expr, jsonpath-filter, nth-filter, regex-filter, replace-filter, split-filter, xpath-filter, lt)
[ \t]
lt(used by hurl-file, request, response, header, body, query-string-params-section, form-params-section, multipart-form-data-section, cookies-section, captures-section, asserts-section, basic-auth-section, options-section, file-param, capture, assert, option, aws-sigv4-option, ca-certificate-option, client-certificate-option, client-key-option, compressed-option, connect-to-option, delay-option, follow-redirect-option, follow-redirect-trusted-option, http10-option, http11-option, http2-option, http3-option, insecure-option, ipv4-option, ipv6-option, max-redirs-option, netrc-option, netrc-file-option, netrc-optional-option, output-option, path-as-is-option, proxy-option, resolve-option, retry-option, retry-interval-option, skip-option, unix-socket-option, variable-option, verbose-option, very-verbose-option, multiline-string)
comment(used by lt)
# ~[\n]*
regex(used by regex-query, match-predicate, regex-filter, replace-filter)
regex-content(used by regex)
regex-text(used by regex-content)
~[\n\/]+
regex-escaped-char(used by regex-content)
\ ~[\n]