亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? cdp.pm

?? Net-CDP-0.09 cdp相關源包
?? PM
字號:
package Net::CDP;## $Id: CDP.pm,v 1.20 2005/08/16 11:52:30 mchapman Exp $#use 5.00503;use strict;use Carp::Clan qw(^Net::CDP);use vars qw($VERSION $XS_VERSION @ISA $AUTOLOAD @EXPORT @EXPORT_OK %EXPORT_TAGS @EXPORT_FAIL);$VERSION = (qw$Revision: 1.20 $)[1];$XS_VERSION = '0.09'; # XXX Keep this in sync with libcdprequire Exporter;require DynaLoader;@ISA = qw(Exporter DynaLoader);my @EXPORT_GENERAL = qw(	CDP_PROMISCUOUS);my @EXPORT_RECV = qw(	CDP_RECV_NONBLOCK CDP_RECV_DECODE_ERRORS);my @EXPORT_CAPS = qw(	CDP_CAP_ROUTER CDP_CAP_TRANSPARENT_BRIDGE CDP_CAP_SOURCE_BRIDGE	CDP_CAP_SWITCH CDP_CAP_HOST CDP_CAP_IGMP CDP_CAP_REPEATER);my @EXPORT_PROTOS = qw(	CDP_ADDR_PROTO_CLNP CDP_ADDR_PROTO_IPV4 CDP_ADDR_PROTO_IPV6	CDP_ADDR_PROTO_DECNET CDP_ADDR_PROTO_APPLETALK CDP_ADDR_PROTO_IPX	CDP_ADDR_PROTO_VINES CDP_ADDR_PROTO_XNS CDP_ADDR_PROTO_APOLLO);@EXPORT = qw();@EXPORT_OK = (@EXPORT_CAPS, @EXPORT_PROTOS, @EXPORT_GENERAL, @EXPORT_RECV, );%EXPORT_TAGS = (	general => [ @EXPORT_GENERAL, ],	recv => [ @EXPORT_RECV, ],	caps => [ @EXPORT_CAPS, ],	protos => [ @EXPORT_PROTOS, ],);@EXPORT_FAIL = (@EXPORT_OK, );sub AUTOLOAD {	my $constname;	($constname = $AUTOLOAD) =~ s/.*:://;	croak '&Net::CDP::constant not defined' if $constname eq 'constant';	my ($error, $val) = Net::CDP::Constants::constant($constname);	croak $error if $error;		no strict 'refs';	*$AUTOLOAD = sub { $val };	goto &$AUTOLOAD;}# If you REALLY need the warnings suppressed, set this to 0use vars qw($warn_deprecated);$warn_deprecated = 1;{	my $warned;	sub _deprecated() {		return unless $warn_deprecated;		return if $warned;		$warned = 1;		warn <<EOF;************************************************************* You're using a deprecated interface! Check out the ****** Net::CDP documentation for more info.              *************************************************************EOF	}}sub export_fail(@) {	my $self = shift;	_deprecated;	();}bootstrap Net::CDP $XS_VERSION;# Load in the Perl part of the Net::CDP::Address# and Net::CDP::IPPrefix namespacesrequire Net::CDP::Address;require Net::CDP::IPPrefix;sub _parse_args($@) {	croak 'Invalid arguments' if @{$_[0]} % 2;	my %args = @{+shift};	my %check = map { $_ => 1 } keys %args;	foreach (@_) {		delete $check{$_} if exists $check{$_};	}	croak "Unknown argument '$_'" foreach keys %check;	%args;}sub _v4_pack {	my $ip = shift;		if ($ip =~ /^(\d+)\.(\d+)\.(\d+)\.(\d+)$/ &&		$1 >= 0 && $1 <= 255 &&		$2 >= 0 && $2 <= 255 &&		$3 >= 0 && $3 <= 255 &&		$4 >= 0 && $4 <= 255	) {		pack 'C4', $1, $2, $3, $4;	} elsif ($ip =~ /^(\d+)\.(\d+)\.(\d+)$/ &&		$1 >= 0 && $1 <= 255 &&		$2 >= 0 && $2 <= 255 &&		$3 >= 0 && $3 <= 255	) {		pack 'C4', $1, $2, 0, $3;	} elsif ($ip =~ /^(\d+)\.(\d+)$/ &&		$1 >= 0 && $1 <= 255 &&		$2 >= 0 && $2 <= 255	) {		pack 'C4', $1, 0, 0, $4;	} else {		undef;	}}sub _v4_unpack {	join '.', unpack 'C4', shift;}use constant POWERS => "\x00\x80\xc0\xe0\xf0\xf8\xfc\xfe\xff";sub _mask_pack {	my $mask = shift;	if ($mask =~ /^255\.255\.255\.(\d+)$/) {		my $index = index POWERS, chr $1;		$index >= 0 ? 24 + $index : undef;	} elsif ($mask =~ /^255\.255\.(\d+)\.0$/) {		my $index = index POWERS, chr $1;		$index >= 0 ? 16 + $index : undef;	} elsif ($mask =~ /^255\.(\d+)\.0\.0$/) {		my $index = index POWERS, chr $1;		$index >= 0 ? 8 + $index : undef;	} elsif ($mask =~ /^(\d+)\.0\.0\.0$/) {		my $index = index POWERS, chr $1;		$index >= 0 ? $index : undef;	} else {		undef;	}}sub _mask_unpack {	_v4_unpack(pack 'B32', 1 x shift);}sub _v6_pack {	my $ip = shift;	if ($ip =~ /^([\da-f\:]+)(?::(\d+)\.(\d+)\.(\d+)\.(\d+))?$/i) {		my $ipv6 = $1;		if (			defined $2 &&			$2 >= 0 && $2 <= 255 &&			$3 >= 0 && $3 <= 255 &&			$4 >= 0 && $4 <= 255 &&			$5 >= 0 && $5 <= 255		) {			$ipv6 .= sprintf ':%x:%x',				($2 << 8) | $3,				($4 << 8) | $5;		}		unless ($ipv6 =~ /:::/ || $ipv6 =~ /::.*::/) {			$ipv6 =~ s/::/':0' x (9 - ($ipv6 =~ tr,:,:,))/e;			if (($ipv6 =~ tr/:/:/) == 7) {				$ipv6 =~ s/^:/0:/;				$ipv6 =~ s/:$/:0/;				return pack 'n8', map hex, split /:/, $ipv6;			}		}	}	undef;}sub _v6_unpack {	my $result = sprintf '%x:%x:%x:%x:%x:%x:%x:%x', unpack 'n8', shift;	$result =~ s/:0(:0)+:/::/;	$result =~ s/^0:/:/;	$result;}sub _rethrow(&) {	my $sub = shift;	if (wantarray) {		my @result = eval { &$sub };		if ($@) {			$@ =~ s/ at \S+ line \d+\.\n\z//;			croak $@;		}		@result;	} else {		my $result = eval { &$sub };		if ($@) {			$@ =~ s/ at \S+ line \d+\.\n\z//;			croak $@;		}		$result;	}}=head1 NAMENet::CDP - Cisco Discovery Protocol (CDP) advertiser/listener=head1 SYNOPSIS  use Net::CDP;  # Available network ports  @ports = Net::CDP::ports;    # Creating a CDP advertiser/listener  $cdp = new Net::CDP;  # Receiving a CDP packet  $packet = $cdp->recv;    # Sending a CDP packet  $cdp->send($packet);    # Other Net::CDP methods  $port = $cdp->port;  @addresses = $cdp->addresses;=head1 DESCRIPTIONThe Net::CDP module implements an advertiser/listener for the CiscoDiscovery Protocol.CDP is a proprietary Cisco protocol for discovering devices on a network. Atypical CDP implementation sends periodic CDP packets on every networkport. It might also listen for packets for advertisements sent by neighboringdevices.A Net::CDP object represents an advertiser/listener for a single networkport. It can send and receive individual CDP packets, each represented by aL<Net::CDP::Packet> object.To manage multiple ports simultaneously, you might like to take a look atL<Net::CDP::Manager>.If you are upgrading code from an older version of Net::CDP, please read theL</"UPGRADING FROM PREVIOUS VERSIONS"> section below.=head1 CONSTRUCTORS=over=item B<new>    $cdp = new Net::CDP($port)    $cdp = new Net::CDP(             [ port        => $port,        ]             [ promiscuous => $promiscuous, ] # default = 0             [ enable_recv => $enable_recv, ] # default = 1             [ enable_send => $enable_send, ] # default = 1           );Returns a new Net::CDP object.If specified, C<$port> must be the name of the network port that should be usedto send and receive packets. If no port is specified, the first port on yoursystem is used (typically, this is the first Ethernet device -- "eth0", forinstance).You can use the L</"ports"> class method to retrieve a list of valid port names.If C<$promiscuous> is non-zero, then promiscuous mode is enabled on thespecified port. Otherwise, Net::CDP attempts to use a multicast ethernetaddress instead. Multicast addresses may not work with all network drivers.By default, C<$enable_recv> and C<$enable_send> are both 1. If either of theseare set to 0 the corresponding function is disabled. This saves a small amountof memory and a file descriptor, and might be useful when you do not intend toboth send and receive packets. You probably won't want to set I<both> to 0.This constructor used to take a single argument, C<$flags>. This is nowdeprecated. See L</"UPGRADING FROM PREVIOUS VERSIONS"> below.=back=cutsub new($;@) {	my $class = shift;	my $port;	my $flags = 0;		if (@_ == 2 && $_[1] =~ /^\d+$/) {		_deprecated;		$flags = pop;	}		$port = shift if @_ == 1;	my %args = _parse_args \@_, qw(port promiscuous enable_recv enable_send);		$port = $args{port} if exists $args{port};	$flags |= CDP_PROMISCUOUS() if $args{promiscuous};	$flags |= CDP_DISABLE_RECV()		if exists $args{enable_recv} && !$args{enable_recv};	$flags |= CDP_DISABLE_SEND()		if exists $args{enable_send} && !$args{enable_send};	carp "enable_recv => 0 and enable_send => 0 both specified"		if $flags & CDP_DISABLE_RECV() and $flags & CDP_DISABLE_SEND();		_rethrow { $class->_new($port, $flags) };}=head1 CLASS METHODS=over =item B<ports>    @ports = Net::CDP::ports()Returns a list of network ports that can be used by this module.=back=cutsub ports() { _rethrow { _ports(); } }=head1 OBJECT METHODS=over=item B<port>    $port = $cdp->port()Returns the network port associated with this Net::CDP object.=item B<addresses>    @addresses = $cdp->addresses()Returns the addresses of the network port associated with thisNet::CDP object. In scalar context the number of addresses is returned.I<NOTE:> Currently only a single IPv4 address is returned, even if the porthas more than one bound address.=item B<recv>    $packet = $cdp->recv(                 [ nonblock      => $nonblock,      ] # default = 0                 [ decode_errors => $decode_errors, ] # default = 0              )Returns the next available CDP packet as a L<Net::CDP::Packet> object. If theC<$nonblock> flag is set, an undefined value returned if no packets areimmediately available. Otherwise, this method blocks until a packet is receivedor an error occurs. If an error occurs, this method croaks.By default, decoding errors will be silently ignored. If C<$decode_errors> isset, this method will croak on a decoding error.This method used to take a single argument, C<$flags>. This is nowdeprecated. See L</"UPGRADING FROM PREVIOUS VERSIONS"> below.=cutsub recv($;@) {	my $self = shift;	my $flags = 0;		if (@_ == 1 && $_[0] =~ /^\d+$/) {		_deprecated;		$flags = pop;	}		my %args = _parse_args \@_, qw(nonblock decode_errors);		$flags |= CDP_RECV_NONBLOCK() if $args{nonblock};	$flags |= CDP_RECV_DECODE_ERRORS() if  $args{decode_errors};		_rethrow { $self->_recv($flags) };}=item B<send>    $bytes = $cdp->send($packet)Transmits the specified packet, which must be a L<Net::CDP::Packet> object,and returns the number of bytes sent. If an error occurs, this method croaks.=back=cutsub send($;@) {	my $self = shift;	my $packet;		$packet = shift if @_ == 1;	my %args = _parse_args \@_, qw(packet);		$packet = $args{packet} if exists $args{packet};		croak 'No packet supplied' unless defined $packet;		_rethrow { $self->_send($packet) };}=head1 UPGRADING FROM PREVIOUS VERSIONSNet::CDP version 0.07 introduces the use of named arguments instead of flagbitmaps for the L</"new"> constructor and L</"recv"> method. Furthermore, theC<:caps> and C<:protos> import tags now live in L<Net::CDP::Packet> andL<Net::CDP::Address> respectively.A warning is generated the first time you attempt to use a deprecated feature.Actual support for the old-style flag bitmaps will be removed soon. To upgradeyour code you will need to:=over=item *Do not import the C<:general> or C<:recv> tags; use named argumentsin calls to L</"new"> and L</"recv"> instead.=item *Replace C<use Net::CDP qw(:caps)> with C<use Net::CDP::Packet qw(:caps)>, andC<use Net::CDP qw(:protos)> with C<use Net::CDP::Address qw(:protos)>.=back=head1 SEE ALSOL<Net::CDP::Packet>=head1 AUTHORMichael Chapman, E<lt>cpan@very.puzzling.orgE<gt>=head1 COPYRIGHT AND LICENSECopyright (C) 2005 by Michael Chapmanlibcdp is released under the terms and conditions of the GNU Library GeneralPublic License version 2. Net::CDP may be redistributed and/or modified underthe same terms as Perl itself.=cut1;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产午夜精品久久久久久久 | 亚洲欧洲三级电影| 精品久久久久久亚洲综合网| 欧美日韩aaaaaa| 欧美日本一道本| 在线电影一区二区三区| 欧美一级理论片| 久久精品视频免费| 日本一区二区在线不卡| 国产精品三级av在线播放| 国产精品毛片大码女人| 亚洲柠檬福利资源导航| 亚洲一区二区三区自拍| 男男成人高潮片免费网站| 国产永久精品大片wwwapp| 国产69精品久久99不卡| 99精品欧美一区二区三区小说 | 国产在线精品国自产拍免费| 国产精品系列在线观看| 91在线免费视频观看| 在线看国产一区| 日韩精品中文字幕一区二区三区| 久久综合999| 夜夜精品视频一区二区| 五月综合激情网| 国产一区不卡视频| 色综合久久88色综合天天| 91精品在线观看入口| 国产免费成人在线视频| 亚洲成人自拍偷拍| 国产乱对白刺激视频不卡| 欧美在线观看禁18| 久久久欧美精品sm网站| 亚洲午夜电影在线| 成人在线综合网| 51精品秘密在线观看| 国产精品久久久久久久蜜臀| 日韩国产高清影视| av亚洲精华国产精华| 日韩三级.com| 亚洲国产精品影院| 成人精品免费视频| 日韩一区二区精品在线观看| 亚洲视频一二区| 国产激情视频一区二区在线观看| 欧美色图在线观看| 中文字幕亚洲电影| 国产一区二区三区四区五区入口| 欧美三级电影网站| 国产精品九色蝌蚪自拍| 狠狠v欧美v日韩v亚洲ⅴ| 欧美亚洲国产一区二区三区va | 欧美色图在线观看| 国产精品久久夜| 国产精品影视天天线| 欧美精品自拍偷拍| 亚洲一区二区三区四区的| 成人禁用看黄a在线| 国产偷国产偷亚洲高清人白洁| 日韩国产在线观看一区| 欧美色网一区二区| 亚洲精品水蜜桃| 91黄色小视频| 一区二区三区成人| 91麻豆免费看| 亚洲黄色在线视频| 日本道精品一区二区三区| 自拍av一区二区三区| av电影天堂一区二区在线| 欧美国产一区二区| youjizz久久| 亚洲视频免费在线| 一本久久a久久免费精品不卡| 国产精品国产精品国产专区不蜜| 成人久久久精品乱码一区二区三区| 日韩精品一区二区三区视频播放| 婷婷国产在线综合| 欧美一区二区三区的| 午夜视频一区二区| 欧美福利视频一区| 美国毛片一区二区| 精品国产露脸精彩对白| 国产一区二区在线观看视频| 精品理论电影在线| 国产精品99久久久久| 国产精品美日韩| 在线中文字幕一区| 青青草成人在线观看| 精品成人免费观看| av在线播放不卡| 一区二区三区在线免费观看| 欧美美女直播网站| 精品一区二区影视| 国产精品盗摄一区二区三区| 日本高清不卡视频| 麻豆成人久久精品二区三区红| xfplay精品久久| 91麻豆免费在线观看| 日韩av在线播放中文字幕| 欧美一卡在线观看| 波波电影院一区二区三区| 亚洲第一福利一区| 久久亚洲精品国产精品紫薇| 99精品视频中文字幕| 日韩精品电影一区亚洲| 久久久久99精品国产片| 欧美性受极品xxxx喷水| 国产一区二区按摩在线观看| 亚洲欧美日韩电影| 日韩精品一区国产麻豆| 99精品黄色片免费大全| 美腿丝袜在线亚洲一区| 综合久久久久综合| 欧美videos大乳护士334| 色婷婷av久久久久久久| 老司机精品视频导航| 亚洲欧美日韩电影| 久久―日本道色综合久久| 在线看国产日韩| 国产成人精品影院| 蜜桃视频在线一区| 一区二区三区美女| 国产日韩一级二级三级| 91 com成人网| 色噜噜狠狠成人中文综合| 国产老妇另类xxxxx| 日韩在线卡一卡二| 亚洲一区二区三区四区在线观看| 久久九九99视频| 欧美一级淫片007| 欧美日本视频在线| 色综合亚洲欧洲| av资源网一区| 成人免费毛片片v| 国产专区欧美精品| 麻豆国产精品一区二区三区| 婷婷综合在线观看| 依依成人综合视频| 亚洲同性gay激情无套| 日本一区二区高清| 国产婷婷一区二区| 国产日韩成人精品| 国产午夜三级一区二区三| 日韩精品中文字幕在线不卡尤物| 6080日韩午夜伦伦午夜伦| 欧洲av一区二区嗯嗯嗯啊| 99精品视频一区二区三区| av亚洲产国偷v产偷v自拍| www.亚洲精品| 91在线观看免费视频| 91影院在线免费观看| 99精品国产热久久91蜜凸| 91在线视频网址| 91美女福利视频| 在线观看一区日韩| 精品视频在线免费观看| 欧美日韩一本到| 欧美电影在线免费观看| 欧美一区二区成人6969| 精品国产一二三| 国产精品水嫩水嫩| 亚洲人成网站精品片在线观看 | 丝袜国产日韩另类美女| 午夜视频一区在线观看| 美日韩一区二区| 精品一区二区三区在线观看国产| 狠狠色狠狠色综合系列| 国产成人免费在线观看不卡| 成人精品亚洲人成在线| 欧美在线|欧美| 777午夜精品视频在线播放| 日韩午夜三级在线| 国产日产欧美精品一区二区三区| 国产精品久久免费看| 亚洲男人天堂av网| 视频一区二区中文字幕| 国产美女一区二区| 一本在线高清不卡dvd| 91精品麻豆日日躁夜夜躁| 精品国产亚洲在线| 亚洲另类色综合网站| 毛片一区二区三区| eeuss国产一区二区三区| 欧美丰满高潮xxxx喷水动漫| 精品久久99ma| 亚洲视频在线一区观看| 男人的天堂久久精品| 99国产欧美久久久精品| 3atv在线一区二区三区| 国产欧美一区二区精品性色 | 亚洲午夜一区二区| 国内精品国产成人| 欧美性生活影院| 国产日韩高清在线| 日韩电影在线观看电影| 99re在线精品| 国产午夜久久久久| 日韩影院免费视频| 在线观看一区日韩| 国产精品入口麻豆原神|