Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Am looking for an open source code for the TCP/IP stack. An explanation along the lines of the stack would also help me in understanding the different modules and their interactions. I tried searching but there is very less information relating to just the TCP/IP stack.

share|improve this question
up vote 3 down vote accepted

You can browse the entire Linux kernel at LXR. For example, here's the implementation of TCP over IPv4. Be aware that a full, real-world TCP/IP stack is going to be huge and it's going to be difficult getting a feel from it just by studying source code.

There are many books available which give you more of an overview, such as this one and this one. Follow the "related titles" link in Amazon for many more...

share|improve this answer

Besides the obvious answer of current OSS kernels (Linux and BSD are the usual suspects), there are some other smaller and easier to read implementations. A quick googling gave me these:

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.