Hunt For The Administrator’s Page Using PHP Program

04/24/2010 20:35 <Custom>#1
Today I am going present you a new PHP tutorial which will enable hackers like you to find the administrator page without any hassle.
Let’s get started with the tutorial.

First of all I am going to create a form where you’ll have to input the URL of the website.

Create a basic HTML platform in a new text file with HTML, BODY, TITLE tag etc.

Creating a form:

PHP Code:
    <form action=”adminsearch.php” method=”post”>

    <
p><input type=”text” size=”120&#8243; value=”http://www.website.com/”/>

    
<input value=”find” type=”submit”><br />

    </
form
Now let’s do some PHP magic after the form.

What we are going to do in PHP magic is to search the specified directory. Many websites usually keeps the administrator page separately on the folder with specific name given.

What we are going to do is execute the following code and find the administrator page folder.

Trying out and guessing different form might be tedious job therefore, we’ll create a new text file named folders.txt with the list of our guessed directory.

PHP Code:
    <?php

    
/** Let’s ensure that the page does not timeout unexpectedly hampering our search job**/

    
set_time_limit(0);

    
$Target $_POST['targetSite'];

    
//this function will only execute if the target is provided.

    
if ($Target <> “”) {

    echo 
<br /> Starting <br />;

    
$url $_POST['targetSite'];

    echo 
<br />Targeting.$Target.” <br /><br />;

    
//This function will check for the file named folders.txt which contains the list of suspected administrator folders.

    
$MasterList ‘folders.txt’;

    
// This function will clear the cache to ensure that the status of the file is checked

    
clearstatcache();

    if (
file_exists($MasterList)) {

    echo 
“Retrieving List <br />;

    } else {

    echo 
“The file $MasterList does not exist”;

    }

    
//Open the file and assign each line to a new element in the array

    //Once completed, close the file

    
$fHandler fopen($MasterList“r”);

    while (! 
feof($fHandler)) {

    
$thisline fgets($fHandler);

    
$adminfolder file($MasterList);

    }

    
fclose($fHandler);

    
//This function will try to access each URL and returns the  list of URLs that do not respond with 404 error(Page not found error)

    
foreach ($adminfolder as $adminurl){

    
$headers get_headers(“$Target$adminurl”);

    if (
eregi(‘Not Found’$headers[0])) {

    echo 
“$Target$adminurl NO!<br />;

    }

    else {

    echo 
<a href=’$Target$adminurl’>$Target$adminurl</aHere is the URL of ADMIN Page!<br />;

    }

    }

    }

    
?>
The folders.txt will be as follow:


Now finally lets arrange the whole thing that we’ve created in one place.

Create new text file or use dreamweaver and copy the form and paste below the form paste the PHP code. Finally rename it as adminsearch.php

Place both adminsearch.php and folders.txt in one separate folder and upload it to your web host or local host. Go to the URL that have adminsearch.php and hunt for the administrator’s page for the target website.

Now since you got the location of administrator page, you can play something further to hack in to administrator’s page.

The tutorial is not mine! Copyrighted by Suraj Kayastha
04/24/2010 20:44 Megaload#2
And a another Tutorial BY the King xDD
04/24/2010 23:35 TheoRettisch#3
´tschuldigung, aber ich muss mich leider über das Script beschweren, da es voller Fehler ist.
Zum Formular:
- Dem Input feld musst du auch einen Namen zuweisen,
- Die Anführungszeichen korrigieren,
- und den Zahlencode bei´m size=... löschen.

Zum Script:
Die Anführungszeichen und die Apostroph die du gesetzt hast, waren größtenteils nicht richtig. Denn anstatt ein " zu setzen hattest du ein " gesetzt und anstatt ' ein ´. Desweiteren hast du die Datei nicht selber erstellen lassen und dadurch entstand ein Errorloop, der den Browser abstürzen lässt, da er so viel durcharbeiten muss (ist ja halt eine Leerlauf-Schleife). Ich würde dich bitten das Script zu überarbeiten, bis keine Fehler mehr auftauchen, da es so keinem etwas bringt.

Post Scriptum: Ich sehe gerade, dass es garnicht von dir ist sondern von Suraj Kayastha. Wenn du mit ihm in Kontakt stehst, bitte ich dich ihm meine Nachricht zu übermitteln. Oder ändere das Script selber...