Internet Security Foot Printing Defiana Arnaldy, M.Si 0818 0296 4763

Click here to load reader

download Internet Security Foot Printing Defiana Arnaldy, M.Si 0818 0296 4763

of 52

description

 Sun Tzu on the Art of War:  "If you know the enemy and know yourself, you need not fear the result of a hundred battles.  If you know yourself but not the enemy, for every victory gained you will also suffer a defeat.  If you know neither the enemy nor yourself, you will succumb in every battle."

Transcript of Internet Security Foot Printing Defiana Arnaldy, M.Si 0818 0296 4763

Internet Security Foot Printing Defiana Arnaldy, M.Si Overview Definition of Foot Printing Internet foot printing Sun Tzu on the Art of War: "If you know the enemy and know yourself, you need not fear the result of a hundred battles. If you know yourself but not the enemy, for every victory gained you will also suffer a defeat. If you know neither the enemy nor yourself, you will succumb in every battle." WHAT IS FOOTPRINTING? Definition: the gathering of information about a potential system or network (the fine art of gathering target information) a.k.a. fingerprinting Attackers point of view Identify potential target systems Identify which types of attacks may be useful on target systems Defenders point of view Know available tools May be able to tell if system is being footprinted, be more prepared for possible attack Vulnerability analysis: know what information youre giving away, what weaknesses you have Information to Gather System (Local or Remote) IP Address, Name and Domain Operating System Type (Windows, Linux, Solaris, Mac) Version (98/NT/2000/2003/XP/Vista/7, Redhat, Fedora, SuSe, Ubuntu, OS X) Usernames (and their passwords) File structure Open Ports (what services/programs are running on the system) Information to Gather (2) Networks / Enterprises System information for all hosts Network topology Gateways Firewalls Overall topology Network traffic information Specialized servers Web, Database, FTP,, etc. Defender Perspective Identify information youre giving away Identify weaknesses in systems/network Know when systems/network is being probed Identify source of probe Develop awareness of threat Construct audit trail of activity Why Is Footprinting Necessary? Footprinting is necessary to systematically and methodically ensure that all pieces of information related to the aforementioned technologies are identified Footprinting is often the most arduous task of trying to determine the security posture of an entity; however, it is one of the most important. Footprinting must be performed accurately and in a controlled fashion Without a sound methodology for performing this type of reconnaissance, you are likely to miss key pieces of information related to a specific technology or organization Internet Footprinting Step 1: Determine the Scope of Your Activities determine the scope of your footprinting activities Are you going to footprint the entire organization, or limit your activities to certain subsidiaries or locations? What about business partner connections (extranets), or disaster-recovery sites? Are there other relationships or considerations? Unfortunately, hackers have no sympathy for our struggles. They exploit our weaknesses in whatever forms they manifest themselves. You do not want hackers to know more about your security posture than you do! Step 2: Get Proper Authorization One thing hackers can usually disregard that you must pay particular attention to is what we techies affectionately refer to as layers eight and nine of the seven-layer OSI Model Politics and Funding Do you have authorization to proceed with your activities? what exactly are your activities? Is the authorization from the right person(s)? Is it in writing? Are the target IP addresses the right ones? Step 3: Publicly Available Information Company web pages Related organizations Location details Phone numbers, contact names,addresses, and personal details Current events (mergers, acquisitions, layoffs, rapid growth, etc.) Privacy or security policies, and technical details indicating the types of security mechanisms in place Archived information Disgruntled employees Search engines, Usenet, and resumes Other information of interest Step 4: WHOIS & DNS Enumeration So who is "managing" the Internet today, you ask? These core functions of the Internet are "managed" by a nonprofit organization named the Internet Corporation for Assigned Names and Numbers (ICANN; ICANN is a technical coordination body for the Internet. Created in October 1998 by a broad coalition of the Internet's business, technical, academic, and user communities, ICANN is assuming responsibility for a set of technical functions previously performed under U.S. government contract by the Internet Assigned Numbers Authority (IANA;and other groups. (In practice, IANA still handles much of the day-to-day operations, but these will eventually be transitioned to ICANN.)http://www.iana.org Specifically, ICANN coordinates the assignment of the following identifiers that must be globally unique for the Internet to function: Internet domain names IP address numbers Protocol parameters and port numbers In addition, ICANN coordinates the stable operation of the Internet's root DNS server system. To be thorough, we could have done the same searches via the command-line WHOIS client with the following three commands: [bash]$ whois com -h whois.iana.org [bash]$ whois keyhole.com -h whois.verisign-grs.com [bash]$ whois keyhole.com -h whois.omnis.com There are also several websites that attempt to automate this process with varying degrees of success: Last but not least, there are several GUIs available that will assist you in your searches too: SamSpade SuperScan NetScan Tools Pro Step 5: DNS Interrogation After identifying all the associated domains, you can begin to query the DNS. DNS is a distributed database used to map IP addresses to hostnames, and vice versa. If DNS is configured insecurely, it is possible to obtain revealing information about the organization. One of the most serious misconfigurations a system administrator can make is allowing untrusted Internet users to perform a DNS zone transfer A zone transfer allows a secondary master server to update its zone database from the primary master This provides for redundancy when running DNS, should the primary name server become unavailable. Generally, a DNS zone transfer needs to be performed only by secondary master DNS servers Many DNS servers, however, are misconfigured and provide a copy of the zone to anyone who asks. A simple way to perform a zone transfer is to use the nslookup client that is usually provided with most UNIX and Windows implementations. We can use nslookup in interactive mode, as follows: [bash]$ nslookup Default Server: ns1.example.net Address: > Server: ns1.example.net Address: Name: gate.tellurian.net Address: > set type=any > ls -d Tellurian.net. >\> /tmp/zone_out Step 6: Network Reconnaissance Now that we have identified potential networks, we can attempt to determine their network topology as well as potential access paths into the network. To accomplish this task, we can use the traceroute (ftp://www.ee.lbl.gov/traceroute.tar.gz) program that comes with most flavors of UNIX and is provided in Windows. In Windows, it is spelled tracert due to the 8.3 legacy filename issues.ftp://www.ee.lbl.gov/traceroute.tar.gz traceroute is a diagnostic tool originally written by Van Jacobson that lets you view the route that an IP packet follows from one host to the next. traceroute uses the time- tolive (TTL) option in the IP packet to elicit an ICMP TIME_EXCEEDED message from each router traceroute may allow you to discover the network topology employed by the target network, in addition to identifying access control devices (such as an applicationbased firewall or packet-filtering routers) that may be filtering our traffic Most of what we have done up to this point with traceroute has been command-line oriented. For the graphically inclined, you can use VisualRoute (http://www.visualroute.com),http://www.visualroute.com NeoTrace (http://www.neotrace.com), orhttp://www.neotrace.com Trout (http://www.foundstone.com)http://www.foundstone.com Tools - Linux Some basic Linux tools - lower level utilities Local System hostname ifconfig who, last Remote Systems ping traceroute nslookup, dig whois arp, netstat (also local system) Other tools lsof Tools Linux (2) Other utilities wireshark (packet sniffing) nmap (port scanning) - more later Ubuntu Linux Go to System / Administration / Network Tools get interface to collection of tools: ping, netstat, traceroute, port scan, nslookup, finger, whois Tools - Windows Windows Sam Spade (collected network tools) Wireshark (packet sniffer) Command line tools ipconfig Many others hostname Determine host name of current system Usage: hostname E.g. hostname localhost.localdomain// default E.g. hostname mobile.cs.uwec.edu ifconfig Configure network interface Tells current IP numbers for host system Usage: ifconfig E.g. ifconfig // command alone: display status eth0Link encap: Ethernet HWaddr 00:0C:29:CD:F6:D3 inet addr: loLink encap: Local Loopback inet addr: who Basic tool to show users on current system Useful for identifying unusual activity (e.g. activity by newly created accounts or inactive accounts) Usage: who E.g. who roottty1Jan 9 12:46 paultty2Jan 9 12:52 last Show last N users on system Default: since last cycling of file -N: last N lines Useful for identifying unusual activity in recent past Usage: last [-n] E.g. last -3 wagnerpj pts/ Sat Feb 5 15:40 still logged in flinstf pts/ Sat Feb 5 15:38 still logged in rubbleb pts/0 c48.someu.edu Sat Feb 5 14: :25 (00:46) ping Potential Uses Is system online? Through response Gather name information Through DNS Tentatively Identify operating system Based on TTL (packet Time To Live) on each packet line TTL = number of hops allowed to get to system 64 is Linux default, 128 is Windows default (but can be changed!) Notes Uses ICMP packets Often blocked on many hosts; more useful within network Usage: ping system E.g. ping ftp.redhat.com E.g. ping localhost traceroute Potential Uses Determine physical location of machine Gather network information (gateway, other internal systems) Find system thats dropping your packets evidence of a firewall Notes Can use UDP or ICMP packets Results often limited by firewalls Several GUI-based traceroute utilities available Usage: traceroute system E.g. traceroute cs.umn.edu traceroute example - blocked ~]$ traceroute cs.umn.edu traceroute to cs.umn.edu ( ), 30 hops max, 38 byte packets ( ) ms ms ms 2 v101.networking.cns.uwec.edu ( ) ms ms ms 3 uweauclairehub2-ge50.core.wiscnet.net ( ) ms ms ms 4 * * * ~]$ traceroute example - success H:\>tracertTracing route to[ ] over a maximum of 30 hops:www.google.akadns.net 1