dnspython  1.16.0
About: dnspython is a DNS toolkit (for Python 2.x) that supports almost all record types.
  Fossies Dox: dnspython-1.16.0.tar.gz  ("inofficial" and yet experimental doxygen-generated source code documentation)  

dns.ipv6 Namespace Reference

Functions

def inet_ntoa (address)
 
def inet_aton (text)
 
def is_mapped (address)
 

Variables

 _leading_zero = re.compile(r'0+([0-9a-f]+)')
 
 _v4_ending = re.compile(br'(.*):(\d+\.\d+\.\d+\.\d+)$')
 
 _colon_colon_start = re.compile(br'::.*')
 
 _colon_colon_end = re.compile(br'.*::$')
 
string _mapped_prefix = b'\x00' * 10 + b'\xff\xff'
 

Function Documentation

◆ inet_aton()

def dns.ipv6.inet_aton (   text)
Convert an IPv6 address in text form to binary form.

*text*, a ``text``, the IPv6 address in textual form.

Returns a ``binary``.

Definition at line 100 of file ipv6.py.

References dns.ipv4.inet_aton(), and dns._compat.xrange.

Referenced by dns.resolver._getaddrinfo(), dns.resolver._gethostbyaddr(), dns.inet.af_for_address(), dns.reversename.from_address(), dns.inet.inet_pton(), dns.inet.is_multicast(), and dns.reversename.to_address().

◆ inet_ntoa()

def dns.ipv6.inet_ntoa (   address)
Convert an IPv6 address in binary form to text form.

*address*, a ``binary``, the IPv6 address in binary form.

Raises ``ValueError`` if the address isn't 16 bytes long.
Returns a ``text``.

Definition at line 29 of file ipv6.py.

References dns.ipv4.inet_ntoa(), dns._compat.maybe_decode(), and dns._compat.xrange.

Referenced by dns.inet.inet_ntop(), and dns.reversename.to_address().

◆ is_mapped()

def dns.ipv6.is_mapped (   address)
Is the specified address a mapped IPv4 address?

*address*, a ``binary`` is an IPv6 address in binary form.

Returns a ``bool``.

Definition at line 173 of file ipv6.py.

Referenced by dns.reversename.from_address().

Variable Documentation

◆ _colon_colon_end

dns.ipv6._colon_colon_end = re.compile(br'.*::$')
private

Definition at line 98 of file ipv6.py.

◆ _colon_colon_start

dns.ipv6._colon_colon_start = re.compile(br'::.*')
private

Definition at line 97 of file ipv6.py.

◆ _leading_zero

dns.ipv6._leading_zero = re.compile(r'0+([0-9a-f]+)')
private

Definition at line 27 of file ipv6.py.

◆ _mapped_prefix

string dns.ipv6._mapped_prefix = b'\x00' * 10 + b'\xff\xff'
private

Definition at line 171 of file ipv6.py.

◆ _v4_ending

dns.ipv6._v4_ending = re.compile(br'(.*):(\d+\.\d+\.\d+\.\d+)$')
private

Definition at line 96 of file ipv6.py.