A penetration tester’s guide to sub-domain enumeration
blog.appsecco.com
blog.appsecco.com
DNS records, e.g. zone files, are supposed to be public information.
As such, ICANN requires gTLD registries to provide users with access to them.[FN1]
However, various ccTLDs at various times refused to comply, and most still try to pretend their zone files are private.
Obviously, as the blog post shows, users can still get a large quantity of the data freely from other sources.
Google search results for ccTLD zone files are dominated by individuals who have done so and are selling this data. IMO, this sale of public data is unnecessary, not to mention annoying.
Last year .se and .nu started making their zone files public.
https://www.iis.se/english/press/pressreleases/iis-releases-...
They were also the first to try their hand at DNSSEC. As the blog post shows, DNSSEC makes it easier to get contents of a zone.
FN1. "About Zone File Access
Registry operators must provide to ICANN bulk access to the zone files of the Generic Top Level Domain (gTLD) at least on a daily basis. For gTLDs, a zone file contains information about domain names that are active in that gTLD. In general, Internet users may be able to access and download zone file data at no cost for certain purposes.
This contractual obligation does not apply to any ccTLD (such as .us, .de, or .uk). If you have a complaint about gTLD zone file access, please submit a Zone File Access Complaint Form."
source: https://www.icann.org/resources/pages/zfa-2013-06-28-en
[ec2-user@x cdx-index-client]$ ./cdx-index-client.py -c CC-MAIN-2017-43 '*.ycombinator.com'
2017-11-11 22:50:08,381: [INFO]: Getting Index From http://index.commoncrawl.org/CC-MAIN-2017-43-index
2017-11-11 22:50:08,387: [INFO]: Starting new HTTP connection (1): index.commoncrawl.org
2017-11-11 22:50:08,468: [INFO]: Fetching 2 pages of *.ycombinator.com
2017-11-11 22:50:08,477: [INFO]: Starting new HTTP connection (1): index.commoncrawl.org
2017-11-11 22:50:08,478: [INFO]: Starting new HTTP connection (1): index.commoncrawl.org
2017-11-11 22:50:10,409: [INFO]: 1 page(s) of 2 finished
2017-11-11 22:50:11,711: [INFO]: 2 page(s) of 2 finished
[ec2-user@x cdx-index-client]$ awk -F')' '{print $1}' domain-y* | sort | uniq -c
66 com,ycombinator
38 com,ycombinator,apply
500 com,ycombinator,blog
2 com,ycombinator,fellowship
2 com,ycombinator,macro
24036 com,ycombinator,news
25 com,ycombinator,old
2 com,ycombinator,ycblogAlso you can look at the SSL certificate of a page of the doamin and see if many domains appears inside it.
And currently if the website uses letsencrypt and need wildcard DNS, you may find hundreds of domains. Fortunately Letsencrypt wildcard certificates come in January
You can go ahead and search the logs yourself through google.
I think they are the only ones because RFC 6962 does not actually support redaction.
Symantec say they are only submitting these entries to the deneb.ws.symantec.com CT log, but it is possible to cross-post redacted log entries to other CT logs, which actually is happening and is kind of annoying.
You can see an example of a redaction (for nsw.gov.au) here: https://crt.sh/?id=49265178
I think the best way to protect your privacy currently is to purchase wildcards, though LE will support wildcards next year :) !
Kind of related, I also wrote https://ausdomainledger.net/ a couple of weeks ago that is crawling CT logs and Common Crawl as well to enumerate domains in the .au zone, because the zone file is not accessible for the ccTLD.
Even where a subscriber specifically didn't want their certs logged and the CA doesn't currently log everything if there's ever a problem it'll get logged. This is because both Google and Mozilla will ask to see all the affected certificates, and logging them is the easiest way to satisfy this requirement. If a CA seems to be trying to dodge this usually participants will take whatever form the CA did provide and upload it to the logs. Google's logs don't care who gives them a cert, they can independently determine that it's authentic so they'll log it.
The option left open by the Chrome team was what's called redaction. The logged document would be partly redacted by for example removing host names.
It's not impossible that redaction will happen and end up being accepted, but its biggest proponent was Symantec, who are exiting the business after destroying trust by not exercising proper oversight on their relationship with Korea's CrossCert. And frankly the redaction proposed was getting ludicrous anyway. The trouble is that people who most want this, as with Brass Plate companies, aren't just looking to avoid excess publicity. What they want is to act entirely with impunity. And that's exactly what CT is there to prevent.
If you want external access you can still use your own CA. I think one can assume that an employee (with an employee device) has the CA installed. If this is a public host or you can't control the employee devices, then use a public cert, or live with the error message.
This is not an unsolvable problem.
> This is not an unsolvable problem.
You literally just did not solve it.
What is the problem?
On point 6, find the asn, my own service https://ipinfo.io can help you there. Curl ipinfo.io/ANYIP/org and you'll get the ASN info. Also see ipinfo.io/developers for more options such as geolocation, hostname, hosted domains, and more.
How one would one go about finding A domains pointing to specific AS. The target web app in question allows either using their subdomain or pointing to your own. Any ideas how to find those?
I'm looking forward to wildcard certs, anything that makes it harder for attackers helps...
Mail headers may be similarly informative if you can get one or more email messages out from within the office.
>X509v3 Subject Alternative Name:
>DNS Name:sniXXXXXXX.cloudflaressl.com (X are numbers)
>DNS Name:(lots of domains, including the one I was researching)
>...
Does that mean all those domains belong to the same user/person?
https://arstechnica.com/information-technology/2015/03/ted-c...
Though to be fair, this incident is now fairly infamous inside Cloudflare and these days they have ways to deal with it.