Skip to main content

About

This module allows you to perform IP subnet calculations, there is support for both IPv4 and IPv6 CIDR notation.

Example Usage

>>> import ipcalc
>>> for x in ipcalc.Network('172.16.42.0/30'):
...     print str(x)
...
172.16.42.1
172.16.42.2
>>> subnet = ipcalc.Network('2001:beef:babe::/48')
>>> print str(subnet.network())
2001:beef:babe:0000:0000:0000:0000:0000
>>> print str(subnet.netmask())
ffff:ffff:ffff:0000:0000:0000:0000:0000
>>> '192.168.42.23' in Network('192.168.42.0/24')
True
>>> long(IP('fe80::213:ceff:fee8:c937'))
338288524927261089654168587652869703991L

Bugs/Features

You can issue a ticket in GitHub: https://github.com/tehmaze/ipcalc/issues

Documentation

Documentation is available from http://ipcalc.rtfd.org/

Release files for ipcalc 1.99.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ipcalc 1.99.0
File Size Uploaded
ipcalc-1.99.0.tar.gz 9.8 kB Details

Release files / ipcalc-1.99.0.tar.gz

Download URL ipcalc-1.99.0.tar.gz
Size 9.8 kB
Tags Source
SHA-256 checksum
How to use checksums
17b9d85859ef70e1996426a723d3891f6b99dd0e283986ea92c37a06601725d9
BLAKE2b-256 checksum
How to use checksums
8f14bb4034c87b4b2a47b381a52051138c3aeb87515a498185e275d40585deeb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

1.99.0 This release

1 release file

1.1.3

1 release file

1.1.2

1 release file

1.1.1

1 release file

1.1.0

1 release file

1.0.0

1 release file

0.6

1 release file

0.5.2

1 release file

0.5.1

1 release file

0.5

1 release file

0.4.1

1 release file

0.4

1 release file

0.3

1 release file

0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page