Permalink
Browse files

Merge pull request #6 from sean-lynch/master

Modify profile to detect alternate web hosts running on www.{host}
  • Loading branch information...
2 parents 63b3843 + 2c6fc04 commit 3fcb05ec48e1c6c6be6841f878e895df0627861a @jpf committed May 20, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 lib/domain-profiler/information.rb
@@ -21,8 +21,9 @@ def fetch(host)
data[:version] = version
status "Fetching data for #{host}: DNS "
+ extended_host = "www." + host
dnsopt = '+noadditional +noauthority'
- data[:dns] = `server=#{dns_server}; host=#{host}; dig @$server ns $host #{dnsopt}; dig @$server a $host #{dnsopt}; dig @$server mx $host #{dnsopt}; dig @$server txt $host #{dnsopt}`
+ data[:dns] = `server=#{dns_server}; host=#{host}; dig @$server ns $host #{dnsopt}; dig @$server a $host #{dnsopt}; dig @$server a #{extended_host} #{dnsopt}; dig @$server mx $host #{dnsopt}; dig @$server txt $host #{dnsopt}`
status 'Whois '
data[:whois] = `sleep 2; whois 'domain #{host}'`

0 comments on commit 3fcb05e

Please sign in to comment.