ryzom / ryzomcore

Ryzom Core is the open-source project related to the Ryzom game. This community repository is synchronized with the Ryzom Forge repository, based on the Core branch.
https://wiki.ryzom.dev
GNU Affero General Public License v3.0
331 stars 89 forks source link

Small patch to RyzomAMS installer #109

Closed ryzom-pipeline closed 10 years ago

ryzom-pipeline commented 10 years ago

Original report by Meelis Mägi (Bitbucket: [Meelis Mägi](https://bitbucket.org/Meelis Mägi), ).


diff -r 2203f917d617 code/ryzom/tools/server/ryzom_ams/www/html/installer/libsetup.php
--- a/code/ryzom/tools/server/ryzom_ams/www/html/installer/libsetup.php Mon Feb 03 01:25:02 2014 +0100
+++ b/code/ryzom/tools/server/ryzom_ams/www/html/installer/libsetup.php Wed Feb 05 12:06:48 2014 +0200
@@ -40,7 +40,6 @@
         //var used to access the DB;
         global $cfg;

-        sleep(15);^M
         try{
             //SETUP THE WWW DB
             $dbw = new DBLayer("install", "web");
ryzom-pipeline commented 10 years ago

Original comment by Matthew Lagoe (Bitbucket: botanic, GitHub: botanic).


whats this for?

ryzom-pipeline commented 10 years ago

Original comment by Meelis Mägi (Bitbucket: [Meelis Mägi](https://bitbucket.org/Meelis Mägi), ).


sleep(15) is unnecessary. it does nothing but waits for 15sec and then continues.

ryzom-pipeline commented 10 years ago

Original comment by Matthew Lagoe (Bitbucket: botanic, GitHub: botanic).


The reason i stuck it in there is to prevent people from trying to brute-force a setup via the installer

ryzom-pipeline commented 10 years ago

Original comment by Meelis Mägi (Bitbucket: [Meelis Mägi](https://bitbucket.org/Meelis Mägi), ).


Installer can only be done once, no?

I dont understand the brute-force problem here.

ryzom-pipeline commented 10 years ago

Original comment by Matthew Lagoe (Bitbucket: botanic, GitHub: botanic).


well it should only work once, but frankly I cant say that its bugfree ;)

Also if someone loads in the database but doesnt load the ams installer the installer page will be there forever

ryzom-pipeline commented 10 years ago

Original comment by Meelis Mägi (Bitbucket: [Meelis Mägi](https://bitbucket.org/Meelis Mägi), ).


index in ams checks for is_installed file and if its not found, forces installer page. Its not possible to use it without using installer.

index also gives error when trying to run installer again after first one succeeded.

sleep in there is unnecessary.

ryzom-pipeline commented 10 years ago

Original comment by Matthew Lagoe (Bitbucket: botanic, GitHub: botanic).


I suppose that this is unnecessary after those other changes, I will remove it.

Thanks!