Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[REQUEST] Allow more than 1 dns resolver #10

Open
menzow opened this issue Mar 1, 2018 · 2 comments
Open

[REQUEST] Allow more than 1 dns resolver #10

menzow opened this issue Mar 1, 2018 · 2 comments

Comments

@menzow
Copy link

menzow commented Mar 1, 2018

I love the speed of this tool but I seem to get suprisingly inaccurate results. Could this be caused by rate limiting of the used resolver?

For subbrute (https://github.com/TheRook/subbrute) I use a list of DNS resolvers which works great. Would such a solution also be possible in dnsbrute?
Not familiar enough in go to implement this myself sadly..

@menzow
Copy link
Author

menzow commented Mar 1, 2018

I've been able to confirm that rate limiting indeed seems to be the issue. Using dnsblast it's easy to determine what the rate limits of a dns resolver is.

I've written a easy shell script that tries 10000 queries @ 1000 qps and outputs the stats. This helps checking a list of resolvers and find one with the lowest rate limit. I've shared it below incase it might help someone.

Save the following as scan.sh:

#!/bin/bash
IP=$1

TIMEOUT=3 # Timeout scan (in seconds). Lower for  faster results.
QUERIES=10000 # How many queries to send
QUERY_RATE=1000 # Queries per seconds

STATS=`timeout $TIMEOUT ~/misc/dnsblast/dnsblast $IP $QUERIES $QUERY_RATE 2>&1 | grep -E '^\S' | tail -n 1`

echo "$IP - $STATS"

Usage:

# Scan a single IP
$ ./scan.sh 8.8.8.8

# Check list of resolvers. Lower the amount of threads if you run out of buffer size.
$ cat resolvers.txt | parallel -j 4 './scan.sh {}'

@Q2h1Cg
Copy link
Owner

Q2h1Cg commented Mar 2, 2018

good job.

you can control the transmit rate with the parameter -rate, 10000 default. your ISP's dns server is better usually.

maybe I'll add a func to the program later.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants