ietf
[Top] [All Lists]

Re: TCP/IP

2002-05-27 07:44:46
On Mon, 27 May 2002 09:38:12 EDT, Bill Cunningham 
<billcu(_at_)citynet(_dot_)net>  said:
Win98 is what I use mostly I also have linux. Your right I'd like to enter

For Linux, you have the source - go poke around in /usr/src/linux/drivers/net
which contains the bottom half of the stack (the device drivers).  The
top half, which does protocol support, is under /usr/src/linux/net/*.

Please note that from userspace, you want to be using the provided syscalls,
as you will most certainly generate an error if you go calling kernel code
without a firm understanding of what you're trying to do and why.

I'd certainly stay *FAR* away from any system's TCP stack internals until
I had read *and understood* at least the first volume or two of Comer's books,
and for Unix/Linux, Steven's "Unix Network Programming".  If you don't
recognize those 2 references, you're not ready. ;)

I think you're getting confused by terminology - although many programs
have their function entry points on a "stack", which is vulnerable to
tweaking by buffer overflows and other malware, the entire networking
subsystem is *also* referred to as a "stack" (which makes sense once you
understand the basics of the OSI 7-layer burrito^H^H^H^H^Hmodel).  As such,
the networking code doesn't really *HAVE* a distinct entry point - it's being
called many ways for different things - from userspace via the syscall
interface (to open/bind/send/receive/close a connection), to/from device
drivers to receive packets and queue packets for transmission, hooks into
the system timing services for callbacks to maintain retransmit timers,
and so on.

-- 
                                Valdis Kletnieks
                                Computer Systems Senior Engineer
                                Virginia Tech

Attachment: pgpI8biYVNE2V.pgp
Description: PGP signature

<Prev in Thread] Current Thread [Next in Thread>