Networking Forums

Networking Forums > Computer Networking > Linux Networking > inpcb or tcpcb in Linux net souce code

Reply
Thread Tools Display Modes

inpcb or tcpcb in Linux net souce code

 
 
Soohyun Cho
Guest
Posts: n/a

 
      05-21-2004, 05:11 PM
Hi all,

I want to search all tcp connections in kernel.
In BSD there are inpcb (Internet protocol control block) and tcpcb (TCP
control block) and the inpcb entities are connected by doubly linked lists.
I think Linux has sock and tcp_opt which are corresponding to insub and
tcpcb respectively.
However I couldn't figure it out whether socks are connected by anyway.
Are they linked by doubly linked list or some other way?
Is there any way I can search all connections in kernel?

I think netstat program is already doing this in kernel level.
But I coundn't find netstat's source code also.

Thank a lot.

Soohyun Cho


 
Reply With Quote
 
 
 
 
Soohyun Cho
Guest
Posts: n/a

 
      05-21-2004, 10:34 PM
I found it.

It is "struct sock" in include/net/sock.h.
Thanks,


Soohyun Cho wrote:
> Hi all,
>
> I want to search all tcp connections in kernel.
> In BSD there are inpcb (Internet protocol control block) and tcpcb (TCP
> control block) and the inpcb entities are connected by doubly linked lists.
> I think Linux has sock and tcp_opt which are corresponding to insub and
> tcpcb respectively.
> However I couldn't figure it out whether socks are connected by anyway.
> Are they linked by doubly linked list or some other way?
> Is there any way I can search all connections in kernel?
>
> I think netstat program is already doing this in kernel level.
> But I coundn't find netstat's source code also.
>
> Thank a lot.
>
> Soohyun Cho
>
>


 
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Port winsock code to linux Matthew Clark Linux Networking 2 08-12-2006 12:14 AM
source code for linux host command kenkahn Linux Networking 2 02-21-2006 07:22 PM
Checksum code in linux kernel Perianayagam Somasundaram Linux Networking 0 10-27-2005 04:44 AM
How hard it is port VxWorks code to Linux? santa19992000@yahoo.com Linux Networking 3 08-20-2005 11:48 AM
howto determine souce of hack attempt Eric Linux Networking 1 12-19-2003 06:54 AM



1 2 3 4 5 6 7 8 9 10 11