NAME

Net::Write::Layer4 - object for a transport layer (layer 4) descriptor

SYNOPSIS

use Net::Write::Layer4 qw(:constants);

# To send a TCP segment to the network
# Encapsulated within an IPv4 network layer
my $desc = Net::Write::Layer4->new(
   dst      => $targetIpAddress,
   protocol => NW_IPPROTO_TCP,
   family   => NW_AF_INET,
);

$desc->open;
$desc->send($rawStringToNetwork);
$desc->close;

DESCRIPTION

This is the class for creating a layer 4 descriptor.

ATTRIBUTES

dev

The string specifying network interface to use.

dst

The target IP address we will send frames to.

METHODS

See Net::Write::Layer for inherited methods.

CONSTANTS

Load them: use Net::Write::Layer4 qw(:constants);

NW_AF_INET
NW_AF_INET6

Address family constants.

NW_IPPROTO_TCP
NW_IPPROTO_UDP
NW_IPPROTO_ICMPv4
NW_IPPROTO_ICMPv6

Protocol type constants.

AUTHOR

Patrice <GomoR> Auffret

COPYRIGHT AND LICENSE

Copyright (c) 2006, Patrice <GomoR> Auffret

You may distribute this module under the terms of the Artistic license. See Copying file in the source distribution archive.

RELATED MODULES

Net::Packet, Net::RawIP, Net::RawSock