So we've ARP spoofed a few connectionsweeeha. Where's the "Beyond" you promised?
Well, the beyond bit lies in the fact the EtterCap can intervene in the traffic stream, and modify strings at our will! The implications of this are endless, but I'll give a short demonstration of this capability.
Say you wanted to replace a TCP stream of a WWW session, so that every time the address www.google.com would redirect you to www.mutsonline.com.
- Chose the Spoofed source and destination computers, as shown before, and start the spoofing process.
- Press "F" to edit your filters:
- We want to edit the "Filters on source" to replace www.google.com to www.mutsonline.com on destination port 80. To do this, we press "W" to enter the Source filters. We then press "A" to add a filter. Choose the specified filter (in case we have a few) and press enter to edit it. Add the required input to create your filter.
- Pressinq "Q" will exit this screen and ask us if we want to save our filter. Choose "yes".
- We are now back at the filter screen. Notice that we just made the filter; we still have not ACTIVATED it (both filters are "OFF").
- To activate the filter we need to press "S", and then we should see the filter status turn to "ON".
- We now try to surf to www.google.com on the attacked machine:
ouch
When I tried this tutorial in class, I noticed that the example did not work perfectly - perhaps because Google has different sitenames that are redirected according to geographical location, so I followed this with another example.
In this example we will manipulate text from a financial article on cnn.com, as seen by an attacked computer. This is the page before we intervene:
"Invertors cash in" because of a weakness in something or otherWe will now manipulate the data in such a way the content of the site will change - only on the victim's computer though. Let's reverse the meaning of the article. Let's make the heading - "Investors cash out".
Basically what this means in Ettercap terms is that we will replace the string "in" to "out", on the http session.
Please note - this is not a Web server defacement - it's manipulation of the data stream that reaches a specific host in our network, in conjunction with ARP spoofing.
Conclusion
So how do we protect our Organization from this evil, evil type of network activity? Well, you're not going to like the answer - There's no simple way. We could use Arpwatch, which is a small daemon that runs on Linux. Arpwatch monitors Ethernet activity and keeps a database of Ethernet / IP address pairings, and can alert on any unexpected changes. Or, we could occasionally use Ettercap to check for the presence of other poisoners.
I've heard of other solutions, concerning switch port security, however I haven't had the opportunity to test this - I'd be glad to hear your experiences. By the way, the Linux version of Ettercap has many more features and plugins (such as DNS spoofing plugins), but you have to start somewhere right?
A FEW EXAMPLES from the EtterCap Readme PDF:
ettercap -b
Use broadcast ping to scan the LAN instead of ARP request all the subnet IPs.
ettercap -s 192.168.0.1 192.168.0.2
Enter the interactive mode and sniff only the connections between 192.168.0.1 and 192.168.0.2.
ettercap -zs -e etter.conf
Use the IP-based sniffing mode and load the other option from the config file (etter.conf). Note that options in the file override command line.
ettercap -Nzs victim.my.net ANY:80
Sniffs in console mode (non-interactive) only the connection to and from "victim.my.net" starting or ending to all other hosts but on port 80 (www). Data are dumped in ASCII mode. To dump in HEX mode add the -x option.
ettercap -NRzs remote.host.net:23 my.local.host.com
Useful to sniff in console mode (non-interactive) all the connections on a remote LAN on which you are executing ettercap. This example will prevent showing your telnet (:23) connection from "my.local.host.com" to "remote.host.net".
ettercap -Nclg
This will provide you the entire list of hosts in the LAN. Will check if someone is poisoning you and will report its IP. Will tell you if you are on a switched LAN or not.
ettercap -NCLzs --quiet
This will detach ettercap from console and log to a file all the collected password. Only works if the LAN is hubbed, or if collected password are directed to your host.
ettercap -Np ooze victim.mynet.org
Launch the plugin "ooze" that will portscan the host "victim.mynet.org" that will be translated with the right IP
Mati Aharoni, MCSES, MCT, CCNA, CCSA, CISSP
Visit the Security through Hacking Web site at http://www.secureit.co.il for additional information.
About the author:
Mati Aharoni, MCSES, MCT, CCNA, CCSA, CISSP
Visit the Security through Hacking Web site at http://www.secureit.co.il for additional information.
Comments
Post new comment