GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages
Net::Packet::Desc(3) User Contributed Perl Documentation Net::Packet::Desc(3)

Net::Packet::Desc - base class for all desc modules

This is the base class for Net::Packet::DescL2, Net::Packet::DescL3 and Net::Packet::DescL4 modules.

It just provides those layers with inheritable attributes and methods.

A descriptor is required when you want to send frames over network.

dev
Network device to use to send frames. Default to use dev set in default $Env object.
ip
Same as above for IP. This is the source IP address to use.
ip6
Same as above for IPv6. This is the source IPv6 address to use.
mac
Same as above for MAC. This is the source MAC address to use.
gatewayIp
Same as above, for gateway IP address.
gatewayMac
Same as above, for gateway MAC address. It is not automatically set here. It is automatically set only under Windows, when using a Net::Packet::DescL3 object.
target
Used to create a Net::Packet::DescL3 and Net::Packet::DescL4. At these layers, one MUST specifiy the target IP address to tell kernel where to send frames.
targetMac
Used to automatically build layer 2 when using a Net::Packet::DescL3 object under Windows.
protocol
This is the transport protocol to use (TCP, UDP, ...). Used in Net::Packet::DescL4 objects. Default to TCP.
family
Same as abose, to tell which network protocol to use (IPv4, IPv6).

send (scalar)
Send the raw data passed as a parameter.
close
Close the descriptor.
isDescL2
isDescL3
isDescL4
Returns true if Desc is of specified type, false otherwise.

Load them: use Net::Packet::Consts qw(:desc);
NP_DESC_IPPROTO_IP
NP_DESC_IPPROTO_IPv6
NP_DESC_IPPROTO_RAW
NP_DESC_IPPROTO_TCP
NP_DESC_IPPROTO_UDP
NP_DESC_IPPROTO_ICMPv4
NP_DESC_IP_HDRINCL
NP_DESC_L2
NP_DESC_L3
NP_DESC_L4

Patrice <GomoR> Auffret

Copyright (c) 2004-2009, Patrice <GomoR> Auffret

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

NetPacket, Net::RawIP, Net::RawSock
2009-11-09 perl v5.32.1

Search for    or go to Top of page |  Section 3 |  Main Index

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with ManDoc.