Reference

Network::Interface(3pm)

a network interface abstraction

NAME

Network::Interface - a network interface abstraction

SYNOPSIS

  my $interface = new Network::Interface(
                                         DEVICE => 'eth0',
                                         IPADDR => '192.168.42.101',
                                         TYPE => 'static',
                                        );

  my $netmask = $interface->netmask;
  my $ip = $interface->ip;
  my $network = $interface->network;

DESCRIPTION

METHODS

The following accessors exist in this module:

ip

returns ip address

ipaddr

returns ip address

netmask

returns subnet mask

network

returns base network address

broadcast

returns broadcast address

device

returns device name

type

returns interface type (dhcp⎪static⎪bootp)

AUTHOR

  Sean Dague
  [email protected]

SEE ALSO

Most of the hard work of this module is done by the Net::Netmask module written by David Muir Sharnoff. The rest is just a mild abstraction layer on top of that.

Network, Net::Netmask, perl