diff --git a/Dockerfile b/Dockerfile index 2ed89311..ccdf0df5 100644 --- a/Dockerfile +++ b/Dockerfile @@ -53,6 +53,7 @@ RUN python manage.py collectstatic --no-input --clear RUN chmod +x /app/tools/get_subdomain.sh RUN chmod +x /app/tools/get_dirs.sh RUN chmod +x /app/tools/get_urls.sh +RUN chmod +x /app/tools/takeover.sh # run entrypoint.sh ENTRYPOINT ["/app/docker-entrypoint.sh"] diff --git a/startScan/views.py b/startScan/views.py index 30fcd75a..e1e2f4f0 100644 --- a/startScan/views.py +++ b/startScan/views.py @@ -185,6 +185,16 @@ def doScan(host_id, domain): sub_domain.technology_stack = tech_string sub_domain.save() + ''' + Subdomain takeover is not provided by default, check for conditions + ''' + if(task.scan_type.subdomain_takeover): + update_last_activity() + create_scan_activity(task, "Subdomain takeover", 1) + os.system('/app/tools/takeover.sh %s' %(current_scan_dir)) + + + ''' Directory search is not provided by default, check for conditions ''' diff --git a/tools/subjack_fingerprint.json b/tools/subjack_fingerprint.json new file mode 100644 index 00000000..043c89d5 --- /dev/null +++ b/tools/subjack_fingerprint.json @@ -0,0 +1,368 @@ +[ + { + "service": "fastly", + "cname": [ + "fastly" + ], + "fingerprint": [ + "Fastly error: unknown domain" + ], + "nxdomain": false + }, + { + "service": "github", + "cname": [ + "github.io" + ], + "fingerprint": [ + "There isn't a GitHub Pages site here." + ], + "nxdomain": false + }, + { + "service": "heroku", + "cname": [ + "herokuapp" + ], + "fingerprint": [ + "herokucdn.com/error-pages/no-such-app.html" + ], + "nxdomain": false + }, + { + "service": "pantheon", + "cname": [ + "pantheonsite.io" + ], + "fingerprint": [ + "The gods are wise, but do not know of the site which you seek." + ], + "nxdomain": false + }, + { + "service": "tumblr", + "cname": [ + "domains.tumblr.com" + ], + "fingerprint": [ + "Whatever you were looking for doesn't currently exist at this address." + ], + "nxdomain": false + }, + { + "service": "wordpress", + "cname": [ + "wordpress.com" + ], + "fingerprint": [ + "Do you want to register" + ], + "nxdomain": false + }, + { + "service": "teamwork", + "cname": [ + "teamwork.com" + ], + "fingerprint": [ + "Oops - We didn't find your site." + ], + "nxdomain": false + }, + { + "service": "helpjuice", + "cname": [ + "helpjuice.com" + ], + "fingerprint": [ + "We could not find what you're looking for." + ], + "nxdomain": false + }, + { + "service": "helpscout", + "cname": [ + "helpscoutdocs.com" + ], + "fingerprint": [ + "No settings were found for this company:" + ], + "nxdomain": false + }, + { + "service": "s3 bucket", + "cname": [ + "amazonaws" + ], + "fingerprint": [ + "The specified bucket does not exist" + ], + "nxdomain": false + }, + { + "service": "ghost", + "cname": [ + "ghost.io" + ], + "fingerprint": [ + "The thing you were looking for is no longer here, or never was" + ], + "nxdomain": false + }, + { + "service": "feedpress", + "cname": [ + "redirect.feedpress.me" + ], + "fingerprint": [ + "The feed has not been found." + ], + "nxdomain": false + }, + { + "service": "shopify", + "cname": [ + "myshopify.com" + ], + "fingerprint": [ + "Sorry, this shop is currently unavailable." + ], + "nxdomain": false + }, + { + "service": "statuspage", + "cname": [ + "statuspage.io" + ], + "fingerprint": [ + "You are being redirected" + ], + "nxdomain": false + }, + { + "service": "uservoice", + "cname": [ + "uservoice.com" + ], + "fingerprint": [ + "This UserVoice subdomain is currently available!" + ], + "nxdomain": false + }, + { + "service": "surge", + "cname": [ + "surge.sh" + ], + "fingerprint": [ + "project not found" + ], + "nxdomain": false + }, + { + "service": "bitbucket", + "cname": [ + "bitbucket.io" + ], + "fingerprint": [ + "Repository not found" + ], + "nxdomain": false + }, + { + "service": "intercom", + "cname": [ + "custom.intercom.help" + ], + "fingerprint": [ + "This page is reserved for artistic dogs.", + "

" + ], + "nxdomain": false + }, + { + "service": "webflow", + "cname": [ + "proxy.webflow.com", + "proxy-ssl.webflow.com" + ], + "fingerprint": [ + "

The page you are looking for doesn't exist or has been moved.

" + ], + "nxdomain": false + }, + { + "service": "wishpond", + "cname": [ + "wishpond.com" + ], + "fingerprint": [ + "https://www.wishpond.com/404?campaign=true" + ], + "nxdomain": false + }, + { + "service": "aftership", + "cname": [ + "aftership.com" + ], + "fingerprint": [ + "Oops.

The page you're looking for doesn't exist." + ], + "nxdomain": false + }, + { + "service": "aha", + "cname": [ + "ideas.aha.io" + ], + "fingerprint": [ + "There is no portal here ... sending you back to Aha!" + ], + "nxdomain": false + }, + { + "service": "tictail", + "cname": [ + "domains.tictail.com" + ], + "fingerprint": [ + "to target URL: Error Code: 404

" + ], + "nxdomain": false + }, + { + "service": "bigcartel", + "cname": [ + "bigcartel.com" + ], + "fingerprint": [ + "

Oops! We could’t find that page.

" + ], + "nxdomain": false + }, + { + "service": "campaignmonitor", + "cname": [ + "createsend.com" + ], + "fingerprint": [ + "Double check the URL or