From 7029f130336432d79540a60452f130a7a3a98621 Mon Sep 17 00:00:00 2001 From: Aditya Patil <72488360+PythonHacker24@users.noreply.github.com> Date: Sun, 22 Dec 2024 18:04:39 +0530 Subject: [PATCH] Update nmap-summary-esp.md --- .../pentesting-network/nmap-summary-esp.md | 179 +++++++++--------- 1 file changed, 90 insertions(+), 89 deletions(-) diff --git a/generic-methodologies-and-resources/pentesting-network/nmap-summary-esp.md b/generic-methodologies-and-resources/pentesting-network/nmap-summary-esp.md index 428ddae35..5c42bb54c 100644 --- a/generic-methodologies-and-resources/pentesting-network/nmap-summary-esp.md +++ b/generic-methodologies-and-resources/pentesting-network/nmap-summary-esp.md @@ -63,171 +63,171 @@ By default Nmap launches a discovery phase consisting of: `-PA80 -PS443 -PE -PP` * **`-sO`:** Protocol Ip scan. Sends bad and empty headers in which sometimes not even the protocol can be distinguished. If ICMP unreachable protocol arrives it is closed, if unreachable port arrives it is open, if another error arrives, filtered, if nothing arrives, open|filtered. * **`-b `:** FTPhost--> It is used to scan a host from another one, this is done by connecting the ftp of another machine and asking it to send files to the ports that you want to scan from another machine, according to the answers we will know if they are open or not. \[\:\@]\\[:\] Almost all ftps servers no longer let you do this and therefore it is of little practical use. -### **Centrar análisis** +### **Focus Analysis** -**-p:** Sirve para dar los puertos a escanear. Para seleccionar los 65335: **-p-** o **-p all**. Nmap tiene una clasificaación interna según su popularidad. Por defecto usa los 1000 ppales. Con **-F** (fast scan) analiza los 100 ppales. Con **--top-ports \** Analiza ese numero de ppales (de 1 hasta los 65335). Comprueba los puertos en orden aleatorio, para que eso no pase **-r**. También podemos seleccionar puertos: 20-30,80,443,1024- Esto ultimo significa que mire en adelante del 1024. También podemos agrupar los puertos por protocolos: U:53,T:21-25,80,139,S:9. También podemos escoger un rango dentro de los puertos populares de nmap: -p \[-1024] analiza hasta el 1024 de los incluidos en nmap-services. **--port-ratio \** Analiza los puertos más comúnes que un ratio que debe estar entre 0 y 1 +**-p:** Used to specify ports to scan. To select all 65,335 ports: **-p-** or **-p all**. Nmap has an internal classification based on popularity. By default, it uses the top 1000 ports. With **-F** (fast scan) it analyzes the top 100. With **--top-ports ** it analyzes that number of top ports (from 1 to 65,335). It checks ports in random order; to prevent this, use **-r**. We can also select specific ports: 20-30,80,443,1024- (the latter means to look from 1024 onwards). We can also group ports by protocols: U:53,T:21-25,80,139,S:9. We can also choose a range within Nmap's popular ports: -p [-1024] analyzes up to port 1024 from those included in nmap-services. **--port-ratio ** Analyzes the most common ports within a ratio between 0 and 1 -**-sV** Escaneado de versión, se puede regular la intensidad de 0 a 9, por defecto 7. +**-sV** Version scanning, intensity can be regulated from 0 to 9, default is 7. -**--version-intensity \** Regulamos la intensidad, de forma que cuanto más bajo solo lanzará las sondas más probables, pero no todas. Con esto podemos acortar considerablemente el tiempo de escaneo UDP +**--version-intensity ** We regulate the intensity, so that the lower it is, it will only launch the most probable probes, but not all. With this, we can considerably shorten UDP scanning time -**-O** Deteccion de os +**-O** OS detection -**--osscan-limit** Para escanear bien un host se necesita que al menos haya 1 puerto abierto y otro cerrado, si no se da esta condición y hemos puesto esto, no intenta hacer predicción de os (ahorra tiempo) +**--osscan-limit** For proper host scanning, at least one open port and one closed port are needed. If this condition isn't met and we've set this, it won't attempt OS prediction (saves time) -**--osscan-guess** Cuando la detección de os no es perfecta esto hace que se esfuerce más +**--osscan-guess** When OS detection isn't perfect, this makes it try harder **Scripts** -\--script _\_|_\_|_\_|_\_\[,...] +--script __|__|__|__[,...] -Para usar los de por efecto vale con -sC o --script=default +To use default scripts, use -sC or --script=default -Los tipos que hay son de: auth, broadcast, default, discovery, dos, exploit, external, fuzzer, intrusive, malware, safe, version, and vuln +Available types are: auth, broadcast, default, discovery, dos, exploit, external, fuzzer, intrusive, malware, safe, version, and vuln -* **Auth:** ejecuta todos sus _scripts_ disponibles para autenticación -* **Default:** ejecuta los _scripts_ básicos por defecto de la herramienta -* **Discovery:** recupera información del _target_ o víctima -* **External:** _script_ para utilizar recursos externos -* **Intrusive:** utiliza _scripts_ que son considerados intrusivos para la víctima o _target_ -* **Malware:** revisa si hay conexiones abiertas por códigos maliciosos o _backdoors_ (puertas traseras) -* **Safe:** ejecuta _scripts_ que no son intrusivos -* **Vuln:** descubre las vulnerabilidades más conocidas -* **All:** ejecuta absolutamente todos los _scripts_ con extensión NSE disponibles +* **Auth:** executes all available authentication scripts +* **Default:** executes basic default tool scripts +* **Discovery:** retrieves information from the target or victim +* **External:** script for using external resources +* **Intrusive:** uses scripts considered intrusive to the victim or target +* **Malware:** checks for connections opened by malicious code or backdoors +* **Safe:** executes non-intrusive scripts +* **Vuln:** discovers the most known vulnerabilities +* **All:** executes absolutely all available NSE extension scripts -Para buscar scripts: +To search for scripts: -**nmap --script-help="http-\*" -> Los que empiecen por http-** +**nmap --script-help="http-\*" -> Those starting with http-** -**nmap --script-help="not intrusive" -> Todos menos esos** +**nmap --script-help="not intrusive" -> All except those** -**nmap --script-help="default or safe" -> Los que estan en uno o en otro o en ambos** +**nmap --script-help="default or safe" -> Those in either or both** -**nmap --script-help="default and safe" --> Los que estan en ambos** +**nmap --script-help="default and safe" --> Those in both** **nmap --script-help="(default or safe or intrusive) and not http-\*"** -\--script-args _\_=_\_,_\_={_\_=_\_},_\_={_\_,_\_} +--script-args __=__,__={__=__},__={__,__} -\--script-args-file _\_ +--script-args-file __ -\--script-help _\_|_\_|_\_|_\_|all\[,...] +--script-help __|__|__|__|all[,...] -\--script-trace ---> Da info de como va elscript +--script-trace ---> Provides info on how the script is progressing -\--script-updatedb +--script-updatedb -**Para usar un script solo hay que poner: namp --script Nombre\_del\_script objetivo** --> Al poner el script se ejecutará tanto el script como el escaner, asi que tambien se pueden poner opciones del escaner, podemos añadir **“safe=1”** para que se ejecuten solo los que sean seguros. +**To use a script, just type: nmap --script Script_Name target** --> When using the script, both the script and scanner will execute, so scanner options can also be added. We can add **"safe=1"** to execute only safe ones. -**Control tiempo** +**Time Control** -**Nmap puede modificar el tiempo en segundos, minutos, ms:** --host-timeout arguments 900000ms, 900, 900s, and 15m all do the same thing. +**Nmap can modify time in seconds, minutes, ms:** --host-timeout arguments 900000ms, 900, 900s, and 15m all do the same thing. -Nmap divide el numero total de host a escanear en grupos y analiza esos grupos en bloques de forma que hasta que no han sido analizados todos, no pasa al siguiente bloque (y el usuario tampoco recibe ninguna actualización hasta que se haya analizado el bloque) de esta forma, es más óptimo para nmap usar grupos grandes. Por defecto en clase C usa 256. +Nmap divides the total number of hosts to scan into groups and analyzes these groups in blocks, so it doesn't move to the next block until all have been analyzed (and the user doesn't receive any updates until the block has been analyzed). This way, it's more optimal for Nmap to use large groups. By default in class C, it uses 256. -Se puede cambiar con\*\*--min-hostgroup\*\* _**\**_**;** **--max-hostgroup** _**\**_ (Adjust parallel scan group sizes) +This can be changed with **--min-hostgroup** _****_**;** **--max-hostgroup** _****_ (Adjust parallel scan group sizes) -Se puede controlar el numero de escaners en paralelo pero es mejor que no (nmpa ya incorpora control automatico en base al estado de la red): **--min-parallelism** _**\**_**;** **--max-parallelism** _**\**_ +You can control the number of parallel scanners but it's better not to (Nmap already incorporates automatic control based on network status): **--min-parallelism** _****_**;** **--max-parallelism** _****_ -Podemos modificar el rtt timeout, pero no suele ser necesario: **--min-rtt-timeout** _**\