The Lupaxa SRE Toolbox
Part of The Lupaxa Project
lupaxa-dns-blacklist-checker
Check whether an IP address or hostname is listed on DNS blacklists.
Features
- Query a built-in list of DNSBL zones in parallel
- Accept IPv4 addresses, IPv6 addresses, and hostnames
- Check every address a hostname resolves to
- Check every address of each mail exchanger with
--mx - Report the return code and TXT reason for a listing
- Treat Spamhaus and Abusix policy codes as notes, not listings
- Use a Spamhaus Data Query Service key with
--spamhaus-keyorSPAMHAUS_DQS_KEY - Record a zone query failure without treating it as a listing
- Override the zone list and the per-zone timeout
- Install
dns-blacklist-checker, withdnsblas an alias for the same command - Use the
checklibrary API - Depend only on
dnspythonat runtime
Installation
From PyPI
pip install lupaxa-dns-blacklist-checker
From source (development mode)
pip install -e ".[dev]"
Requires Python 3.13+.
Library quick start
from lupaxa.dns_blacklist_checker import check
result = check("203.0.113.9", zones=("zen.spamhaus.org", "bl.spamcop.net"))
for item in result.addresses:
print(item.address, item.listed)
for zone in item.zones:
print(zone.zone, zone.detail, zone.return_codes, zone.reason)
CLI quick start
dns-blacklist-checker --help
dns-blacklist-checker 192.0.2.1 example.com
dns-blacklist-checker 203.0.113.1 --zone zen.spamhaus.org --timeout 5
dnsbl is an alias for dns-blacklist-checker. Both commands accept the same
flags and print the same output.
You can also run the CLI as a module:
python -m lupaxa.dns_blacklist_checker --help
python -m lupaxa.dns_blacklist_checker --version
Options
TARGET: one or more IPv4 addresses, IPv6 addresses, or hostnames--timeout,-t: per-zone DNS timeout in seconds; default5--zone,-z: DNSBL zone to query; repeat to replace the built-in list--mx: check every address of each mail exchanger for a domain--spamhaus-key: Spamhaus Data Query Service key; defaultSPAMHAUS_DQS_KEY--version: print the package version
Documentation
Online documentation:
Source repository:
Serve docs locally
From a clone of the repository:
make mkdocs-serve
Then open the local URL printed by MkDocs in your browser.
Development
Clone the repository and install with Make:
make init # first-time makefile-skills checkout
make python-install-dev # editable install with [dev]
make python-check # lint, type-check, and test
Release files for lupaxa-dns-blacklist-checker 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| lupaxa_dns_blacklist_checker-0.1.1.tar.gz | 11.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| lupaxa_dns_blacklist_checker-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 24.1 kB
Release files / lupaxa_dns_blacklist_checker-0.1.1.tar.gz
| Download URL | lupaxa_dns_blacklist_checker-0.1.1.tar.gz |
|---|---|
| Size | 11.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9cb418f2015777aa375517bbda56f5b8810346765c21048d83a9cf5873eb93d1
|
|
BLAKE2b-256 checksum How to use checksums |
02986af90d15a1b338724d7d1313d25be6b58f03a2a4aa063f26310b8fe471fb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 23, 2026.
Transparency logRelease files / lupaxa_dns_blacklist_checker-0.1.1-py3-none-any.whl
| Download URL | lupaxa_dns_blacklist_checker-0.1.1-py3-none-any.whl |
|---|---|
| Size | 12.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fd953033fa302fe4a5e744bbb33aa27ca405b91d931f1744c09dd1cc8f53107a
|
|
BLAKE2b-256 checksum How to use checksums |
ad372b9a1a60656573644be84f6d030f8dd33b07b096c1057f09bb6b071bc239
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 23, 2026.
Transparency log