Wednesday 27 July 2011

Connecting to any host anonymously with ncat and vidalia bundle by telecominfo.in


In this tutorial I will show you how to connect to any host and port number with ncat anonymously through a range of proxies provided by tor network by vidalia bundle.

First off you will need to download ncat and vidalia bundle:

Vidalia bundle
Code:

http://www.torproject.org/vidalia/index.html.en

Nmap and Ncat
Code:

http://nmap.org/download.html

Both applications can be ran on linux, windows and mac os x.
Ncat comes with Nmap, so you have to download and install Nmap as well.

When installing Vidalia bundle, make sure you install all the features which are given to you at the installation process.

Ok, all the installing out of the way let's get to work.

First let's connect to a host and determine our IP adress:

Code:

C:\>ncat -v smtp.gmail.com 587
Ncat version 5.00 ( http://nmap.org/ncat )
Connected to 74.125.47.109:587.
220 mx.google.com ESMTP 6sm2383279ywc.54
ehlo
250-mx.google.com at your service, [my.ip.is.here]
250-SIZE 35651584
250-8BITMIME
250-STARTTLS
250-ENHANCEDSTATUSCODES
250 PIPELINING
^C

A you can see I first connected to gmail smtp server with verbose flag and on connection I typed in "ehlo" which then spits out my ip address which I renamed for this tutorial (my.ip.is.here).

This type of connection as you can see is not anonymous and if you are doing any poking around, the administrator of the server will see you IP address and will be able to track you down.

Now open vidalia AND privoxy, opeing just vidalia won't work for this tutorial.
Now consider this:

Code:

C:\>ncat -v --proxy 127.0.0.1:8118 smtp.gmail.com 587
Ncat version 5.00 ( http://nmap.org/ncat )
Connected to 127.0.0.1:8118.
ehlo
HTTP/1.0 200 Connection established
Proxy-Agent: Privoxy/3.0.6

220 mx.google.com ESMTP 23sm2380871ywh.33
250-mx.google.com at your service, [91.198.227.49]
250-SIZE 35651584
250-8BITMIME
250-STARTTLS
250-ENHANCEDSTATUSCODES
250 PIPELINING
^C

As you can see I successfully stayed anonymous on the server by forwarding my ncat traffic through the tor network proxy.

I first connect to the privoxy program which listens on my localhost port 8118 (yours will be the same, unless you want to change it) and privoxy forwards my network traffic through to vidalia and to tor network, which hops from host to host on the tor network to finally connected to our desired destination which is the gmail smtp server.

ncat>privoxy>tor hosts>gmail server

I hope this tutorial will be usefull for you, and if you have any questions just ask here. Thanks.

0 comments:

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More

 
Powered by Blogger