This is a tester for a DNS proxy filter. Used to locally or remotely test DNS proxy filters that use a certain format of configuration file. See disciption at GitHub page.
Project description
The Python package dnstester-qboxxbyh
This is a tester for a DNS proxy filter. It can be used locally or remotely to test DNS proxy filters that rely on a specific configuration file format below:
[server]
listen_address = 127.0.0.1
listen_port = 5300
[upstream]
dns1 = 1.1.1.1
dns2 = 8.8.8.8
dns3 = 8.8.4.4
[blacklist]
yandex.ru = notfind
ya.ru = refuse
tutu.ru = 178.248.234.61
Installation
This package is available on PyPI and can be installed with pip install dnstester-qboxxbyh or updated with pip install --upgrade dnstester-qboxxbyh
How to use
If the DNS proxy filter being tested is a Python script (e.g., mydnsfilter.py):
from dnstester_qboxxbyh import dnsProxyTester
tester = dnsProxyTester(sample_size_input = 200)
tester.run(app_binary = "python3 mydnsfilter.py", sample_size_input = 200,
ignoreUnexpected = False, ignoreTrailing = False,
raiseOnTruncation = False, ignoreErrors = False,
timeOut = None) # None for timeOut means for ever
Or, if the DNS proxy filter being tested is a binary (which may also require its own parameters, such as a configuration file):
from dnstester_qboxxbyh import dnsProxyTester
tester = dnsProxyTester(sample_size_input = 200)
tester.run(app_binary =
"~/dns-proxy-filter-p2B9agE1/dns_proxy_filter_p2B9agE1 ~/.config/p2B9agE1/dns-proxy-p2B9agE1.conf",
sample_size_input = 200, ignoreUnexpected = False, ignoreTrailing = False,
raiseOnTruncation = False, ignoreErrors = False,
timeOut = None) # None for timeOut means for ever
How it works
The software downloads and uses a collection of 4,170,262 verified domains from https://tranco-list.eu/download/VQ92N/full. It makes a random sample without replacement from this pool of domains and randomly splits it into four subsamples. Using three of those subsamples (one for domains not to be found, one for domains to be refused service, and one for domains with randomly pre-specified IPv4 and IPv6 addresses), the software creates a test configuration file and locally launches the tested DNS proxy filter.
The test results
The results are displayed and are dynamically updated in the terminal:
Constraints
This version doesn't yet support:
- Pre-specifying both IPv4 and IPv6 for the same domain in the configuration file
- Testing the handling of non-standard multi-query DNS requests by a DNS proxy filter
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 dnstester_qboxxbyh-0.1.16.tar.gz.
File metadata
- Download URL: dnstester_qboxxbyh-0.1.16.tar.gz
- Upload date:
- Size: 8.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
140ca8bbb647293e85ed9713ce1a4279084aca946c2c891aa516655a22335690
|
|
| MD5 |
c500d3082b8745eaaa7544eb2c9d1902
|
|
| BLAKE2b-256 |
85f33699a8c6bd7844cf22d60538294b41ed99fa19a6c1ef02103a80f01188ee
|
File details
Details for the file dnstester_qboxxbyh-0.1.16-py3-none-any.whl.
File metadata
- Download URL: dnstester_qboxxbyh-0.1.16-py3-none-any.whl
- Upload date:
- Size: 8.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6cde4abdaf6bf724fe344772cd609f3e2dd9943fb4a61204d4f1d83d92ad3149
|
|
| MD5 |
8234d94973c1ac82002ff5ffd13a99c2
|
|
| BLAKE2b-256 |
4185f22ad771730a0a8baaae3ae4bfd568069c43af37002d7dca10350351afca
|