netaddr.fbsocket

Package netaddr :: Module fbsocket |
[hide private]
[frames] | no frames]

# Module fbsocket

Fallback routines for Python's standard library socket module

Functions | [hide private]
inet_ntoa(packed_ip) Convert an IP address from 32-bit packed binary format to string format. |
inet_aton(ip_string) Convert an IP address in string format (123.45.67.89) to the 32-bit packed binary format used in low-level network functions. |
_compact_ipv6_tokens(tokens) |
inet_ntop(af, packed_ip) Convert an packed IP address of the given family to string format. |
_inet_pton_af_inet(ip_string) Convert an IP address in string format (123.45.67.89) to the 32-bit packed binary format used in low-level network functions. |
inet_pton(af, ip_string) Convert an IP address from string format to a packed string suitable for use with low-level network functions. |

Variables | [hide private]
| AF_INET = `2`
| AF_INET6 = `10`
| __package__ = ``'``netaddr``'``

Function Details | [hide private]

### _inet_pton_af_inet(ip_string) |
Convert an IP address in string format (123.45.67.89) to the 32-bit packed binary format used in low-level network functions. Differs from inet_aton by only support decimal octets. Using octal or hexadecimal values will raise a ValueError exception.