program to collect the packets

Discussion in 'Installation/Configuration' started by full_adder, Mar 8, 2007.

  1. full_adder

    full_adder New Member

    Hi everyone

    I have two machine connected with a crossover cable, I am looking for a C program to collect the data in the reciever machine. I think such these programs are ready and free on the net but I failed to get them.
    If anybody knows a specific program to do that, please provide me.


    thanks a lot
     
  2. martinfst

    martinfst ISPConfig Developer ISPConfig Developer

    Code:
    tcpdump
    is a standard line oriented packet sniffer/dumper, or you could use Wireshark (both Linux and Windows version) if you want nice graphical representation and filtering. tcpdump has a lot of filtering options too. See
    Code:
    man tcpdump
     
  3. full_adder

    full_adder New Member

    but that program is not open source code, it is closed.
    I found out tcpdump.8.gz and tcpslice.gz are located in /usr/share/man/man8.
    I can decompress any of them if I would get the source in C, but tar command does not work correctly here, may be because the file is 8.gz not tar.gz !!
     
  4. martinfst

    martinfst ISPConfig Developer ISPConfig Developer

    Both programs are open source and they are included in Debian/Ubuntu distributions. Maybe they are in restricted, but they are certainly freely available.
    the /usr/share/man/man8/tcpdump.8.gz is part of the man pages. You cannot use that. 1st install the programs with
    Code:
    apt-get install tcpdump
    and then try
    Code:
    man tcpdump
    .
     

Share This Page