NAME
Net::Frame::Layer::RIPng - Routing Information Protocol ng layer object
SYNOPSIS
use Net::Frame::Simple;
use Net::Frame::Layer::RIPng qw(:consts);
my $layer = Net::Frame::Layer::RIPng->new(
command => NF_RIPNG_COMMAND_REQUEST,
version => 1,
reserved => 0,
);
#
# Read a raw layer
#
my $layer = Net::Frame::Layer::RIPng->new(raw => $raw);
print $layer->print."\n";
print 'PAYLOAD: '.unpack('H*', $layer->payload)."\n"
if $layer->payload;
DESCRIPTION
This modules implements the encoding and decoding of the RIPng layer.
RFC: ftp://ftp.rfc-editor.org/in-notes/rfc2080.txt
See also Net::Frame::Layer for other attributes and methods.
ATTRIBUTES
- command
-
RIP command. See CONSTANTS for more information.
- version
-
RIPng protocol version: 1 valid.
- reserved
-
Default set to 0.
The following are inherited attributes. See Net::Frame::Layer for more information.
- raw
- payload
- nextLayer
METHODS
- new
- new (hash)
-
Object constructor. You can pass attributes that will overwrite default ones. See SYNOPSIS for default values.
- getKey
- getKeyReverse
-
These two methods are basically used to increase the speed when using recv method from Net::Frame::Simple. Usually, you write them when you need to write match method.
- match (Net::Frame::Layer::RIPng object)
-
This method is mostly used internally. You pass a Net::Frame::Layer::RIPng layer as a parameter, and it returns true if this is a response corresponding for the request, or returns false if not.
The following are inherited methods. Some of them may be overriden in this layer, and some others may not be meaningful in this layer. See Net::Frame::Layer for more information.
- layer
- computeLengths
- pack
- unpack
- encapsulate
- getLength
- getPayloadLength
- dump
CONSTANTS
Load them: use Net::Frame::Layer::RIPng qw(:consts);
- NF_RIPNG_DEST_HWADDR
- NF_RIPNG_DEST_ADDR
- NF_RIPNG_DEST_PORT
-
Default destination Ethernet address, IPv6 address and UDP port.
- NF_RIPNG_COMMAND_REQUEST
- NF_RIPNG_COMMAND_RESPONSE
-
Commands.
SEE ALSO
AUTHOR
Michael Vincent
COPYRIGHT AND LICENSE
Copyright (c) 2012, Michael Vincent
You may distribute this module under the terms of the Artistic license. See LICENSE.Artistic file in the source distribution archive.