Skip to content

Commit

Permalink
code optimized: reconstruct and new featurs
Browse files Browse the repository at this point in the history
  • Loading branch information
lijiejie committed Dec 21, 2015
1 parent f54d201 commit b3071df
Show file tree
Hide file tree
Showing 11 changed files with 15,525 additions and 51,659 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
*.py[cod]
.idea/*
26 changes: 18 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,41 @@
# subDomainsBrute

A simple and fast sub domain brute tool for pentesters
A simple and fast sub domain brute tool for pentesters.

这个脚本的主要目标是发现其他工具无法探测到的域名. 比如大家常用的Google,aizhan,fofa。

##Change Log
* 字典统一到dict文件夹下
* 精简二级域名字典,丰富三四域名字典
* 增加-i参数,忽略指向内网IP域名
* 默认由10线程调整为30线程,但增加了超时重试

##Dependencies
First you need install [dnspython](http://www.dnspython.org/kits/1.12.0/) to do DNS query
First you need to install [dnspython](http://www.dnspython.org/kits/1.12.0/) to do DNS query
> pip install dnspython
## Improvements
* 用小字典递归地发现三级域名,四级域名、五级域名等不容易被探测到的域名
* 字典较为全面,小字典就包括3万多条,大字典多达8万条
* 默认使用114DNS、百度DNS、阿里DNS这几个快速又可靠的公共DNS进行查询,可随时修改配置文件添加你认为可靠的DNS服务器
* 自动筛选泛解析的域名,当前规则是: 超过10个域名指向同一IP,则此后发现的其他指向该IP的域名将被丢弃
* 整体速度还过得去,在我的PC上,每秒稳定扫描100到200个域名(10个线程
* 字典较为丰富,小字典就包括1万5千条,大字典多达6万3千条
* 默认使用114DNS、百度DNS、阿里DNS这几个快速又可靠的Public DNS查询,可修改配置文件添加DNS服务器
* 自动去重泛解析的域名,当前规则: 超过2个域名指向同一IP,则此后发现的其他指向该IP的域名将被丢弃
* 速度尚可,在我的PC上,每秒稳定扫描几百个域名(30个线程

##Usage
```
Usage: subDomainsBrute.py [options] target
Usage: subDomainsBrute.py [options] target.com
Options:
-h, --help show this help message and exit
-t THREADS_NUM, --threads=THREADS_NUM
Number of threads. default = 10
Number of threads. default = 30
-f NAMES_FILE, --file=NAMES_FILE
Dict file used to brute sub names
-i, --ignore-intranet
Ignore domains pointed to private IPs.
-o OUTPUT, --output=OUTPUT
Output file name. default is {target}.txt
```

Output file could be like: [http://www.lijiejie.com/wp-content/uploads/2015/04/baidu.com_.txt](http://www.lijiejie.com/wp-content/uploads/2015/04/baidu.com_.txt)
Expand Down
File renamed without changes.
57 changes: 53 additions & 4 deletions next_sub.txt → dict/next_sub.txt
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,10 @@ sms
zip
monitor
proxy
proxy1
proxy2
update
upgrade
stat
stats
data
portal
blog
Expand All @@ -98,7 +97,6 @@ git
log
staff
vpn
ssl-vpn
sslvpn
ssh
scanner
Expand All @@ -110,4 +108,55 @@ demo
console
cms
auth
crm
crm
erp
res
static
old
new
beta
image
service
login
3g
docs
it
e
live
library
files
i
d
cp
connect
gateway
lib
preview
backup
share
status
assets
user
vote
bugs
cas
feedback
id
edm
survey
union
ceshi
dev1
updates
phpmyadmin
pma
edit
master
xml
control
profile
zhidao
tool
toolbox
boss
activity
Loading

0 comments on commit b3071df

Please sign in to comment.