Shitty Shared Hosting or Stupid Web Administrator
Hosting condiviso, ormai te lo tirano dietro con 4 euro !
Ma è veramente sicuro un hosting condiviso !?
Il prezzo non dovrebbe importare, comunque io sono su un hosting condiviso cioè:
Wikipedia:
A shared web hosting service or virtual hosting service or derive host refers to a web hosting service where many websites reside on one web server connected to the Internet. Each site “sits” on its own partition, or section/place on the server, to keep it separate from other sites. This is generally the most economical option for hosting, as many people share the overall cost of server maintenance.
Cioè su un server sono hostati più siti.
Essendo in un hosting linux ogni utente ha una propria home directory alla quale è associato il proprio sito internet.
Adesso se uno “Shitty Shared Hosting” permette la navigazione nelle directory del server sfruttando una cattiva configurazione e uno ” Stupid Web Administrator ” ha sbagliato ad impostare i permessi un attacker può leggere/modificare i nostri file.
Quindi in lato pratico:
-Enumerare gli utenti che sono nel nostro server :)
Questa cosa è abbastanza facile :)
Si può usare DRIL, oppure leggere /etc/passwd oppure listare un po’ a caso queste directory /var/www /var/mail /home/ www/.
Una volta ottenuto l’accesso a un server provare funzioni php e eventuali perl python a seconda di quello che supporta il server per poter eseguire comandi :)
Le funzioni php da provare sono:
- exec;
- passthru;
- shell_exec;
- system;
- proc_open;
- popen;
- ini_set;
In perl cgi si può usare:
- system;
In python, sono troppe da elencare :)
Una volta enumerate le home degli utenti dovremo fare un bruteforce alla ricerca dei loro file di configurazione nelle home degli altri utenti con i permessi sbagliati :) :)
I permessi 777 non bisogna darli :)
wp-config.php # WordPress
config.php # phpBB, ExpressionEngine
configuration.php # Joomla
LocalSettings.php # MediaWiki
mt-config.cgi # Movable Type
settings.php # Drupal
E file di backup:
wp-config.php~ # Vim, Gedit
#wp-config.php# # Emacs
wp-config.php.save # Nano
wp-config.php.swp # Vim (swap file)
wp-config.php.swo # Vim (swap file)
L’enumerazione la possiamo fare con weevely o a manina oppure rilascerò a breve un piccolo tool :)
An e Buon Natale :D
Related posts:
- [Shared Web Hosting Fuck]Weevely 0.4 is OUT :D
- YASAT:Yet Another Stupid Audit Tool
- [CVE-2010-2568]Metasploit:windows Oday Remote Code Exuction
- [How-To] Durandal Distributed CPU/GPU Hash Cracker
- [ddos attack]Siege,rendere spiacevole la giornata di un SysAdmin
This entry was posted on Saturday, December 24th, 2011 at 10:16 am and is filed under Articles on GNU/Linux, GNU/Linux, Hacking, Software. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.
Tagged with: attack • hosting






