diff --git a/Dockerfile b/Dockerfile index 6a61394..250993e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -132,6 +132,9 @@ RUN /root/go/bin/nuclei -update-templates # To allow run crlfuzz inside the docker RUN GO111MODULE=on /usr/local/go/bin/go get -v github.com/dwisiswant0/crlfuzz/cmd/crlfuzz +# To allow run puredns inside the docker +RUN GO111MODULE=on /usr/local/go/bin/go get github.com/d3mondev/puredns/v2 + # -------- End Agents dependencies -------- ENTRYPOINT ["dotnet", "ReconNess.Web.dll"] diff --git a/Puredns/Script b/Puredns/Script new file mode 100644 index 0000000..992e126 --- /dev/null +++ b/Puredns/Script @@ -0,0 +1,9 @@ +using ReconNess.Core.Models; + +var match = System.Text.RegularExpressions.Regex.Match(lineInput, @"([^\.\/]+)(\.[^\.\/]+)+(?:\/|$)"); +if (match.Success) +{ + return new ScriptOutput { Subdomain = match.Groups[0].Value }; +} + +return new ScriptOutput(); diff --git a/Puredns/readme.md b/Puredns/readme.md new file mode 100644 index 0000000..6edb857 --- /dev/null +++ b/Puredns/readme.md @@ -0,0 +1,36 @@ +## Puredns command + +Using {{rootDomain}} ReconNess replace {{rootDomain}} to the root domain, for example, yahoo.com if we define that as a root domain adding the Target + +If we have massdns in the folder /app/massdns/bin/massdns + +``` +puredns bruteforce subdomains.txt {{rootDomain}} --resolvers resolvers.txt --bin /app/massdns/bin/massdns -q +``` + +## Puredns Command for Docker + +``` +/root/go/bin/puredns bruteforce /app/Content/wordlists/subdomain_enum/default.txt {{rootDomain}} --resolvers /app/Content/wordlists/dns_resolver_enum/default.txt --bin /app/massdns/bin/massdns -q + +``` + +## Puredns Script + +Check [Script file](https://github.com/reconness/reconness-agents/blob/master/Puredns/Script) + +## Puredns Dockerfile Entry + +# -------- Agents dependencies -------- + +``` +# To allow run Puredns inside the docker + +RUN apt-get update && apt-get install -y git build-essential wget +RUN wget https://dl.google.com/go/go1.14.6.linux-amd64.tar.gz +RUN tar -C /usr/local -xzf go1.14.6.linux-amd64.tar.gz +RUN git clone https://github.com/blechschmidt/massdns.git && cd massdns && make +RUN GO111MODULE=on /usr/local/go/bin/go get github.com/d3mondev/puredns/v2 +``` + +# -------- End Agents dependencies -------- diff --git a/README.md b/README.md index d1e50dd..1f05625 100644 --- a/README.md +++ b/README.md @@ -17,6 +17,7 @@ These are the list of Agents tested inside the Docker - [Knockpy](https://github.com/reconness/reconness-agents/tree/master/Knockpy) - [Massdns](https://github.com/reconness/reconness-agents/tree/master/Massdns) - [Shuffledns](https://github.com/reconness/reconness-agents/tree/master/Shuffledns) +- [Puredns](https://github.com/reconness/reconness-agents/tree/master/Puredns) ### Agents Dir Discovery diff --git a/default-agents1.5.json b/default-agents1.5.json index 61be2fc..828b63a 100644 --- a/default-agents1.5.json +++ b/default-agents1.5.json @@ -191,6 +191,14 @@ "isBySubdomain": "true", "scriptUrl": "https://raw.githubusercontent.com/reconness/reconness-agents/master/CRLFuzz/Script", "repository": "https://github.com/dwisiswant0/crlfuzz" - } + }, + { + "name": "Puredns", + "category": "Agents Subdomain Enum", + "command": "/root/go/bin/puredns bruteforce /app/Content/wordlists/subdomain_enum/default.txt {{rootDomain}} --resolvers /app/Content/wordlists/dns_resolver_enum/default.txt --bin /app/massdns/bin/massdns -q", + "isByRootDomain": "true", + "scriptUrl": "https://raw.githubusercontent.com/reconness/reconness-agents/master/Puredns/Script", + "repository": "https://github.com/d3mondev/puredns" + } ] }