Namespaces   Class Hierarchy   Compound List   File List   Header Files   Compound Members   File Members   Examples  

TCP Class Reference

the TCP-class. More...

#include <usi++.h>

Class diagram for TCP:

IP Datalink

List of all members.

Public Members


Detailed Description

the TCP-class.

Examples:
blindSpoof.cc and tcp_sniff.cc.

Member Function Documentation

u_int16_t TCP::get_srcport ()

Get the sourceport in human-readable form.

Examples:
blindSpoof.cc and tcp_sniff.cc.

u_int16_t TCP::get_dstport ()

Get the destinationport in human-readable form.

Examples:
blindSpoof.cc and tcp_sniff.cc.

u_int32_t TCP::get_seq ()

Get TCP-sequencenumber

Examples:
blindSpoof.cc.

u_int32_t TCP::get_ack ()

Get the actual achnkowledge-number from the TCP-header.

Examples:
blindSpoof.cc.

u_int8_t TCP::get_flags ()

Set TCP-flags

Examples:
blindSpoof.cc and tcp_sniff.cc.

u_int16_t TCP::get_tcpsum ()

Get TCP-header checksum

int TCP::set_seq (u_int32_t s)

Set the sequencenumber-filed in the TCP-header.

Examples:
blindSpoof.cc.

int TCP::set_ack (u_int32_t a)

Set the acknowledgenumber-filed in the TCP-header. This is only monitored by the target-kernel, if TH_ACK is set in the TCP-flags.

int TCP::set_flags (u_int8_t f)

Set TCP-flags

Examples:
blindSpoof.cc.

int TCP::set_tcpsum (u_int16_t s)

Set TCP-checksum. Calling this function with s != 0 will prevent sendpack from calculating the checksum!!!

int TCP::recvpack (void * buf, int len) [virtual]

Receive a TCP-packet, destinated for this host.

Reimplemented from IP.

int TCP::sniffpack (void * buf, int len) [virtual]

Sniff a TCP-packet.

Reimplemented from IP.

Examples:
tcp_sniff.cc.

int TCP::sendpack (void * buf, int paylen) [virtual]

Send a TCP-packet

Reimplemented from IP.

Examples:
blindSpoof.cc.

int TCP::init_device (char * dev, int promisc, int snaplen) [virtual]

Initialize a device ("eth0" for example) for packet- capturing. It MUST be called before sniffpack() is launched. Set 'promisc' to 1 if you want the device running in promiscous mode. Fetch at most 'snaplen' bytes per call.

Reimplemented from Datalink.

Examples:
tcp_sniff.cc.

The documentation for this class was generated from the following file:
Generated at Sun Oct 10 13:51:36 1999 for libusi++ by doxygen  written by Dimitri van Heesch, © 1997-1999