Wireless Hacks Free Open Book

Wireless Hacks

Previous Section Next Section

Hack 38 Visual Traffic Analysis with Ethereal

figs/beginner.giffigs/hack38.gif

Sift through network data with one of the most advanced protocol analyzers available.

Ethereal is one of the most popular protocol analyzers on the planet. It runs on virtually all major platforms, including Linux, BSD, Mac OS X, and Windows. Like tcpdump [Hack #37], it can capture packets directly from a network interface, or analyze data from a previously saved file. While capturing data, Ethereal can give you real-time statistics about which protocols are actively in use (Figure 3-35). Start capturing by selecting Capture Start..., select the interface you want to capture from, and click OK. Note that you need proper permissions (typically root privileges) to actually capture data.

Figure 3-35. Ethereal gives you statistics about the protocols it sees as it captures packets.
figs/wh_0335.gif

If you would like to see these statistics again (with even more detail) after you have finished capturing packets, go to Tools Protocol Heirarchy Statistics. You can use this on previously captured dump files as well. If you already have some captured data (say, saved with tcpdump from a remote machine), you can simply click File Open... and select the file you'd like to analyze.

Ethereal displays the data it has collected in three ways. The top part of the window shows a summary of the data, with one packet per line. This lists the sequence, time, IP data, protocol, and general description of the packet. The data can be sorted on any of these fields by clicking the field name at the top. Selecting one packet displays more information in the other two window areas. The middle part of the window shows a hierarchical dissection of the packet, including the Ethernet, IP, TCP, and other layers. This allows you to quickly "drill down" into the particular piece of the packet that you are interested in. The bottom portion of the window shows a hex dump of the actual packet. Bits of the packet are automatically highlighted by selecting parts of the packet in the middle section. For example, selecting the IP source address in the middle section highlights the corresponding 4 bytes in the hex dump at the bottom.

Figure 3-36 shows Ethereal's ability to dissect high-level protocols such as HTTP. Select an HTTP packet at the top, and open the Hypertext Transfer Protocol drop-down in the middle section. This shows the contents of the packet in plain ASCII.

Figure 3-36. Ethereal understands many high level protocols, such as HTTP.
figs/wh_0336.gif

Of course, most TCP conversations are spread across several packets. Ethereal reassembles the entire stream for you by selecting one packet and clicking Tools Follow TCP Stream. Figure 3-37 shows the results of following the above HTTP stream.

Figure 3-37. Ethereal reassembles a TCP stream to show you a conversation between two hosts.
figs/wh_0337.gif

It is difficult to tell in black and white, but the two conversations are actually displayed in different colors, making it simple to tell at a glance which side is speaking.

Speaking of colors, Ethereal can even display its packet data with color coding, defined by a rich pattern-matching language. This can make any data you are searching for leap out in bold red while showing everything else in pale gray, for example. It uses the same pattern-matching language to specify display filters, which unfortunately isn't the same language used by tcpdump. For an example of how to build a display filter, see [Hack #39].

This is just a simple example of some of Ethereal's basic features. It can show you as much detail as you care to know about the packets flying around on your wireless network, and is one of the most powerful tools available for tracking down network problems. See the documentation and example capture files at http://www.ethereal.com/ for some other creative uses for Ethereal.

    Previous Section Next Section
    Index: [SYMBOL][A][B][C][D][E][F][G][H][I][J][L][M][N][O][P][Q][R][S][T][U][V][W][X][Z]


         Main Menu
    Main Page
    Table of content
    Copyright
    Credits
    Foreword
    Preface
    Chapter 1. The Standards
    Chapter 2. Bluetooth and Mobile Data
    Chapter 3. Network Monitoring
    3.1 Hacks #20-42
    Hack 20 Find All Available Wireless Networks
    Hack 21 Network Discovery Using NetStumbler
    Hack 22 Network Detection on Mac OS X
    Hack 23 Detecting Networks Using Handheld PCs
    Hack 24 Passive Scanning with KisMAC
    Hack 25 Establishing Connectivity
    Hack 26 Quickly Poll Wireless Clients with ping
    Hack 27 Finding Radio Manufacturers by MAC Address
    Hack 28 Rendezvous Service Advertisements in Linux
    Hack 29 Advertising Arbitrary Rendezvous Services in OS X
    Hack 30 'Brought to you by' Rendezvous Ad Redirector
    Hack 31 Detecting Networks with Kismet
    Hack 32 Running Kismet on Mac OS X
    Hack 33 Link Monitoring in Linux with Wavemon
    Hack 34 Historical Link State Monitoring
    Hack 35 EtherPEG and DriftNet
    Hack 36 Estimating Network Performance
    Hack 37 Watching Traffic with tcpdump
    Hack 38 Visual Traffic Analysis with Ethereal
    Hack 39 Tracking 802.11 Frames in Ethereal
    Hack 40 Interrogating the Network with nmap
    Hack 41 Network Monitoring with ngrep
    Hack 42 Running ntop for Real-Time Network Stats
    Chapter 4. Hardware Hacks
    Chapter 5. Do-It-Yourself Antennas
    Chapter 6. Long Distance Links
    Chapter 7. Wireless Security
    Appendix A. Deep Dish Parabolic Reflector Template
    Colophon
    Index


    More Books
    PHP Hacks
    Processing Xml With Java - A Guide To Sax, Dom, Jdom, Jaxp, And Trax
    The Koran (Holy Qur'an)
    Macromedia Flash 8 Bible
    Search Engine Optimization for Dummies
    YouTube Traffic
    PHP 5 for Dummies
    Harry Potter and The Chamber of Secrets
    Harry Potter and the Sorcerer's Stone
    The Pilgrim's Progress
    Wireless Hacks
    Flash Hacks. 100 Industrial-Strength Tips & Tools
    PayPal Hacks. 100 Industrial-Strength Tips and Tools
    Amazon Hacks
    Pdf Hacks
    The Da Vinci Code
    Google Hacks
    The Holy Bible
    Windows XP For Dummies
    Harry Potter and the Half-Blood Prince
    Seo Book
    Upgrading and Repairing Networks
    Macromedia Dreamweaver 8 UNLEASHED
    Windows XP Annoyances
    Windows XP Hacks
    Microsoft Windows XP Power Toolkit
    Teach Yourself MS Office In 24Hours
    iPod & iTunes Missing Manual
    PC Hacks 100 Industrial-Strength Tips and Tools
    PC Overclocking, Optimization, and Tuning - 2th Edition
    PC Hardware In A Nutshell 3rd Edition
    PC Hardware in a Nutshell, 2nd Edition
    Upgrading and Repairing PCs
    Google for Dummies
    MySQL Cookbook
    Teach Yourself Macromedia Flash 8 In 24 Hours
    PHP CookBook
    Sams Teach Yourself JavaScript in 24 Hours
    PHP5 Manual
    Free Games Paper Airplanes
    500 Juegos Gratis 500 Giochi Gratis 500 Jeux Gratuits 500 Jogos Gratis 500 Kostenlose Spiele