Visual fingerprints for network addresses — lossless, bit-accurate identicons for IPv6, IPv4, and MAC addresses.
Project description
Hexicon
Visual fingerprints for network addresses.
A terminal-first tool to turn IPv6, IPv4, and MAC addresses into bit-accurate, lossless, human-readable visual patterns. Visualize structured binary data in the terminal without losing bit order or structure. Or identicons, but for network addresses.
Why?
Network addresses are hard to compare at a glance. Hexicon lets you compare addresses in logs visually, get an intuitive feel for address distribution, and simplify debugging. Or just create pixel art to represent your addresses.
Features
- Supports IPv6, IPv4, and MAC addresses
- Bit-accurate rendering. No hashing, no data loss
- Semantic structure (network/host, OUI/NIC, octets)
- Terminal-friendly block rendering with multiple layouts: grid, split, inline, barcode
- JSON output for programmatic use
- Zero dependencies. Python stdlib only
Installation
pip install hexicon
How it works
Hexicon converts addresses into bit-accurate patterns through a deterministic, lossless pipeline. No hashing.
Addresses are normalised to their canonical form, converted to a bitstream, grouped into scanlines of width bits, paired as adjacent scanlines (top/bottom), and mapped to half-block characters.
Each cell (half a block) represents a single bit.
Usage
CLI
hexicon 2001:db8::1
hexicon --random
hexicon --random --type ipv6 --layout barcode --show-bits --output text
# Read from stdin
echo "::1" | hexicon -
Python API
from hexicon import render_address, addr_to_nibbles
# Render an address to text
print(render_address("2001:db8::1"))
# Get structured data
schema = addr_to_nibbles("2001:db8::1")
print(schema.type) # "ipv6"
print(schema.parts) # [Part(name="net", ...), Part(name="host", ...)]
# JSON output
print(render_address("::1", output="json"))
Options
| Flag | Values | Default | Description |
|---|---|---|---|
--type |
auto, ipv6, ipv4, mac |
auto |
Address type |
--layout |
auto, grid, split, inline, barcode |
auto |
Layout mode |
--width |
N or auto |
auto |
Bits per scanline row |
--scale |
N |
1 |
Vertical scaling factor |
--invert |
flag | — | Invert filled/empty pixels |
--output |
text, json |
text |
Output format |
--random |
flag | — | Generate a random address |
--show-bits |
flag | — | Debug: print bit values |
--no-newline |
flag | — | Suppress trailing newline |
Layouts
Split
Default view. Semantic separation of address parts. For IPv6: network │ host. For MAC: OUI │ NIC.
Grid
Vertical stacked version of split view.
Inline
Single 1-height continuous strip. Good for logs or embedding.
Barcode
Compact 2-height view.
JSON Output
Returns a JSON object with the following fields:
{
"type": "ipv6",
"address": "2001:db8::1",
"parts": [
{
"name": "net",
"rows": ["▀ ▀▄", "..."],
"bit_range": [0, 64],
"label": "network"
}
]
}
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file hexicon-0.1.0.tar.gz.
File metadata
- Download URL: hexicon-0.1.0.tar.gz
- Upload date:
- Size: 9.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9c68f351644f75c9c01563bd897c9955a50db6e3c07c3ed88faea2e51a6a3b0f
|
|
| MD5 |
47ac123962c6ee73070167c6dcc46ac5
|
|
| BLAKE2b-256 |
ef6ce812b2aa2b73628e0c02ded6f4d64349b92a584adbce91de7474438e0e60
|
File details
Details for the file hexicon-0.1.0-py3-none-any.whl.
File metadata
- Download URL: hexicon-0.1.0-py3-none-any.whl
- Upload date:
- Size: 8.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d754a3e79d66e7bdf138dc776282c0cbc55fdfc0f36612e2ab637331eae30f26
|
|
| MD5 |
9666887a25828604ced8254e94f5de7a
|
|
| BLAKE2b-256 |
8d89735faeb536ec672068011e01c7109066df7e390703b77605a2278d9217ab
|