IP Calculator for IP RANGE, HEX, BINARY, CIDR
This quick Python script provides a command-line interface for converting IP addresses and ranges between different formats. It supports converting between decimal, hexadecimal, binary, and CIDR notation. The tool also allows for converting CIDR notation to IP ranges and finding the smallest CIDR block that encompasses a given IP range.
- 👉 Checkout some more awesome tools at GetCyber
- 👉 Subscribe to my YouTube Channel GetCyber - YouTube
- 👉 Discord Server GetCyber - Discord
- Convert IP addresses to hexadecimal format.
- Convert IP addresses to binary format.
- Convert binary IP addresses back to decimal format.
- Convert hexadecimal IP addresses back to decimal format.
- Convert CIDR notation to IP range.
- Convert an IP range to the smallest possible CIDR block that covers the entire range.
Run the script in your terminal, and you will be presented with a menu of options:
Menu:
- Convert IP to HEX
- Convert IP to Binary
- Convert Binary to IP
- Convert HEX to IP
- Convert CIDR to IP Range
- Convert IP Range to the smallest CIDR block
- Exit
Enter the number corresponding to the action you want to perform and follow the prompts.
- Python 3
Clone this repository to your local machine:
git clone https://github.com/Dan-Duran/ip-calc.git && cd ip-calc/
python3 ip-calc.py
If you want colored output, install the termcolor library:
- This project is licensed under the MIT License - see the LICENSE file for details. https://opensource.org/license/mit