Net::F...:Option(3pm)

πŸ“¦
version 1.08 Β· 2 versions
  • 1.08 Β· debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking (latest)
  • 1.08 Β· ubuntu jammy
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– Net::F...:Option(3pm) β€” bestie, it's the IPv6 Option object ✨

okay so this is Net::F...:Option(3pm), straight out of the User Contributed Perl Documentation collection, and it's literally the manual page for Net::Frame::Layer::IPv6::Option πŸ¦‹


🌸 NAME 🌸

Net::Frame::Layer::IPv6::Option β€” it's an IPv6 Option object πŸ’… no cap


✨ SYNOPSIS ✨

here's the whole vibe, copy-paste ready, no edits from me, promise 🫢

use Net::Frame::Layer::IPv6::Option;

my $layer = Net::Frame::Layer::IPv6::Option->new(
   type   => 1,
   length => 0,
   value  => '',
);
$layer->pack;

print 'RAW: '.$layer->dump."\n";

# Read a raw layer
my $layer = Net::Frame::Layer::IPv6::Option->new(
   raw => $raw,
);

print $layer->print."\n";
print 'PAYLOAD: '.unpack('H*', $layer->payload)."\n"
   if $layer->payload;

like, build it, pack it, dump it, done πŸŽ€ and if you already have raw bytes lying around, just hand them over with raw and it'll decode them for you. iconic.


πŸ’œ DESCRIPTION πŸ’œ

so this module implements the encoding and decoding of IPv6 Options. that's the whole job. it does it, it does it well, periodt πŸ’…

also, go look at Net::Frame::Layer for the other attributes and methods, iykyk β€” that's where the family drama lives.


πŸ¦‹ ATTRIBUTES πŸ¦‹

  • type β€” the type of IPv6 option. that's it, that's the field 🌈
  • length β€” the length of the IPv6 option, counted as a number of bytes, and yes bestie it includes the type and length fields themselves, don't forget that part 😭
  • value β€” the value. the actual content. the main character 🫢

and okay, the little lore drop: the default type, length and value together create the PadN option padding, where N=2 ✨ cute right

the following are inherited attributes β€” go read Net::Frame::Layer for more info, she has the full tea β˜•

  • raw
  • payload
  • nextLayer

πŸŽ€ METHODS πŸŽ€

new

new (hash)

object constructor πŸ’– you can pass attributes and they'll overwrite the default ones β€” peek at SYNOPSIS above for the default values, they're right there, no gatekeeping.

the following are inherited methods. some of them may be overridden in this layer, and some others may not be meaningful in this layer at all πŸ’€ β€” check Net::Frame::Layer for more info.

  • layer
  • computeLengths
  • computeChecksums
  • pack
  • unpack
  • encapsulate
  • getLength
  • getPayloadLength
  • print
  • dump

🌈 CONSTANTS 🌈

No constants here. empty. nada. the void. πŸ•³οΈ


⭐ SEE ALSO ⭐

  • Net::Frame::Layer::IPv6
  • Net::Frame::Layer

πŸ‘‘ AUTHOR πŸ‘‘

Patrice <GomoR> Auffret</GomoR> β€” king behaviour, fr fr πŸ’œ


Copyright (c) 2006-2017, Patrice <GomoR> Auffret

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

bestie, license stuff is not a joke β€” read the file, respect the file, it's giving legal πŸ’…

and that's the whole page!! this one's perl v5.36.0, dated 2022-11-19, filed under Net::F...:Option(3pm) β€” bye bestie, go pad some options πŸŒΈπŸ¦‹βœ¨