Learn about using Basic HTTP with Nuclei
request
block which specifies the start of the requests for the template.
redirects: true
in request details. 10 redirects are followed at maximum by default which should be good enough for most use cases. More fine grained control can be exercised over number of redirects followed by using max-redirects
field.{{
and end with }}
and are case-sensitive.
{{BaseURL}}
- This will replace on runtime in the request by the input URL as specified in the target file.
{{RootURL}}
- This will replace on runtime in the request by the root URL as specified in the target file.
{{Hostname}}
- Hostname variable is replaced by the hostname including port of the target on runtime.
{{Host}}
- This will replace on runtime in the request by the input host as specified in the target file.
{{Port}}
- This will replace on runtime in the request by the input port as specified in the target file.
{{Path}}
- This will replace on runtime in the request by the input path as specified in the target file.
{{File}}
- This will replace on runtime in the request by the input filename as specified in the target file.
{{Scheme}}
- This will replace on runtime in the request by protocol scheme as specified in the target file.
An example is provided below - https://example.com:443/foo/bar.php
Variable | Value |
---|---|
{{BaseURL}} | https://example.com:443/foo/bar.php |
{{RootURL}} | https://example.com:443 |
{{Hostname}} | example.com:443 |
{{Host}} | example.com |
{{Port}} | 443 |
{{Path}} | /foo |
{{File}} | bar.php |
{{Scheme}} | https |
status_code
will point to the effective status code of the current request/response pair in elaboration. Previous responses status codes are accessible by suffixing the attribute name with _n
, where n is the n-th ordered request 1-based. So if the template has four requests and we are currently at number 3:
status_code
: will refer to the response code of request number 3status_code_1
and status_code_2
will refer to the response codes of the sequential responses number one and twostatus_code_1
, status_code_3
, andbody_2
:
.git/config
file mentioned above is as follows: