UNIX Network Programming, Volume 1: The Sockets Networking API [3. ed., 8. printing]
0131411551, 0076092025917, 9780131411555
This is THE guide to UNIX network programming APIs. Whether you write Web servers, client/server applications, or any ot
282
87
8MB
English
Pages XXIII, 991 Seiten Diagramme
[1094]
Year 2003;2008
Report DMCA / Copyright
DOWNLOAD PDF FILE
Table of contents :
[Trial version] Main Page......Page 1
[Trial version] Table of content......Page 3
[Trial version] Copyright......Page 16
[Trial version] Addison-Wesley Professional Computing Series......Page 17
[Trial version] Foreword......Page 19
[Trial version] Preface......Page 20
[Trial version] Introduction......Page 21
[Trial version] Changes from the Second Edition......Page 22
[Trial version] Using This Book......Page 23
[Trial version] Source Code and Errata Availability......Page 24
[Trial version] Acknowledgments......Page 25
[Trial version] Part 1: Introduction and TCP/IP......Page 27
[Trial version] Chapter 1. Introduction......Page 28
[Trial version] 1.1 Introduction......Page 29
[Trial version] 1.2 A Simple Daytime Client......Page 32
[Trial version] 1.3 Protocol Independence......Page 36
[Trial version] 1.4 Error Handling: Wrapper Functions......Page 38
[Trial version] 1.5 A Simple Daytime Server......Page 41
[Trial version] 1.6 Roadmap to Client/Server Examples in the Text......Page 44
[Trial version] 1.7 OSI Model......Page 46
[Trial version] 1.8 BSD Networking History......Page 48
[Trial version] 1.9 Test Networks and Hosts......Page 50
[Trial version] 1.10 Unix Standards......Page 55
[Trial version] 1.11 64-Bit Architectures......Page 58
[Trial version] 1.12 Summary......Page 59
[Trial version] Exercises......Page 60
[Trial version] Chapter 2. The Transport Layer: TCP, UDP, and SCTP......Page 61
[Trial version] 2.1 Introduction......Page 62
[Trial version] 2.2 The Big Picture......Page 63
[Trial version] 2.3 User Datagram Protocol (UDP)......Page 66
[Trial version] 2.4 Transmission Control Protocol (TCP)......Page 67
[Trial version] 2.5 Stream Control Transmission Protocol (SCTP)......Page 69
[Trial version] 2.6 TCP Connection Establishment and Termination......Page 70
[Trial version] 2.7 TIME_WAIT State......Page 75
[Trial version] 2.8 SCTP Association Establishment and Termination......Page 77
[Trial version] 2.9 Port Numbers......Page 81
[Trial version] 2.10 TCP Port Numbers and Concurrent Servers......Page 84
[Trial version] 2.11 Buffer Sizes and Limitations......Page 86
[Trial version] 2.12 Standard Internet Services......Page 91
[Trial version] 2.13 Protocol Usage by Common Internet Applications......Page 93
[Trial version] 2.14 Summary......Page 94
[Trial version] Exercises......Page 95
[Trial version] Part 2: Elementary Sockets......Page 96
[Trial version] Chapter 3. Sockets Introduction......Page 97
[Trial version] 3.1 Introduction......Page 98
[Trial version] 3.2 Socket Address Structures......Page 99
[Trial version] 3.3 Value-Result Arguments......Page 105
[Trial version] 3.4 Byte Ordering Functions......Page 108
[Trial version] 3.5 Byte Manipulation Functions......Page 112
[Trial version] 3.6 'inet_aton', 'inet_addr', and 'inet_ntoa' Functions......Page 114
[Trial version] 3.7 'inet_pton' and 'inet_ntop' Functions......Page 116
[Trial version] 3.8 'sock_ntop' and Related Functions......Page 119
[Trial version] 3.9 'readn', 'writen', and 'readline' Functions......Page 122
[Trial version] 3.10 Summary......Page 127
[Trial version] Exercises......Page 128
[Trial version] Chapter 4. Elementary TCP Sockets......Page 129
[Trial version] 4.1 Introduction......Page 130
[Trial version] 4.2 'socket' Function......Page 131
[Trial version] 4.3 'connect' Function......Page 134
[Trial version] 4.4 'bind' Function......Page 137
[Trial version] 4.5 'listen' Function......Page 140
[Trial version] 4.6 'accept' Function......Page 145
[Trial version] 4.7 'fork' and 'exec' Functions......Page 148
[Trial version] 4.8 Concurrent Servers......Page 151
[Trial version] 4.9 'close' Function......Page 154
[Trial version] 4.10 'getsockname' and 'getpeername' Functions......Page 155
[Trial version] 4.11 Summary......Page 158
[Trial version] Exercises......Page 159
[Trial version] Chapter 5. TCP Client/Server Example......Page 160
[Trial version] 5.1 Introduction......Page 161
[Trial version] 5.2 TCP Echo Server: 'main' Function......Page 162
[Trial version] 5.3 TCP Echo Server: 'str_echo' Function......Page 164
[Trial version] 5.4 TCP Echo Client: 'main' Function......Page 165
[Trial version] 5.5 TCP Echo Client: 'str_cli' Function......Page 167
[Trial version] 5.6 Normal Startup......Page 168
[Trial version] 5.7 Normal Termination......Page 171
[Trial version] 5.8 POSIX Signal Handling......Page 173
[Trial version] 5.9 Handling 'SIGCHLD' Signals......Page 176
[Trial version] 5.10 'wait' and 'waitpid' Functions......Page 179
[Trial version] 5.11 Connection Abort before 'accept' Returns......Page 184
[Trial version] 5.12 Termination of Server Process......Page 186
[Trial version] 5.13 'SIGPIPE' Signal......Page 188
[Trial version] 5.14 Crashing of Server Host......Page 190
[Trial version] 5.15 Crashing and Rebooting of Server Host......Page 191
[Trial version] 5.16 Shutdown of Server Host......Page 192
[Trial version] 5.17 Summary of TCP Example......Page 193
[Trial version] 5.18 Data Format......Page 195
[Trial version] 5.19 Summary......Page 199
[Trial version] Exercises......Page 200
[Trial version] Chapter 6. I/O Multiplexing: The 'select' and 'poll' Functions......Page 202
[Trial version] 6.1 Introduction......Page 203
[Trial version] 6.2 I/O Models......Page 204
[Trial version] 6.3 'select' Function......Page 209
[Trial version] 6.4 'str_cli' Function (Revisited)......Page 215
[Trial version] 6.5 Batch Input and Buffering......Page 217
[Trial version] 6.6 'shutdown' Function......Page 220
[Trial version] 6.7 'str_cli' Function (Revisited Again)......Page 222
[Trial version] 6.8 TCP Echo Server (Revisited)......Page 224
[Trial version] 6.9 'pselect' Function......Page 229
[Trial version] 6.10 'poll' Function......Page 231
[Trial version] 6.11 TCP Echo Server (Revisited Again)......Page 234
[Trial version] 6.12 Summary......Page 237
[Trial version] Exercises......Page 238
[Trial version] Chapter 7. Socket Options......Page 239
[Trial version] 7.1 Introduction......Page 240
[Trial version] 7.2 'getsockopt' and 'setsockopt' Functions......Page 241
[Trial version] 7.3 Checking if an Option Is Supported and Obtaining the Default......Page 243
[Trial version] 7.4 Socket States......Page 247
[Trial version] 7.5 Generic Socket Options......Page 248
[Trial version] 7.6 IPv4 Socket Options......Page 261
[Trial version] 7.7 ICMPv6 Socket Option......Page 263
[Trial version] 7.8 IPv6 Socket Options......Page 264
[Trial version] 7.9 TCP Socket Options......Page 267
[Trial version] 7.10 SCTP Socket Options......Page 270
[Trial version] 7.11 'fcntl' Function......Page 280
[Trial version] 7.12 Summary......Page 283
[Trial version] Exercises......Page 284
[Trial version] Chapter 8. Elementary UDP Sockets......Page 286
[Trial version] 8.1 Introduction......Page 287
[Trial version] 8.2 'recvfrom' and 'sendto' Functions......Page 288
[Trial version] 8.3 UDP Echo Server: 'main' Function......Page 290
[Trial version] 8.4 UDP Echo Server: 'dg_echo' Function......Page 291
[Trial version] 8.5 UDP Echo Client: 'main' Function......Page 293
[Trial version] 8.6 UDP Echo Client: 'dg_cli' Function......Page 294
[Trial version] 8.7 Lost Datagrams......Page 295
[Trial version] 8.8 Verifying Received Response......Page 296
[Trial version] 8.9 Server Not Running......Page 299
[Trial version] 8.10 Summary of UDP Example......Page 301
[Trial version] 8.11 'connect' Function with UDP......Page 303
[Trial version] 8.12 'dg_cli' Function (Revisited)......Page 307
[Trial version] 8.13 Lack of Flow Control with UDP......Page 309
[Trial version] 8.14 Determining Outgoing Interface with UDP......Page 313
[Trial version] 8.15 TCP and UDP Echo Server Using 'select'......Page 315
[Trial version] 8.16 Summary......Page 318
[Trial version] Exercises......Page 319
[Trial version] Chapter 9. Elementary SCTP Sockets......Page 321
[Trial version] 9.1 Introduction......Page 322
[Trial version] 9.2 Interface Models......Page 323
[Trial version] 9.3 'sctp_bindx' Function......Page 327
[Trial version] 9.4 'sctp_connectx' Function......Page 328
[Trial version] 9.5 'sctp_getpaddrs' Function......Page 329
[Trial version] 9.6 'sctp_freepaddrs' Function......Page 330
[Trial version] 9.7 'sctp_getladdrs' Function......Page 331
[Trial version] 9.8 'sctp_freeladdrs' Function......Page 332
[Trial version] 9.9 'sctp_sendmsg' Function......Page 333
[Trial version] 9.10 'sctp_recvmsg' Function......Page 334
[Trial version] 9.11 'sctp_opt_info' Function......Page 335
[Trial version] 9.12 'sctp_peeloff' Function......Page 336
[Trial version] 9.13 'shutdown' Function......Page 337
[Trial version] 9.14 Notifications......Page 338
[Trial version] 9.15 Summary......Page 344
[Trial version] Exercises......Page 345
[Trial version] Chapter 10. SCTP Client/Server Example......Page 346
[Trial version] 10.1 Introduction......Page 347
[Trial version] 10.2 SCTP One-to-Many-Style Streaming Echo Server: 'main' Function......Page 348
[Trial version] 10.3 SCTP One-to-Many-Style Streaming Echo Client: 'main' Function......Page 351
[Trial version] 10.4 SCTP Streaming Echo Client: 'str_cli' Function......Page 353
[Trial version] 10.5 Exploring Head-of-Line Blocking......Page 355
[Trial version] 10.6 Controlling the Number of Streams......Page 361
[Trial version] 10.7 Controlling Termination......Page 362
[Trial version] 10.8 Summary......Page 364
[Trial version] Exercises......Page 365
[Trial version] Chapter 11. Name and Address Conversions......Page 366
[Trial version] 11.1 Introduction......Page 367
[Trial version] 11.2 Domain Name System (DNS)......Page 368
[Trial version] 11.3 'gethostbyname' Function......Page 372
[Trial version] 11.4 'gethostbyaddr' Function......Page 376
[Trial version] 11.5 'getservbyname' and 'getservbyport' Functions......Page 377
[Trial version] 11.6 'getaddrinfo' Function......Page 382
[Trial version] 11.7 'gai_strerror' Function......Page 387
[Trial version] 11.8 'freeaddrinfo' Function......Page 388
[Trial version] 11.9 'getaddrinfo' Function: IPv6......Page 389
[Trial version] 11.10 'getaddrinfo' Function: Examples......Page 391
[Trial version] 11.11 'host_serv' Function......Page 393
[Trial version] 11.12 'tcp_connect' Function......Page 394
[Trial version] 11.13 'tcp_listen' Function......Page 398
[Trial version] 11.14 'udp_client' Function......Page 403
[Trial version] 11.15 'udp_connect' Function......Page 406
[Trial version] 11.16 'udp_server' Function......Page 408
[Trial version] 11.17 'getnameinfo' Function......Page 410
[Trial version] 11.18 Re-entrant Functions......Page 412
[Trial version] 11.19 'gethostbyname_r' and 'gethostbyaddr_r' Functions......Page 416
[Trial version] 11.20 Obsolete IPv6 Address Lookup Functions......Page 418
[Trial version] 11.21 Other Networking Information......Page 420
[Trial version] 11.22 Summary......Page 422
[Trial version] Exercises......Page 423
[Trial version] Part 3: Advanced Sockets......Page 425
[Trial version] Chapter 12. IPv4 and IPv6 Interoperability......Page 426
[Trial version] 12.1 Introduction......Page 427
[Trial version] 12.2 IPv4 Client, IPv6 Server......Page 428
[Trial version] 12.3 IPv6 Client, IPv4 Server......Page 431
[Trial version] 12.4 IPv6 Address-Testing Macros......Page 433
[Trial version] 12.5 Source Code Portability......Page 435
[Trial version] 12.6 Summary......Page 436
[Trial version] Exercises......Page 437
[Trial version] Chapter 13. Daemon Processes and the 'inetd' Superserver......Page 438
[Trial version] 13.1 Introduction......Page 439
[Trial version] 13.2 'syslogd' Daemon......Page 440
[Trial version] 13.3 'syslog' Function......Page 441
[Trial version] 13.4 'daemon_init' Function......Page 444
[Trial version] 13.5 'inetd' Daemon......Page 448
[Trial version] 13.6 'daemon_inetd' Function......Page 453
[Trial version] 13.7 Summary......Page 456
[Trial version] Exercises......Page 457
[Trial version] Chapter 14. Advanced I/O Functions......Page 458
[Trial version] 14.1 Introduction......Page 459
[Trial version] 14.2 Socket Timeouts......Page 460
[Trial version] 14.3 'recv' and 'send' Functions......Page 466
[Trial version] 14.4 'readv' and 'writev' Functions......Page 468
[Trial version] 14.5 'recvmsg' and 'sendmsg' Functions......Page 469
[Trial version] 14.6 Ancillary Data......Page 473
[Trial version] 14.7 How Much Data Is Queued?......Page 477
[Trial version] 14.8 Sockets and Standard I/O......Page 478
[Trial version] 14.9 Advanced Polling......Page 481
[Trial version] 14.10 Summary......Page 487
[Trial version] Exercises......Page 488
[Trial version] Chapter 15. Unix Domain Protocols......Page 489
[Trial version] 15.1 Introduction......Page 490
[Trial version] 15.2 Unix Domain Socket Address Structure......Page 491
[Trial version] 15.3 'socketpair' Function......Page 494
[Trial version] 15.4 Socket Functions......Page 495
[Trial version] 15.5 Unix Domain Stream Client/Server......Page 496
[Trial version] 15.6 Unix Domain Datagram Client/Server......Page 498
[Trial version] 15.7 Passing Descriptors......Page 500
[Trial version] 15.8 Receiving Sender Credentials......Page 508
[Trial version] 15.9 Summary......Page 512
[Trial version] Exercises......Page 513
[Trial version] Chapter 16. Nonblocking I/O......Page 514
[Trial version] 16.1 Introduction......Page 515
[Trial version] 16.2 Nonblocking Reads and Writes: 'str_cli' Function (Revisited)......Page 517
[Trial version] 16.3 Nonblocking 'connect'......Page 527
[Trial version] 16.4 Nonblocking 'connect:' Daytime Client......Page 528
[Trial version] 16.5 Nonblocking 'connect:' Web Client......Page 531
[Trial version] 16.6 Nonblocking 'accept'......Page 540
[Trial version] 16.7 Summary......Page 542
[Trial version] Exercises......Page 543
[Trial version] Chapter 17. 'ioctl' Operations......Page 544
[Trial version] 17.1 Introduction......Page 545
[Trial version] 17.2 'ioctl' Function......Page 546
[Trial version] 17.3 Socket Operations......Page 548
[Trial version] 17.4 File Operations......Page 549
[Trial version] 17.5 Interface Configuration......Page 550
[Trial version] 17.6 'get_ifi_info' Function......Page 553
[Trial version] 17.7 Interface Operations......Page 563
[Trial version] 17.8 ARP Cache Operations......Page 565
[Trial version] 17.9 Routing Table Operations......Page 568
[Trial version] 17.10 Summary......Page 569
[Trial version] Exercises......Page 570
[Trial version] Chapter 18. Routing Sockets......Page 571
[Trial version] 18.1 Introduction......Page 572
[Trial version] 18.2 Datalink Socket Address Structure......Page 573
[Trial version] 18.3 Reading and Writing......Page 574
[Trial version] 18.4 'sysctl' Operations......Page 582
[Trial version] 18.5 'get_ifi_info' Function (Revisited)......Page 586
[Trial version] 18.6 Interface Name and Index Functions......Page 590
[Trial version] 18.7 Summary......Page 595
[Trial version] Exercises......Page 596
[Trial version] Chapter 19. Key Management Sockets......Page 597
[Trial version] 19.1 Introduction......Page 598
[Trial version] 19.2 Reading and Writing......Page 599
[Trial version] 19.3 Dumping the Security Association Database (SADB)......Page 601
[Trial version] 19.4 Creating a Static Security Association (SA)......Page 605
[Trial version] 19.5 Dynamically Maintaining SAs......Page 611
[Trial version] 19.6 Summary......Page 615
[Trial version] Exercises......Page 616
[Trial version] Chapter 20. Broadcasting......Page 617
[Trial version] 20.1 Introduction......Page 618
[Trial version] 20.2 Broadcast Addresses......Page 620
[Trial version] 20.3 Unicast versus Broadcast......Page 622
[Trial version] 20.4 'dg_cli' Function Using Broadcasting......Page 625
[Trial version] 20.5 Race Conditions......Page 628
[Trial version] 20.6 Summary......Page 636
[Trial version] Exercises......Page 637
[Trial version] Chapter 21. Multicasting......Page 638
[Trial version] 21.1 Introduction......Page 639
[Trial version] 21.2 Multicast Addresses......Page 640
[Trial version] 21.3 Multicasting versus Broadcasting on a LAN......Page 644
[Trial version] 21.4 Multicasting on a WAN......Page 646
[Trial version] 21.5 Source-Specific Multicast......Page 648
[Trial version] 21.6 Multicast Socket Options......Page 649
[Trial version] 21.7 'mcast_join' and Related Functions......Page 654
[Trial version] 21.8 'dg_cli' Function Using Multicasting......Page 660
[Trial version] 21.9 Receiving IP Multicast Infrastructure Session Announcements......Page 661
[Trial version] 21.10 Sending and Receiving......Page 666
[Trial version] 21.11 Simple Network Time Protocol (SNTP)......Page 670
[Trial version] 21.12 Summary......Page 675
[Trial version] Exercises......Page 676
[Trial version] Chapter 22. Advanced UDP Sockets......Page 677
[Trial version] 22.1 Introduction......Page 678
[Trial version] 22.2 Receiving Flags, Destination IP Address, and Interface Index......Page 679
[Trial version] 22.3 Datagram Truncation......Page 685
[Trial version] 22.4 When to Use UDP Instead of TCP......Page 686
[Trial version] 22.5 Adding Reliability to a UDP Application......Page 688
[Trial version] 22.6 Binding Interface Addresses......Page 698
[Trial version] 22.7 Concurrent UDP Servers......Page 703
[Trial version] 22.8 IPv6 Packet Information......Page 705
[Trial version] 22.9 IPv6 Path MTU Control......Page 709
[Trial version] 22.10 Summary......Page 711
[Trial version] Exercises......Page 712
[Trial version] Chapter 23. Advanced SCTP Sockets......Page 713
[Trial version] 23.1 Introduction......Page 714
[Trial version] 23.2 An Autoclosing One-to-Many-Style Server......Page 715
[Trial version] 23.3 Partial Delivery......Page 716
[Trial version] 23.4 Notifications......Page 719
[Trial version] 23.5 Unordered Data......Page 723
[Trial version] 23.6 Binding a Subset of Addresses......Page 724
[Trial version] 23.7 Determining Peer and Local Address Information......Page 726
[Trial version] 23.8 Finding an Association ID Given an IP Address......Page 730
[Trial version] 23.9 Heartbeating and Address Failure......Page 731
[Trial version] 23.10 Peeling Off an Association......Page 733
[Trial version] 23.11 Controlling Timing......Page 735
[Trial version] 23.12 When to Use SCTP Instead of TCP......Page 737
[Trial version] 23.13 Summary......Page 739
[Trial version] Exercises......Page 740
[Trial version] Chapter 24. Out-of-Band Data......Page 741
[Trial version] 24.1 Introduction......Page 742
[Trial version] 24.2 TCP Out-of-Band Data......Page 743
[Trial version] 24.3 'sockatmark' Function......Page 751
[Trial version] 24.4 TCP Out-of-Band Data Recap......Page 758
[Trial version] 24.5 Summary......Page 760
[Trial version] Exercises......Page 761
[Trial version] Chapter 25. Signal-Driven I/O......Page 762
[Trial version] 25.1 Introduction......Page 763
[Trial version] 25.2 Signal-Driven I/O for Sockets......Page 764
[Trial version] 25.3 UDP Echo Server Using 'SIGIO'......Page 767
[Trial version] 25.4 Summary......Page 773
[Trial version] Exercises......Page 774
[Trial version] Chapter 26. Threads......Page 775
[Trial version] 26.1 Introduction......Page 776
[Trial version] 26.2 Basic Thread Functions: Creation and Termination......Page 778
[Trial version] 26.3 'str_cli' Function Using Threads......Page 781
[Trial version] 26.4 TCP Echo Server Using Threads......Page 783
[Trial version] 26.5 Thread-Specific Data......Page 788
[Trial version] 26.6 Web Client and Simultaneous Connections (Continued)......Page 796
[Trial version] 26.7 Mutexes: Mutual Exclusion......Page 800
[Trial version] 26.8 Condition Variables......Page 804
[Trial version] 26.9 Web Client and Simultaneous Connections (Continued)......Page 808
[Trial version] 26.10 Summary......Page 810
[Trial version] Exercises......Page 811
[Trial version] Chapter 27. IP Options......Page 812
[Trial version] 27.1 Introduction......Page 813
[Trial version] 27.2 IPv4 Options......Page 814
[Trial version] 27.3 IPv4 Source Route Options......Page 816
[Trial version] 27.4 IPv6 Extension Headers......Page 824
[Trial version] 27.5 IPv6 Hop-by-Hop Options and Destination Options......Page 825
[Trial version] 27.6 IPv6 Routing Header......Page 830
[Trial version] 27.7 IPv6 Sticky Options......Page 836
[Trial version] 27.8 Historical IPv6 Advanced API......Page 837
[Trial version] 27.9 Summary......Page 838
[Trial version] Exercises......Page 839
[Trial version] Chapter 28. Raw Sockets......Page 840
[Trial version] 28.1 Introduction......Page 841
[Trial version] 28.2 Raw Socket Creation......Page 842
[Trial version] 28.3 Raw Socket Output......Page 843
[Trial version] 28.4 Raw Socket Input......Page 845
[Trial version] 28.5 'ping' Program......Page 848
[Trial version] 28.6 'traceroute' Program......Page 861
[Trial version] 28.7 An ICMP Message Daemon......Page 874
[Trial version] 28.8 Summary......Page 889
[Trial version] Exercises......Page 890
[Trial version] Chapter 29. Datalink Access......Page 891
[Trial version] 29.1 Introduction......Page 892
[Trial version] 29.2 BSD Packet Filter (BPF)......Page 893
[Trial version] 29.3 Datalink Provider Interface (DLPI)......Page 895
[Trial version] 29.4 Linux: 'SOCK_PACKET' and 'PF_PACKET'......Page 896
[Trial version] 29.5 'libpcap': Packet Capture Library......Page 898
[Trial version] 29.6 'libnet': Packet Creation and Injection Library......Page 899
[Trial version] 29.7 Examining the UDP Checksum Field......Page 900
[Trial version] 29.8 Summary......Page 919
[Trial version] Exercises......Page 920
[Trial version] Chapter 30. Client/Server Design Alternatives......Page 921
[Trial version] 30.1 Introduction......Page 922
[Trial version] 30.2 TCP Client Alternatives......Page 924
[Trial version] 30.3 TCP Test Client......Page 925
[Trial version] 30.4 TCP Iterative Server......Page 927
[Trial version] 30.5 TCP Concurrent Server, One Child per Client......Page 928
[Trial version] 30.6 TCP Preforked Server, No Locking Around 'accept'......Page 932
[Trial version] 30.7 TCP Preforked Server, File Locking Around 'accept'......Page 938
[Trial version] 30.8 TCP Preforked Server, Thread Locking Around 'accept'......Page 941
[Trial version] 30.9 TCP Preforked Server, Descriptor Passing......Page 943
[Trial version] 30.10 TCP Concurrent Server, One Thread per Client......Page 949
[Trial version] 30.11 TCP Prethreaded Server, per-Thread 'accept'......Page 951
[Trial version] 30.12 TCP Prethreaded Server, Main Thread 'accept'......Page 954
[Trial version] 30.13 Summary......Page 957
[Trial version] Exercises......Page 958
[Trial version] Chapter 31. Streams......Page 959
[Trial version] 31.1 Introduction......Page 960
[Trial version] 31.2 Overview......Page 961
[Trial version] 31.3 'getmsg' and 'putmsg' Functions......Page 965
[Trial version] 31.4 'getpmsg' and 'putpmsg' Functions......Page 967
[Trial version] 31.5 'ioctl' Function......Page 968
[Trial version] 31.6 Transport Provider Interface (TPI)......Page 969
[Trial version] 31.7 Summary......Page 979
[Trial version] Exercises......Page 980
[Trial version] Appendix A. IPv4, IPv6, ICMPv4, and ICMPv6......Page 981
[Trial version] A.1 Introduction......Page 982
[Trial version] A.2 IPv4 Header......Page 983
[Trial version] A.3 IPv6 Header......Page 985
[Trial version] A.4 IPv4 Addresses......Page 988
[Trial version] A.5 IPv6 Addresses......Page 991
[Trial version] A.6 Internet Control Message Protocols (ICMPv4 and ICMPv6)......Page 995
[Trial version] Appendix B. Virtual Networks......Page 998
[Trial version] B.1 Introduction......Page 999
[Trial version] B.2 The MBone......Page 1000
[Trial version] B.3 The 6bone......Page 1002
[Trial version] B.4 IPv6 Transition: 6to4......Page 1003
[Trial version] Appendix C. Debugging Techniques......Page 1004
[Trial version] C.1 System Call Tracing......Page 1005
[Trial version] C.2 Standard Internet Services......Page 1007
[Trial version] C.3 'sock' Program......Page 1008
[Trial version] C.4 Small Test Programs......Page 1011
[Trial version] C.5 'tcpdump' Program......Page 1012
[Trial version] C.6 'netstat' Program......Page 1013
[Trial version] C.7 'lsof' Program......Page 1014
[Trial version] Appendix D. Miscellaneous Source Code......Page 1015
[Trial version] D.1 'unp.h' Header......Page 1016
[Trial version] D.2 'config.h' Header......Page 1021
[Trial version] D.3 Standard Error Functions......Page 1027
[Trial version] Appendix E. Solutions to Selected Exercises......Page 1030
[Trial version] Chapter 1......Page 1032
[Trial version] Chapter 2......Page 1034
[Trial version] Chapter 3......Page 1036
[Trial version] Chapter 4......Page 1037
[Trial version] Chapter 5......Page 1038
[Trial version] Chapter 6......Page 1042
[Trial version] Chapter 7......Page 1044
[Trial version] Chapter 8......Page 1050
[Trial version] Chapter 9......Page 1053
[Trial version] Chapter 10......Page 1055
[Trial version] Chapter 11......Page 1057
[Trial version] Chapter 12......Page 1063
[Trial version] Chapter 13......Page 1064
[Trial version] Chapter 14......Page 1065
[Trial version] Chapter 15......Page 1066
[Trial version] Chapter 16......Page 1070
[Trial version] Chapter 17......Page 1071
[Trial version] Chapter 18......Page 1072
[Trial version] Chapter 20......Page 1073
[Trial version] Chapter 21......Page 1074
[Trial version] Chapter 22......Page 1076
[Trial version] Chapter 24......Page 1079
[Trial version] Chapter 25......Page 1081
[Trial version] Chapter 26......Page 1082
[Trial version] Chapter 27......Page 1083
[Trial version] Chapter 28......Page 1084
[Trial version] Chapter 29......Page 1085
[Trial version] Chapter 30......Page 1086
[Trial version] Chapter 31......Page 1087
[Trial version] Bibliography......Page 1088