Design of an Ethernet Monitor and Protocol Analyzer Gwenna S
Total Page:16
File Type:pdf, Size:1020Kb
Iowa State University Capstones, Theses and Retrospective Theses and Dissertations Dissertations 1990 Design of an Ethernet monitor and protocol analyzer Gwenna S. Jacobson Iowa State University Follow this and additional works at: https://lib.dr.iastate.edu/rtd Part of the Hardware Systems Commons Recommended Citation Jacobson, Gwenna S., "Design of an Ethernet monitor and protocol analyzer" (1990). Retrospective Theses and Dissertations. 16878. https://lib.dr.iastate.edu/rtd/16878 This Thesis is brought to you for free and open access by the Iowa State University Capstones, Theses and Dissertations at Iowa State University Digital Repository. It has been accepted for inclusion in Retrospective Theses and Dissertations by an authorized administrator of Iowa State University Digital Repository. For more information, please contact [email protected]. Design of an Ethernet monitor and protocol analyzer by Gwenna S. Jacobson A Thesis Submitted to the Graduate Faculty in Partial Fulfillment of the Requirements for the Degree of MASTER OF SCIENCE Department: Electrical Engineering and Computer Engineering Major: Computer Engineering Signatures have been redacted for privacy Iowa State University Ames, Iowa 1990 11 TABLE OF CONTENTS ACKNOWLEDGEMENTS VIll 1. INTRODUCTION ... 1 2. MONITORING TECHNIQUES 3 2.1 C en t ralized ~Ioni tor 3 2.1.1 Probe Monitor 3 2.1.2 Spy Monitor. 3 2.2 Distributed Monitor 4 2.3 Hybrid l\Ionitor ... 4 3. NETWORK PROTOCOLS .5 3.1 OSlo 5 3.1.1 Physical Layer. 6 3.1.2 Data Link Layer 6 3.1.3 Network Layer 8 3.1.4 Transport Layer. 11 3.1.5 Session Layer . 13 3.1.6 Presentation Layer 1.5 3.1.7 Application Layer. 17 3.2 TCP/IP ......... 18 III 3.2.1 IP 20 3.2.2 TCP 21 3.2.3 FOP 23 :3.2.-! IC\IP 24 ·V 3.2 ..5 ARp!RARP. ~.) .)- 3.2.6 RIP _I 3.2.7 Telnet 28 3.2.8 FTP 28 3.2.9 S~ITP 28 3.3 Ethernet 29 4. NETWORK MONITOR DESIGN 37 4.1 Hardware 37 4.2 Software 37 4.2.1 F ser Interface 38 4.2.2 Filters 39 4.2.3 Data Capture 39 4.2.4 Data Display Windows 39 4.2 ..5 File I/O 44 4.2.6 Statistics. 44 4.2.7 Driver Software 44 5. CONCLUSIONS 47 6. BIBLIOGRAPHY 49 IV 7. APPENDIX A: ACRONYMS . .. .')1 8. APPENDIX B: SOURCE CODE. .')3 v LIST OF FIGURES Figure 3.1: OSI Layers. .. ... 7 Figure 3.2: ISO IP packet data unit formats 9 Figure 3.3: ISO transport protocol fixed header formats 12 Figure 3.4: ISO session protocol data unit 14 Figure 3.5: ISO presentation protocol data unit 16 Figure 3.6: Comparison of DPA protocols to OSI layers. 19 Figure 3.7: Internet protocol format 20 Figure .3.8: TCP protocol data unit . 22 Figure 3.9: UDP protocol data unit. 23 Figure 3.10: ICMP protocol data unit 25 Figure 3.11: ARP jRARP protocol data unit 26 Figure 3.12: RIP protocol data unit 27 Figure 3.13: Ethernet frame .... 29 Figure 4.1: Block diagram of the User Interface 38 Figure 4.2: Filtering Setup Menus. 40 Figure 4.3: Data Capture Screen 41 Figure 4.4: Data Display Windows 42 Figure 4.5: Summary Display \Vindow 43 VI Figure 4.6: Detail Display Window . 43 Figure 4.7: Hexadecimal Display \Vindow 44 Figure 4.8: Store/Restore Menu ..... 4.5 Vll LIST OF TABLES Table 3.1: Ethernet Address Assignments for Vendors 31 Table 3.2: Ethernet Type Field Assignments . 34 Table 7.1: Acronyms ............ .52 VIll ACKNOWLEDGEMENTS I would like to thank Professor Terry Smay, my major professor, for his help on the project and helping me meet the deadlines. I would also like to thank Professor Dick Horton and Professor Dale Grosvenor for serving on my committee. I want to thank Lynn Christiansen who worked with me on this project. She encouraged me when I needed encouragement and worked with me although my schedule was difficult to work around. I also need to thank Pam Myers, the graduate secretary, because I am sure without her constant reminders of deadlines I would have missed a few of them. I am grateful to my parents for never imposing limitations on me and always encouraging me to test my abilities. I especially want to thank my husband, Doug, for knowing this was something I wanted to finish and helping me to do it. He answered my many questions on various aspects of this project: He also spent many evenings taking care of things at home, enabling me to complete my degree. 1 1. INTRODUCTION As local area networks have proliferated over the last decade, it is necessary to be able to monitor and analyze activity on these networks. This is even more necessary when LANs are internetworked together and all the computer systems on the network are not under one person's control or even one department's control. A network monitor and protocol analyzer allows you to capt ure, decode, exam ine and analyze frames on the network and to isolate and identify problems on the network. A protocol analyzer would be a valuable tool in computer networking classes. Students could use the protocol analyzer to see the packets decoded. Several network protocol analyzers are commercially available, however they are expensive. An ad vantage of a protocol analyzer that is especially developed for the classroom instead of the commercial marketplace is that it would allow students to examine source code and write code modules for other protocols, thus giving them experience in network programrrung. The network monitor and protocol analyzer discussed in this thesis was developed for the Ethernet protocol. The hardware used was an off-the-shelf 386 personal computer installed with a 3eom Ethernet board [1]. The Ethernet board used was a 3C505 intelligent Ethernet adapter board and came with driver software. The 2 board has an 80188 microprocessor, 512 Kbytes of memory and a DMA interface. It captures, decodes and analyzes Ethernet protocols, TCP lIP protocols and OSI protocols. The user interface was standardized to that of an FDDI monitor currently be ing developed by Lynn Christiansen. It was developed with a windowing library of routines called C \Vindows Toolkit [2]. 3 2. MONITORING TECHNIQUES There are three commonly used monitoring techniques. They are centralized, distributed, and hybrid [3] [4]. 2.1 Centralized Monitor A centralized monitor is a monitor in which a dedicated station on the net work collects and analyzes data on that station. There are two types of centralized monitoring techniques. They are the probe monitor and the spy monitor. 2.1.1 Probe Monitor The probe monitor injects packets onto the network and can be used to analyze how the network will perform under varying loads. 2.1.2 Spy Monitor The spy monitor is a special node dedicated to monitoring the network passively. It listens to already existing traffic on the network and does not introduce any ar tificial traffic onto the network. The monitor designed in this research was a spy monitor. 4 2.2 Distributed Monitor A distributed monitor is a monitor where each station collects and analyzes data and then sends this information to a central location for further analysis. 2.3 Hybrid Monitor A hybrid monitor is a monitor where data are collected and analyzed at both a central location and distributed locations. .5 3. NETWORK PROTOCOLS A network protocol is a set of rules that govern the exchange of data between two communicating entities. There are two major protocol standards for the higher protocol layers, the OSI reference model and TCP /IP. At the two lower protocol layers the standards for local area networks (LANs) are the IEEE 802 series of standards. There are three major types of LANs defined in IEEE 802, CSMA/CD bus, token ring and token bus. CSMA/CD is also known as Ethernet and is the type of LAN used in this research. The OSI reference model, Tep /IP and Ethernet are discussed in further detail in the following sections. The part of the protocol that is examined by the network monitor is the actual protocol data units (PDUs) associated with each layer. 3.1 OSI In 19ii the International Organization for Standardization (ISO) established a subcommittee to define a communications architecture. The result was the Open Systems Interconnection (051) reference model adopted in 1983. The OSI reference model uses the structuring technique of layering, where each layer in the network performs a certain subset of functions and passes the information on to the next lower layer where the next layer performs more primitive functions and conceals the 6 details of those functions [,5] [6] [i]. Each layer also provides serVIces to the next higher layer [8]. The OSI model has seven layers listed below and shown in Figure 3.1. • the physical layer • the data link layer • the network layer • the transport layer • the session layer • the presentation layer • the application layer. 3.1.1 Physical Layer The Physical Layer is concerned with the transmission of data over the physical medium. It deals with the mechanical, electrical, functional and procedural char acteristics to access the physical medium. The physical layer protocol used in this proje,ct is Ethernet and will be discussed in another section. 3.1.2 Data Link Layer The data link layer provides for the reliable transfer of information across the physical link. It sends blocks of data (frames or packets) with the necessary synchro nization, error control, and flow control.