You are not signed in. Sign in.


Category IT Books

UNIX Network Programming: The Sockets Networking API, Vol. 1 » (3rd Edition)

Book cover image of UNIX Network Programming: The Sockets Networking API, Vol. 1 by W. Richard Stevens

Authors: W. Richard Stevens, Andrew M. Rudoff, Bill Fenner, Andrew M. Rudoff, Bill Fenner
ISBN-13: 9780131411555, ISBN-10: 0131411551
Format: Hardcover
Publisher: Addison-Wesley
Date Published: October 2003
Edition: 3rd Edition

Find Best Prices for This Book »

Author Biography: W. Richard Stevens

The late W. RICHARD STEVENS was the original author of UNIX Network Programming, First and Second Editions, widely recognized as the classic texts in UNIX networking. BILL FENNER is Principal Technical Staff Member at AT&T Labs in Menlo Park, CA, specializing in IP multicasting, network management, and measurement. He is one of the IETF's Routing Area Directors, responsible for approving all routing-related documents that get published as RFCs. ANDREW M. RUDOFF, Senior Software Engineer at Sun Microsystems, specializes in networking, operating systems internals, file systems, and high availability software architecture.

Book Synopsis

UNIX Network Programming, Volume 1: The Sockets Networking API, Third Edition

"Everyone will want this book because it provides a great mix of practical experience, historical perspective, and a depth of understanding that only comes from being intimately involved in the field. I've already enjoyed and learned from reading this book, and surely you will too."

—Sam LefflerThe classic guide to UNIX networking APIs... now completely updated!

To build today's highly distributed, networked applications and services, you need deep mastery of sockets and other key networking APIs. One book delivers comprehensive, start-to-finish guidance for building robust, high-performance networked systems in any environment: UNIX Network Programming, Volume 1, Third Edition.

Building on the legendary work of W. Richard Stevens, this edition has been fully updated by two leading network programming experts to address today's most crucial standards, implementations, and techniques. New topics include:

  • POSIX Single UNIX Specification Version 3
  • IPv6 APIs (including updated guidance on IPv6/IPv4 interoperability)
  • The new SCTP transport protocol
  • IPsec-based Key Management Sockets
  • FreeBSD 4.8/5.1, Red Hat Linux 9.x, Solaris 9, AIX 5.x, HP-UX, and Mac OS X implementations
  • New network program debugging techniques
  • Source Specific Multicast API, the key enabler for widespread IP multicast deployment

The authors also update and extend Stevens' definitive coverage of these crucial UNIX networking standards and techniques:

  • TCP and UDP transport
  • Sockets:elementary, advanced, routed, and raw
  • I/O: multiplexing, advanced functions, nonblocking, and signal-driven
  • Daemons and inetd
  • UNIX domain protocols
  • ioctl operations
  • Broadcasting and multicasting
  • Threads
  • Streams
  • Design: TCP iterative, concurrent, preforked, and prethreaded servers

Since 1990, network programmers have turned to one source for the insights and techniques they need: W. Richard Stevens' UNIX Network Programming. Now, there's an edition specifically designed for today's challenges—and tomorrow's.


Tutorial on networking for those with a working knowledge of C and the UNIX system. Includes full descriptions for popular protocols such as TCP/IP, XNS, SNA, NetBIOS, OSI, and UUCP. Also includes case studies of real network applications, as well as approximately 15,000 lines of C source code, taken directly from their source files. Annotation c. Book News, Inc., Portland, OR (

Table of Contents

Part 1.Introduction and TCP/IP1
Chapter 1.Introduction3
Chapter 2.The Transport Layer: TCP, UDP, and SCTP31
Part 2.Elementary Sockets65
Chapter 3.Sockets Introduction67
Chapter 4.Elementary TCP Sockets95
Chapter 5.TCP Client/Server Example121
Chapter 6.I/O Multiplexing: The select and poll Functions153
Chapter 7.Socket Options191
Chapter 8.Elementary UDP Sockets239
Chapter 9.Elementary SCTP Sockets267
Chapter 10.SCTP Client/Server Example287
Chapter 11.Name and Address Conversions303
Part 3.Advanced Sockets351
Chapter 12.IPv4 and IPv6 Interoperability353
Chapter 13.Daemon Processes and the inetd Superserver363
Chapter 14.Advanced I/O Functions381
Chapter 15.Unix Domain Protocols411
Chapter 16.Nonblocking I/O435
Chapter 17.ioctl Operations465
Chapter 18.Routing Sockets485
Chapter 19.Key Management Sockets511
Chapter 20.Broadcasting529
Chapter 21.Multicasting549
Chapter 22.Advanced UDP Sockets587
Chapter 23.Advanced SCTP Sockets621
Chapter 24.Out-of-Band Data645
Chapter 25.Signal-Driven I/O663
Chapter 26.Threads675
Chapter 27.IP Options709
Chapter 28.Raw Sockets735
Chapter 29.Datalink Access787
Chapter 30.Client/Server Design Alternatives817
Chapter 31.Streams851
Appendix A.IPv4, IPv6, ICMPv4, and ICMPv6869
A.2IPv4 Header869
A.3IPv6 Header871
A.4IPv4 Addresses874
A.5IPv6 Addresses877
A.6Internet Control Message Protocols (ICMPv4 and ICMPv6)882
Appendix B.Virtual Networks885
B.2The MBone885
B.3The 6bone887
B.4IPv6 Transition: 6to4889
Appendix C.Debugging Techniques891
C.1System Call Tracing891
C.2Standard Internet Services893
C.3sock Program893
C.4Small Test Programs896
C.5tcpdum Program896
C.6netstat Program896
C.7lsof Program897
Appendix D.Miscellaneous Source Code899
D.1unp.h Header899
D.2config.h Header904
D.3Standard Error Functions910
Appendix E.Solutions to Selected Exercises913




No reviews. Submit yours!

Review this book.

We would like to know what you think about this book and publish your thoughts here! (top)

Your Review

  1. You may optionally give a title for this comment.

  2. Worst to best, 1 to 5, what would you rate this one?

  3. The actual content of your comment. No HTML nor whatsoever allowed.

  4. The author of this comment.

  5. How many eyes do you have? Use 1, 2, 3, ... to answer.

    Please answer the question by common sense.