#!/usr/bin/env ruby
# www.railsmine.net
require 'open-uri'
if ARGV.size < 1
puts '[-] Usage: ruby whois.rb [domain_name]'
exit 1
end
puts '-----------------------------------------------'
puts '[+] Whois tool - whois.rb'
puts "-----------------------------------------------\n\n"
begin
domain_name = ARGV[0]
open("http://reports.internic.net/cgi/whois?whois_nic=#{domain_name}&type=domain") {|page|
page.each_line {|line|
if (line =~ /Domain Name:/)
puts "[+]#{line}"
end
if (line =~ /Registrar:/)
puts "[+]#{line}"
end
if (line =~ /Name Server:/)
puts "[+]#{line}"
end
if (line =~ /Whois Server:/)
puts "[+]#{line}"
end
if (line =~ /Referral URL:/)
puts "[+]#{line}"
end
if (line =~ /Status:/)
puts "[+]#{line}"
end
if (line =~ /Updated Date:/)
puts "[+]#{line}"
end
if (line =~ /Creation Date:/)
puts "[+]#{line}"
end
if (line =~ /Expiration Date:/)
puts "[+]#{line}"
end
}
}
rescue OpenURI::HTTPError => error_msg
puts "[-] Oops! Bad status code: #{error_msg}. Please try again."
rescue Timeout::Error
puts '[-] 0ops! Timeout, Check your internet connection.'
end
Railsmine
Sunday, February 19, 2012
Ruby Whois Script - whois.rb
Description: My old script. Client for the whois directory service.
Monday, February 13, 2012
ID-Ruby
ID-Ruby is a community of ruby users in Indonesia to learn together about ruby and to provide a place for ruby developers to meet friends and network. The group meets up at least once a month with talks, demos, hacks and discussions. ID-Ruby Meetup is informal, free, and open to public. Everyone are welcomed to participate.Getting in Touch
Visit http://id-ruby.org for meetup information and join ID-Ruby mailing list [email protected].
Getting Involved
Fork ID-Ruby repository here https://github.com/id-ruby/
Sunday, July 17, 2011
Ruby 2.0: What We Want to Accomplish in the Near Future
Matz, the founder of Ruby, talks about Ruby 2.0 and the future of Ruby.
Subscribe to:
Posts (Atom)