gopinath6 / sub.sh

Online Subdomain Detect Script

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

πŸŽ―πŸ•ΈπŸ“˜ Online Subdomain Detect Script CMD

✨ πŸ”ΊSub.sh but without API key πŸ”»

‼️ jq and httprobe required πŸ“Œ

Linux Install (Debian,Kali Linux,Ubuntu)

sudo apt-get install jq

MAC OSX Install

brew install jq

πŸ“˜ βœ…Used Services

USAGE πŸ’‘

Script Usage 🎯

bash sub.sh webscantest.com
./sub.sh webscantest.com

image

Curl Usage 🎯

curl -sL https://raw.githubusercontent.com/cihanmehmet/sub.sh/master/sub.sh | bash -s webscantest.com

πŸ”– Curl shortened link usage

curl -sL https://git.io/JesKK | bash -s tesla.com

image


πŸ§±πŸ”¨ Multiprocessing(Parallel) Subdomain Detect

‼️ jq , httprobe and parallel required πŸ“Œ

Debian Install apt install parallel

Mac OSX Install brew install parallel

bash parallel_sub.sh bing.com
curl -sL https://git.io/Jebz5|bash -s bing.com

Subdomain Alive Check 🎯

bash sub_alive.sh bing.com
curl -sL https://raw.githubusercontent.com/cihanmehmet/sub.sh/master/sub_alive.sh | bash -s bing.com

‼️ fping required

image


πŸ”“ Nmap -sn (No port scan) scan live IP detection script

fping -f ip.txt

Usage bash nmap_sn.sh ip.txt

ping

#!/bin/bash

nmap -sn -iL $1 |grep "Nmap scan report for"|grep -Eo "(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)"|sort -u |tee $1.txt

echo "Detect IP $(wc -l $1.txt|awk '{ print $1 }' )" "=> result_${1}" "saved"
echo "File Location : "$(pwd)/"result_$1"

πŸ”‘ Other Resources for subdomain Detection

πŸ“œ DNSGEN Generates combination of domain names from the provided input. :cyclone: dnsgen

DNSGEN install

pip install dnsgen

πŸ”– Sample usage

Usage 1(fping)fping 🎯

cat domains.txt | dnsgen - |fping|grep "alive"|cut -d " " -f1>resolvers.txt

Usage 2(httprobe ) 🎯

Kali Linux httprobe Install πŸ”‘

wget https://github.com/tomnomnom/httprobe/releases/download/v0.1.2/httprobe-linux-amd64-0.1.2.tgz

bash tar -xvzf httprobe-linux-amd64-0.1.2.tgz

cp httprobe /usr/local/bin

chmod +x /usr/local/bin/httprobe


Tool Usage

cat domains.txt | dnsgen - |httprobe|cut -d "/" -f3|sort -u |tee resolvers.txt
dnsgen domain.txt -w subdomains-10000.txt|httprobe|cut -d "/" -f3|sort -u |tee dnsgen.txt
pip3 install ludicrousdns 
cat domain.txt|ludicrousdns resolve |cut -d " " -f1

resolver


πŸ”‘ πŸ“œ Subdomain Detect Terminal Shortcut Function

nano ~/.zshrc

or

nano ~/.bashrc

function subdomain() { curl -sL https://git.io/JesKK | bash -s $1 }

πŸ’‘ Usage

subdomain webscantest.com

subdomain


🧡 Docker Usage


🚩 πŸ’» I am open to suggestions for improvement.



CMD

Cihan Mehmet DOĞAN


🚩 πŸ’» I am open to suggestions for improvement.

About

Online Subdomain Detect Script


Languages

Language:Shell 100.0%