An Implementation of X.25 Over Tcp/Ip
Total Page:16
File Type:pdf, Size:1020Kb
Copyright is owned by the Author of the thesis. Permission is given for a copy to be downloaded by an individual for the purpose of research and private study only. The thesis may not be reproduced elsewhere without the pennission of the Author. AN IMPLEMENTATION OF X.25 OVER TCP/IP A Thesis Presented in Partial Fulfilment of the Requirements for the Degree of Master of Technology in Computing Technology at Massey University Ajitkumar J. W. Rasiah 1991 ACKNOWLEDGMENTS I am indebted to my supervisor, Dr. Peter Kay of the Department of Computer Science, Massey University, for his invaluable advice, assistance and helpful criticism throughout this study and the preparation of this manuscript. His patience and encouragement are greatly appreciated. I also wish to thank: Professor Robert M. Hodgson of the Department of Production Technology, Massey University, for providing the opportunity for this study. Professor Mark D. Apperley of the Department of Computer Science, Massey University, and the Massey University Computer Centre for providing the facilities for this study. I would also like to express my sincere thanks to my parents Dr. and Mrs. B. W. Rasiah for their patience, help and encouragement during the course of this study. -11- CONTENTS ACKNOWLEDGMENTS .............................................................................................. ii CONTENTS .................................................................................................................... iii LIST OF FIGURES ......................................................................................................... vii ABSTRACT..................................................................................................................... viii 1. INTRODUCTION ....................................................................................................... ! ,1.1 The Rapid Growth of Computer Networks .................................................... ! 1.2 International Standards Organizations ............................................................ 2 1.3 Protocols ......................................................................................................... 2 1.4 Reference Models ........................................................................................... 3 1.5 Objectives of the Project ................................................................................. 7 2. CCITT X.25 RECOMMENDATIONS ...................................................................... 9 2.1 Packet Switching Data Networks ................................................................... 9 2.2 CCITT X.25 Recommendations ..................................................................... IO 2.3 The Structure of X.25 ..................................................................................... 11 2.4 Virtual Calls .................................................................................................... 12 2.5 X.25 Packet Formats ...................................................................................... 12 2.5.1 Call Set-up and Clearing Packets ..................................................... 13 2.5.2 Data and Interrupt Packets ............................................................... 14 2.5.3 Resetting and Restarting Packets ..................................................... 14 2.6 Flow Control .................................................................................................. 16 2.7 Packet Assembly/Disassembly Devices ......................................................... 17 2.8 Efficiency Considerations ............................................................................... 17 3. THE INTERNET PROTOCOL SUITE ...................................................................... 19 3.1 Background .................................................................................................... 19 3.2 Layering in the Internet ................................................................................... 20 3.3 Internet Addressing ........................................................................................ 21 3.4 The Transmission Control Protocol (TCP) .................................................... .22 3.5 The Internet Protocol (IP) ............................................................................... 24 3.6 Underlying Network Services ........................................................................ 25 - iii - 4. UNDERLYING NETWORK SERVICES ................................................................ 26 4.1 Link Access Protocol B (LAPB) .................................................................... 26 4.1.1 LAPB Frame Format ...................................................................... 26 4.1.2 LAPB Frame Types ........................................................................ 27 Information Frames ...................................................................... 27 Supervisory Frames ..................................................................... 28 Unnumbered Frames .................................................................... 28 4.2 Bus Networks ................................................................................................. 30 4.3 IEEE 802 ....................................................................................................... 32 4.3.1 IEEE 802.2 (LLC) .......................................................................... 32 4.3.2 IEEE 802.3 (CSMA/CD) ............................................................... 35 Ethernet ........................................................................................ 35 4.4 IP over Ethernet .............................................................................................. 37 4.4.1 Address Resolution Protocol ........................................................... 37 4.4.2 Ethernet Frame Contents for IP ....................................................... 37 4.4.3 TCP Maximum Segment Size Option ............................................. 38 4.4.4 Datagram Fragmentation ................................................................. 38 4.5 X.25 over CSMA/CD .................................................................................... 40 4.5.1 Data Link Layer Management ........................................................ .40 4.5.2 Layer Management .......................................................................... 42 4.6 Serial Line IP (SLIP) ...................................................................................... 44 4.6.1 SLIP Protocol Description .............................................................. .44 4.6.2 Deficiencies ..................................................................................... 44 4.7 Point-to-Point Protocol (PPP) ....................................................................... .46 4. 7 .1 PPP Layering ................................................................................... 46 The Physical Layer ....................................................................... 46 The Data Link Layer ..................................................................... 47 4.7.2 Link Control Protocol (LCP) .......................................................... .48 LCP Packets ................................................................................. 48 LCP Actions and Events .............................................................. 49 LCP Configuration Options .......................................................... 51 4. 7 .3 IP Control Protocol (IPCP) ............................................................. 52 4.8 ISO Development Environment (ISODE) ..................................................... 53 4.8.1 ISODE Communities ...................................................................... 53 4.8.2 Transport Service Bridges ............................................................... 54 4.8.3 ISO-TP0 Bridge between TCP and X.25 ........................................ 54 - iv - 4.9 VMS Packet Switch Interface (PSI) ............................................................... 58 4.10 IP over X.25 ................................................................................................. 58 5. IMPLEMENTATION OF X.25 OVER TCP/IP ........................................................ 61 5.1 Introduction .................................................................................................... 61 5.2 The Client-Server Model of Interaction .......................................................... 62 5 .3 Overview of the Implementation .................................................................... 63 5.4 The X.25 Library ............................................................................................ 65 5.4.1 Modes of Operation ......................................................................... 66 5.4.2 Buffering ......................................................................................... 66 5.4.3 Handling Special Packets ................................................................. 66 5 .5 The X.25 Library Interface ............................................................................. 68 5.5.1 socket() ............................................................................................ 68 5.5.2 connect() .......................................................................................... 69 5.5.3 bind() ..............................................................................................