mac-vendors-client
Lightweight, offline MAC address -> vendor lookups against a pre-built SQLite database export.
- Zero dependencies - reads the export via the standard library
sqlite3. - Fast - range/bits index lookup, no network, no per-call cost.
- Read-only - opens the export file read-only; never modifies it.
Use it when you have a downloaded SQLite export and want fast, local lookups
with no network calls. For live queries against the hosted API, use the online
SDK (mac-vendors-sdk) instead.
Install
pip install mac-vendors-client
Usage
from mac_vendors_client import MacVendorsClient
with MacVendorsClient("vendors.db") as client:
match = client.lookup("00:50:56:AA:BB:CC")
if match:
print(match.organization_name) # "VMware, Inc."
print(match.assignment, match.bits)
# Name only
name = client.lookup_name("00-50-56-aa-bb-cc")
# Batch (invalid entries map to None instead of raising)
results = client.lookup_batch(["0050.56AA.BBCC", "FF:FF:FF:00:00:00"])
# Export metadata
info = client.info()
print(info.exported_at, info.total_records)
MAC input accepts any common format (:/-/. separators or bare hex), and
a shorter prefix such as a 6-hex OUI. The most specific (largest-bits) match
wins when prefixes overlap (e.g. an MA-S assignment inside an MA-L block).
The export contract
The export is a SQLite database with this schema:
CREATE TABLE mac_addresses (
id INTEGER PRIMARY KEY,
assignment TEXT NOT NULL,
organization_name TEXT,
organization_address TEXT,
range_begin INTEGER NOT NULL, -- 48-bit MAC range start
range_end INTEGER NOT NULL, -- 48-bit MAC range end
bits INTEGER NOT NULL -- 24 / 28 / 36
);
CREATE TABLE metadata (key TEXT PRIMARY KEY, value TEXT); -- updated_at, exported_at, total_records
A lookup resolves a MAC M to the row where
range_begin <= int(M) <= range_end, ordered by bits DESC (most specific
first).
License
MIT
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 mac_vendors_client-1.0.0.tar.gz.
File metadata
- Download URL: mac_vendors_client-1.0.0.tar.gz
- Upload date:
- Size: 8.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4e351a293f879b6c0612669f883ae3939db04636fd221c1712a51c1061103838
|
|
| MD5 |
d7698c79a832fd4b5c9e32d4ffee20d6
|
|
| BLAKE2b-256 |
ad5b83f9a0d15a2bf162affcec37d8c1154d077080ec0187332d79bb7a819bc0
|
Provenance
The following attestation bundles were made for mac_vendors_client-1.0.0.tar.gz:
Publisher:
publish.yml on mac-vendors/mac-vendors-client
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mac_vendors_client-1.0.0.tar.gz -
Subject digest:
4e351a293f879b6c0612669f883ae3939db04636fd221c1712a51c1061103838 - Sigstore transparency entry: 2226553248
- Sigstore integration time:
-
Permalink:
mac-vendors/mac-vendors-client@4b2d570513c6f36df632c1b0de573f5ecc9a2fef -
Branch / Tag:
refs/tags/v1.0.0 - Owner: https://github.com/mac-vendors
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@4b2d570513c6f36df632c1b0de573f5ecc9a2fef -
Trigger Event:
release
-
Statement type:
File details
Details for the file mac_vendors_client-1.0.0-py3-none-any.whl.
File metadata
- Download URL: mac_vendors_client-1.0.0-py3-none-any.whl
- Upload date:
- Size: 6.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/6.1.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
92c33c4727dd1ef299e57e566249069be09f1763f4124a784351f9dcb0c06022
|
|
| MD5 |
6c5b66f21d9ff87356789db3197e91ff
|
|
| BLAKE2b-256 |
44182c818ed78e14e7ddf44c3d97dd45872e7f4aa047c9fb559dd16e478d5673
|
Provenance
The following attestation bundles were made for mac_vendors_client-1.0.0-py3-none-any.whl:
Publisher:
publish.yml on mac-vendors/mac-vendors-client
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
mac_vendors_client-1.0.0-py3-none-any.whl -
Subject digest:
92c33c4727dd1ef299e57e566249069be09f1763f4124a784351f9dcb0c06022 - Sigstore transparency entry: 2226553320
- Sigstore integration time:
-
Permalink:
mac-vendors/mac-vendors-client@4b2d570513c6f36df632c1b0de573f5ecc9a2fef -
Branch / Tag:
refs/tags/v1.0.0 - Owner: https://github.com/mac-vendors
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@4b2d570513c6f36df632c1b0de573f5ecc9a2fef -
Trigger Event:
release
-
Statement type: