Showing posts with label ip. Show all posts
Showing posts with label ip. Show all posts

Sunday, September 11, 2011

Finding domains on targeted host | Reverse IP lookup



" Reverse IP Lookup " is a very  useful concept for the penetration testers to find out domains which are hosted in targeted host  . Using this concept you can find out the number of domains hosted on a server lets say s4ur4v.com is a server with a server address 1.1.1.1 now when you do a reverse IP lookup on that server you will find the other domains hosted on the same server.

Whats the theory behind this  ?
All web servers are assigned with a unique IP address . If a web server is running a website the IP a address of the site will be same as that of the server. Now if there are multiple domains hosted on the same web server  they will be also having the same IP address of the server . By using this concept " Reverse IP Lookup " we instruct the lookup process to look the number of domains on the target server/host 

How to do a Reverse IP Lookup ? 

Their are a lots of ready made sites which offer you to do a reverse IP look up like yougetsignal

-Go to http://www.yougetsignal.com/
-Gype the server address / website URL
-Click on check and bingo you get the number of domains on the server you looked up


Next i will show you how to do this with a python script which will be using Bing's API to find our dinner ( You can use also DRIL which uses the same )
  1. import httplib, urllib, socket, sys
  2. from xml.dom.minidom import parse, parseString
  3. if len(sys.argv) == 2:
  4.  AppId = '1734E2C92CA63FAA596335295B09CF1D0B5C6161'
  5.  domain = sys.argv[1]
  6.  sites = [domain]
  7.  ip = socket.gethostbyname(domain)
  8.  offset = 50
  9.  while offset < 300:
  10.   uri = "/xml.aspx?AppId=%s&Query=ip:%s&Sources=Web&Version=2.0&Market=en-us&Adult=Moderate&Options=EnableHighlighting&Web.Count=50&Web.Offset=%s&Web.Options=DisableQueryAlterations"%(AppId, ip, offset)
  11.   conn = httplib.HTTPConnection("api.bing.net")
  12.   conn.request("GET", uri)
  13.   res = conn.getresponse()
  14.   data = res.read()
  15.   conn.close()
  16.   xmldoc = parseString(data)
  17.   nameEls = xmldoc.getElementsByTagName('web:DisplayUrl')
  18.   for el in nameEls:
  19.    temp = el.childNodes[0].nodeValue
  20.    temp = temp.split("/")[0]
  21.    if temp.find('www.') == -1:
  22.     if temp not in sites:
  23.      sites.append(temp)
  24.   offset += 50
  25.  print "\n\n"
  26.  print "Total: %d domain(s)\n\n"%len(sites)
  27.  for i in sites:
  28.   print i
  29.  print "\n\n"
  30. else:
  31.  print "\n\n\n"
  32.  print "=====================================\n"
  33.  print "Usage: $ python reverse.py domain.com\n"
  34.  print "Ex: $ python reverse.py hackersbay.in   \n"
  35.  print "=====================================\n"
  36.  print "\n\n\n"

Windows users please mind it you have python installed in your OS before running this script.I am going to show it using Backtrack 

- Copy the above script and paste it in a file rename it to reverse.py
- Browse through the directory you saved the file in e.g cd /dir 
- to execute the script you have to just write python reverse.py and then it will show you the how to do the rest :D 

root@bt:~# cd /pentest 

root@bt:/pentest# python reverse.py 

=====================================
Usage: $ python reverse.py domain.com

Ex: $ python reverse.py enhack.net   
=====================================
root@bt:/pentest# python reverse.py davunit8.org

Total: 103 domain(s)

davunit8.org
psplindia.com
jnvkeonjhar.com
microfinanceltd.com
puspitamishra.com
htti-cuttack.com
neemworld.com
keonjhar.net
origininfosystem.com
cippl.com
newditech.com
caravanholidaysindia.com
niateducation.com
sunrayadv.com
spanscaffold.com
suinsys.com
ihmbbs.org
mohindratourist.com
hiem-bdk.org
immunologyofdiabetessociety.com
pipilicrafts.com
dhaneswarinstitutekatak.com
indomer.com
itibalasore.org... continues 

I missed something ? feel free to comment 

Wednesday, May 25, 2011

World IPv6 Day

World IPv6 Day is an event sponsored and organized by the Internet Society and several large content providers to test public IPv6 deployment. It will start 00:00 UTC on June 8, 2011 and end 23:59 the same day.Web giants Facebook, Yahoo, and Google, with a combined one billion visitors per day, are participating by enabling IPv6 for their main services that day. Content distributors Limelight and Akamai are also joining the party by enabling their customers to participate. But unlike during the IETF IPv6 experiment, IPv4 won't be turned off.

Yahoo, Google, and Facebook have each been working on IPv6 for some time, but have been avoiding  to simply flip the IPv6 switch and add an IPv6 address to their DNS records so everyone can reach them over IPv6. They fear becoming unreachable to users with broken IPv6 connectivity. Google did measurements in this area in 2008, which showed that at that time, 0.09 percent of their users would have to suffer delays as their computers try to connect over IPv6, and eventually fail and retry over IPv4.

So Google created the Google over IPv6 program, where network operators have to promise the search giant that they have good IPv6. In turn, Google will respond to DNS requests from those networks with IPv6 addresses for various Google properties such as google.com and youtube.com. The hoi polloi have to make do with just IPv4 or type ipv6.google.com. (Only works if you have IPv6.) Facebook has www.v6.facebook.com—with address 2620:0:1cfe:face:b00c::3 

-HOW TO TAKE PART

