Is your feature request related to a problem? Please describe.
with the addition of relative path support, we almost using it all the time while running nuclei, but as the templates are not in the current directory it becomes a problem when you want to list/find any targeted template, so adding flag support which will perform same ls like action in at installed template path would make it more useful.
Describe the solution you'd like
Suggested flag:-
ts - stands for template search.
example:-
This is same as ls -1 ~/nuclei-templates/
nuclei -ts
[WRN] Use with caution. You are responsible for your actions
[WRN] Developers assume no liability and are not responsible for any misuse or damage.
[INF] Searching for templates in /Users/bauthard/nuclei-templates/
LICENSE
README.md
basic-detections
brute-force
cves
dns
files
panels
payloads
security-misconfiguration
subdomain-takeover
technologies
tokens
vulnerabilities
workflows
This is same as ls -1 ~/nuclei-templates/tokens
nuclei -ts tokens/
[WRN] Use with caution. You are responsible for your actions
[WRN] Developers assume no liability and are not responsible for any misuse or damage.
[INF] Searching for templates in /Users/bauthard/nuclei-templates/tokens/
amazon-mws-auth-token-value.yaml
aws-access-key-value.yaml
google-api-key.yaml
http-username-password.yaml
mailchimp-api-key.yaml
slack-access-token.yaml
string-based search for template file names.
Note:- if user-provided string which is the same as the folder name, folder lookup will be performed instead of filename search.
nuclei -ts rce
[WRN] Use with caution. You are responsible for your actions
[WRN] Developers assume no liability and are not responsible for any misuse or damage.
[INF] Searching for templates in /Users/bauthard/nuclei-templates/
vulnerabilities/pdf-signer-ssti-to-rce.yaml
vulnerabilities/rce-shellshock-user-agent.yaml
vulnerabilities/rce-via-java-deserialization.yaml
workflows/liferay-rce-workflow.yaml
workflows/netsweeper-preauth-rce-workflow.yaml
In case, no config file found, the following error will be displayed.
nuclei -ts
[WRN] Use with caution. You are responsible for your actions
[WRN] Developers assume no liability and are not responsible for any misuse or damage.
[FTL] Program exiting: nuclei-templates are not installed, use update-templates flag to download.
Few notes to consider:-
ts flag works with ~/.nuclei-config.json config file to get the template path to search for.
If ~/.nuclei-config.json is missing, it means user needs to download the template, in that case, error out with warning to download the template using -update-template flag.
Is your feature request related to a problem? Please describe. with the addition of relative path support, we almost using it all the time while running nuclei, but as the templates are not in the current directory it becomes a problem when you want to list/find any targeted template, so adding flag support which will perform same ls like action in at installed template path would make it more useful.
Describe the solution you'd like
Suggested flag:-
ts
- stands for template search.example:-
This is same as
ls -1 ~/nuclei-templates/
This is same as
ls -1 ~/nuclei-templates/tokens
string-based search for template file names.
Note:- if user-provided string which is the same as the folder name, folder lookup will be performed instead of filename search.
In case, no config file found, the following error will be displayed.
Few notes to consider:-
ts
flag works with~/.nuclei-config.json
config file to get the template path to search for.~/.nuclei-config.json
is missing, it means user needs to download the template, in that case, error out with warning to download the template using-update-template
flag.