XUT_ / COURSES / CYBER SECURITY 101

Vulnerable and Outdated Components - Exploit

Ya que esto va de vulnerabilidades conocidas, la mayoría del trabajo ya ha sido hecho. Nuestro principal objetivo es averiguar la información del software y buscar hasta encontrar un exploit. Veamos un ejemplo.

Vulnerable and Outdated Components - Exploit

Aquí vemos la página por defecto de un servidor que corre Nostromo 1.9.6. Ahora que tenemos el nombre del software y la versión podemos usar Exploit-DB para buscar exploits para él. Por suerte para nosotros, sí que hay:

Vulnerable and Outdated Components - Exploit

Al intentar ejecutar el código del exploit salta un problema, por eso conviene conocer lenguajes de programación, para poder arreglar pequeños bugs:

sh
user@linux$ python 47837.py
Traceback (most recent call last):
  File "47837.py", line 10, in <module>
    cve2019_16278.py
NameError: name 'cve2019_16278' is not defined

En nuestro caso, hay que comentar una línea:

python
# Exploit Title: nostromo 1.9.6 - Remote Code Execution
# Date: 2019-12-31
# Exploit Author: Kr0ff
# Vendor Homepage:
# Software Link: http://www.nazgul.ch/dev/nostromo-1.9.6.tar.gz
# Version: 1.9.6
# Tested on: Debian
# CVE : CVE-2019-16278

cve2019_16278.py  # This line needs to be commented.

#!/usr/bin/env python

Por último, volvemos a probar y boom, RCE conseguida!