Interested in joining the other organizations that are taking part in this initiative? Select your type of organization below and you’ll find everything you need to participate in World IPv6 Day:



http://isoc.org/wp/worldipv6day/

-Test Your Connectivity 

http://test-ipv6.com/

Thank You 

Friday, April 15, 2011

Asia runs out of IPv4 addresses

The Asia Pacific Network Information Centre (APNIC) has run out of all but a handful of IPv4 addresses that it is holding in reserve for start-up network operators.
APNIC is the first of the Internet's five regional Internet registries to deplete its free pool of IPv4 address space.
APNIC's news is another sign that CIOs and other IT executives need to begin migrating to IPv6, the long-anticipated upgrade to the Internet's main communications protocol known as IPv4.

"For anybody who hasn't figured out that it's time to do IPv6, this is another wake-up call for them," says Owen DeLong, an IPv6 evangelist at Hurricane Electric and a member of the advisory council of the American Registry for Internet Numbers (ARIN), the North American counterpart to APNIC.
Any CIO who isn't planning for IPv6 is "driving toward a brick wall and closing your eyes and hoping that it's going to disappear before you get there," DeLong says. Ignoring IPv6 "is not the best strategy."
Most IPv4 address space is expected to be handed out by the regional Internet registries by the end of 2011.
IPv4 uses 32-bit addresses and can support 4.3 billion devices connected directly to the Internet. IPv6, on the other hand, uses 128-bit addresses and supports a virtually unlimited number of devices -- 2 to the 128th power.
The Asia Pacific region has been gobbling up the most IPv4 address space in recent years. Geoff Huston, Chief Scientist at APNIC, said APNIC allocated more than 58 million IPv4 addresses in the last two months alone: 41.2 million in March and 16.8 million in April. Among the largest allocations since February 1 were 8.3 million to NTT Communications of Japan, 4.1 million addresses to China Mobile, 4.1 million addresses to KDDI of Japan. and 3.1 million to North Star Information of China. Three other carriers -- India's Bharti Airtel Ltd.,  Pakistan Telecommunications and Chinanet Hunan Province Network -- all received 2 million IPv4 addresses.
APNIC has depleted its IPv4 address space "dramatically faster than people expected," DeLong says. "My guess is that a lot of operators in the Asia Pacific region realized the time of IPv4 depletion was drawing near and they rushed to get their applications in."


APNIC is holding 16.7 million IPv4 addresses -- dubbed a /8 in network engineering terms -- in reserve to distribute in tiny allotments of around 1,000 addresses each to new and emerging IPv6-based networks so they can continue to communicate with the largely IPv4-based Internet infrastructure.
ARIN, which doles out IPv4 and IPv6 address space to companies operating in North America, predicts that it will run out of IPv4 addresses this fall.
"RIPE [the European Internet registry] is going to be the next one to run out. I wouldn't count on them making it until July," DeLong says. "I think ARIN will make it to the end of this year; maybe we'll run out in October or November."

Asia runs out of IPv4 addresses

The Asia Pacific Network Information Centre (APNIC) has run out of all but a handful of IPv4 addresses that it is holding in reserve for start-up network operators.
APNIC is the first of the Internet's five regional Internet registries to deplete its free pool of IPv4 address space.
APNIC's news is another sign that CIOs and other IT executives need to begin migrating to IPv6, the long-anticipated upgrade to the Internet's main communications protocol known as IPv4.

"For anybody who hasn't figured out that it's time to do IPv6, this is another wake-up call for them," says Owen DeLong, an IPv6 evangelist at Hurricane Electric and a member of the advisory council of the American Registry for Internet Numbers (ARIN), the North American counterpart to APNIC.
Any CIO who isn't planning for IPv6 is "driving toward a brick wall and closing your eyes and hoping that it's going to disappear before you get there," DeLong says. Ignoring IPv6 "is not the best strategy."
Most IPv4 address space is expected to be handed out by the regional Internet registries by the end of 2011.
IPv4 uses 32-bit addresses and can support 4.3 billion devices connected directly to the Internet. IPv6, on the other hand, uses 128-bit addresses and supports a virtually unlimited number of devices -- 2 to the 128th power.
The Asia Pacific region has been gobbling up the most IPv4 address space in recent years. Geoff Huston, Chief Scientist at APNIC, said APNIC allocated more than 58 million IPv4 addresses in the last two months alone: 41.2 million in March and 16.8 million in April. Among the largest allocations since February 1 were 8.3 million to NTT Communications of Japan, 4.1 million addresses to China Mobile, 4.1 million addresses to KDDI of Japan. and 3.1 million to North Star Information of China. Three other carriers -- India's Bharti Airtel Ltd.,  Pakistan Telecommunications and Chinanet Hunan Province Network -- all received 2 million IPv4 addresses.
APNIC has depleted its IPv4 address space "dramatically faster than people expected," DeLong says. "My guess is that a lot of operators in the Asia Pacific region realized the time of IPv4 depletion was drawing near and they rushed to get their applications in."


APNIC is holding 16.7 million IPv4 addresses -- dubbed a /8 in network engineering terms -- in reserve to distribute in tiny allotments of around 1,000 addresses each to new and emerging IPv6-based networks so they can continue to communicate with the largely IPv4-based Internet infrastructure.
ARIN, which doles out IPv4 and IPv6 address space to companies operating in North America, predicts that it will run out of IPv4 addresses this fall.
"RIPE [the European Internet registry] is going to be the next one to run out. I wouldn't count on them making it until July," DeLong says. "I think ARIN will make it to the end of this year; maybe we'll run out in October or November."