3
I want to know how a network packet travels through different layers, i.e. from the physical layer to the presentation layer in Linux systems.
Are there any detailed articles or books on this topic with code?
3
I want to know how a network packet travels through different layers, i.e. from the physical layer to the presentation layer in Linux systems.
Are there any detailed articles or books on this topic with code?
2
The OSI layer model isn't how networking is actually programmed. You might check this book if you're interested in C code samples:
This book is not what I exactly wanted. It is mostly on tcp/ip. I want codes for other layers also. – ranjit – 2010-09-28T18:58:04.830
By other layers you mean ...? – hotei – 2010-09-28T20:39:01.677
0
not cheap, but one of the definite classics. Richad Stevens: "TCP/IP Illustrated Vol.1 The Protocols". Very thorough, covers of course also UDP, ICMP, etc. pp.
If your're into programming, there's also "TCP/IP Illustrated Vol. 2 The Implementation" by Gary Wright.
0
7 Application
6 Presentation
5 Session
4 Transport
3 Network
2 Data
1 Physical
TCP / IP combines certain layers
7-5 Application
4 Transport
3 Internetwork
2-1 Network Access
Conceptually the OSI model looks like this
7 Application---- ------------- Application
6 Presentation--- ------------- Presentation
5 Session-------- ------------- Session
4 Transport------ ------------- Transport
3 Network-------- ---Network--- Network
2 Data----------- ---Data------ Data
1 Physical------- ---Physical-- Physical
Each send layer appears to communicate transparently to the corresponding receive layer. In routed networks (middle column) the same is true.
As a packet descends from 7 to 1 each layer attaches header information that the layer below sees as a Protocol Data Unit. As the packet ascends the the model each layer removes the header.
Ummm... sorry to be harsh but.. something is wrong - you failed to google, yet you answered and upvoted hotei's answer on OSI?! OSI is the key to understanding the different layers...you should not have to worry about the layers - let the network layer take care of it for you, OSI layer 4... – t0mm13b – 2010-09-28T21:22:38.167