o 0¦iÅ; ã @ sˆ d Z dZddlZdZdZG dd„ deƒZG dd „ d eƒZd d„ Zd=d d„Z dd„ Z dd„ Zdd„ Zdd„ Z dd„ Zdd„ Zdd„ Zdd„ Zdd „ Zd!d"„ ZG d#d$„ d$ƒZdaejG d%d&„ d&eƒƒZejG d'd(„ d(eƒƒZG d)d*„ d*ƒZG d+d,„ d,eeƒZG d-d.„ d.eƒZG d/d0„ d0eeƒZG d1d2„ d2ƒZee_G d3d4„ d4ƒZG d5d6„ d6eeƒZ G d7d8„ d8e ƒZ!G d9d:„ d:eeƒZ"G d;d<„ d<ƒZ#e#e _dS )>z•A fast, lightweight IPv4/IPv6 manipulation library in Python. This library is used to create/poke/manipulate IPv4 and IPv6 addresses and networks. z1.0é Né é€ c @ ó e Zd ZdZdS )ÚAddressValueErrorz%A Value Error related to the address.N©Ú__name__Ú __module__Ú__qualname__Ú__doc__© r r ú0/opt/alt/python310/lib64/python3.10/ipaddress.pyr ó r c @ r )ÚNetmaskValueErrorz%A Value Error related to the netmask.Nr r r r r r r r c C óR zt | ƒW S ttfy Y nw zt| ƒW S ttfy! Y nw t| ›d�ƒ‚)a® Take an IP string/int and return an object of the correct type. Args: address: A string or integer, the IP address. Either IPv4 or IPv6 addresses may be supplied; integers less than 2**32 will be considered to be IPv4 by default. Returns: An IPv4Address or IPv6Address object. Raises: ValueError: if the *address* passed isn't either a v4 or a v6 address z. does not appear to be an IPv4 or IPv6 address)ÚIPv4Addressr r ÚIPv6AddressÚ ValueError©Úaddressr r r Ú ip_address s ÿ ÿr Tc C sV zt | |ƒW S ttfy Y nw zt| |ƒW S ttfy# Y nw t| ›d�ƒ‚)aÐ Take an IP string/int and return an object of the correct type. Args: address: A string or integer, the IP network. Either IPv4 or IPv6 networks may be supplied; integers less than 2**32 will be considered to be IPv4 by default. Returns: An IPv4Network or IPv6Network object. Raises: ValueError: if the string passed isn't either a v4 or a v6 address. Or if the network has host bits set. z. does not appear to be an IPv4 or IPv6 network)ÚIPv4Networkr r ÚIPv6Networkr )r Ústrictr r r Ú ip_network9 s ÿÿr c C r )ag Take an IP string/int and return an object of the correct type. Args: address: A string or integer, the IP address. Either IPv4 or IPv6 addresses may be supplied; integers less than 2**32 will be considered to be IPv4 by default. Returns: An IPv4Interface or IPv6Interface object. Raises: ValueError: if the string passed isn't either a v4 or a v6 address. Notes: The IPv?Interface classes describe an Address on a particular Network, so they're basically a combination of both the Address and Network classes. z0 does not appear to be an IPv4 or IPv6 interface)Ú IPv4Interfacer r Ú IPv6Interfacer r r r r Úip_interfaceV s ÿ ÿr c C ó&