Nuclei es un escaner de vulnerabilidades escrito en Go permitiendo realizar la detección en diferentes protocolos por ejemplo TCP, HTTP, DNS.
En esta entrada veremos como configurar y ejecutar la herramienta, algo muy importante y a tomar en cuenta es que toda herramienta que realice un escaneo de vulnerabilidades potencialmente podría dar de baja algún sistema, según el tipo de configuración que tenga el servidor o sistema respectivamente.
Considera que también un scanner no hará tu trabajo o detectara todas las vulnerabilidades o falencias de seguridad, siempre necesitaremos a una persona que conozca del tema.
Instalación
Al ser realizado en Go es posible contar con la aplicación en Linux, Windows o Mac para ello debemos dirigirnos a los releases, en este podremos ver diferentes paquetes según la arquitectura y además del sistema operativo.
Después de descargarlo accederemos al binario nuclei el cual te recomiendo que realices un enlace simbólico para que trabajes con la herramienta desde cualquier ubicación.
chmod +x nuclei
sudo ln -s nuclei /usr/bin/nuclei
Una vez lo tengamos podremos verificar si está funcionando correctamente con el comando nuclei --help
nuclei --h
Nuclei is a fast, template based vulnerability scanner focusing
on extensive configurability, massive extensibility and ease of use.
Usage:
nuclei [flags]
Flags:
TARGET:
-u, -target string[] target URLs/hosts to scan
-l, -list string path to file containing a list of target URLs/hosts to scan (one per line)
-resume Resume scan using resume.cfg (clustering will be disabled)
TEMPLATES:
-t, -templates string[] template or template directory paths to include in the scan
-tu, -template-url string[] URL containing list of templates to run
-nt, -new-templates run only new templates added in latest nuclei-templates release
-w, -workflows string[] workflow or workflow directory paths to include in the scan
-wu, -workflow-url string[] URL containing list of workflows to run
-validate validate the passed templates to nuclei
-tl list all available templates
FILTERING:
-tags string[] execute a subset of templates that contain the provided tags
-itags, -include-tags string[] tags from the default deny list that permit executing more intrusive templates
-etags, -exclude-tags string[] exclude templates with the provided tags
-it, -include-templates string[] templates to be executed even if they are excluded either by default or configuration
-et, -exclude-templates string[] template or template directory paths to exclude
-s, -severity value[] Templates to run based on severity. Possible values: info, low, medium, high, critical
-es, -exclude-severity value[] Templates to exclude based on severity. Possible values: info, low, medium, high, critical
-pt, -type value[] protocol types to be executed. Possible values: dns, file, http, headless, network, workflow, ssl, websocket, whois
-ept, -exclude-type value[] protocol types to not be executed. Possible values: dns, file, http, headless, network, workflow, ssl, websocket, whois
-a, -author string[] execute templates that are (co-)created by the specified authors
-id, -template-id string[] List of template IDs to run (comma-separated, file)
-eid, -exclude-id string[] List of template IDs to exclude (comma-separated, file)
Veremos todo el output de los comandos que podremos utilizarlo, pero si ejecutamos solo nuclei procederá a realizar la descarga de los templates, como lo vemos en el siguiente texto.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
nuclei
__ _
____ __ _______/ /__ (_)
/ __ \/ / / / ___/ / _ \/ /
/ / / / /_/ / /__/ / __/ /
/_/ /_/\__,_/\___/_/\___/_/ 2.6.0
projectdiscovery.io
[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] nuclei-templates are not installed, installing...
[INF] Successfully downloaded nuclei-templates (v8.8.5) to /root/nuclei-templates. GoodLuck!
[INF] Using Nuclei Engine 2.6.0 (latest)[INF] Using Nuclei Templates 8.8.5 (latest)[INF] Templates added in last update: 3117[INF] Templates loaded for scan: 2909[INF] No results found. Better luck next time!
Para actualizar los Templates se ejecuta la flag nuclei -ut y para actualizar la herramienta se realiza con el comando nuclei -update
nuclei -ut
__ _
____ __ _______/ /__ (_)
/ __ \/ / / / ___/ / _ \/ /
/ / / / /_/ / /__/ / __/ /
/_/ /_/\__,_/\___/_/\___/_/ 2.6.0
projectdiscovery.io
[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] No new updates found for nuclei templates
nuclei -update
__ _
____ __ _______/ /__ (_)
/ __ \/ / / / ___/ / _ \/ /
/ / / / /_/ / /__/ / __/ /
/_/ /_/\__,_/\___/_/\___/_/ 2.6.0
projectdiscovery.io
[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] No new updates found for nuclei engine!
Escaneo de vulnerabilidades con Nuclei
Para realizar un escaneo de vulnerabilidades a una página web en específico es realizado con el siguiente comando.
1
nuclei -u https://sniferl4bs.com
Visualizamos en la siguiente captura cual es el resultado de realizar el escaner sobre el blog.
En otro caso si deseamos ejecutar multiples sitios podemos realizarlo
1
nuclei -l urls.txt
Si deseamos realizar un escaneo con un HEADER personalizado debemos de usar la flag -H
1
nuclei -H 'SNIFER:HEADER' -l urls.txt
También podríamos realizar un escaneo con base en alguno de sus tags, especificar el formato que nos devolvera el resultado por ejemplo es realizado con la flag -o
cve, rce, lfi, xss, network, logs, config, ssrf
Para que llegues a sacar un mejor provecho de la herramienta, te recomiendo que revises en profundidad todas las banderas y realices las pruebas respectivas.
«Por cada esfuerzo disciplinado, siempre hay múltiples recompensas.». – Jim Rohn
Regards, Snifer
Share on
Support the author with
WRITTEN BY
Snifer
Creador del proyecto Snifer@L4b's, Consultor en Seguridad Informática.