Before we attempt to exploit any target, it is wise to do proper reconnaissance. Without doing reconnaissance, you will likely be wasting your time and energy as well as risking your freedom. In previous guides, I have demonstrated multiple ways to perform reconnaissance including passive recon with Netcraft, active recon with Nmap or hping3, recon by exploiting DNS or SNMP, and many others.
![](https://static.wixstatic.com/media/6a4a49_91fd3ff1c5434be795afb5fc153abdfd~mv2.jpg/v1/fill/w_147,h_84,al_c,q_80,usm_0.66_1.00_0.01,blur_2,enc_auto/6a4a49_91fd3ff1c5434be795afb5fc153abdfd~mv2.jpg)
In this tutorial, we will be using an active tool called Maltego, developed by Paterva, that can do many of these tasks with one simple scan. There is a community edition (CE) built into our Kali Linux that allows us 12 scans without purchasing Maltego (about $300/year). It is capable of a significant amount of information gathering about a prospective target in a single sweep of the domain. Maltego is able to gather information from open source information gathering between the following entities;
People.
Names.
Email addresses.
Aliases.
Groups of people (social networks).
Companies.
Organizations.
Web sites.
Internet infrastructure such as:
Domains.
DNS names.
Netblocks.
IP addresses.
Affiliations.
Documents and files.
Maltego fits into the the exciting new realm of Big Data and Data Science. This is the field that enables us to find and make connections from all the data that is now available on the Internet and social networking sites. These include Twitter, Facebook, LinkedIn, Instagram and many others. If we can gather that info and make sense of it, it will enable us to know more about our target making exploits and social engineering more likely to be successful!
Besides hackers and information security engineers, Maltego and tools similar to Maltego, are used by the NSA and other governmental entities. In this way, they can track potential terrorists and other threats. For instance, if NSA finds a phone call from a person in the U.S. to a known terrorist in another country, they can then use Maltego or other tools to find that individual's many connections on the web. This can then lead to targeted surveillance of potential threats.
Using Maltego in Kali to Recon a Target Network
Maltego is capable of gathering information about either a domain (infrastructural) or an personal; here we will focus on the former and leave personal information gathering for another time. We will be looking at gathering info on all the subdomains, the IP address range, the WHOIS info, all of the email addresses, and the relationship between the target domain and others.
Step 1: Open Maltego & Register
Let's start by firing up Kali and then opening Maltego. Maltego can be found in numerous places in Kali, but the easiest way to get to it is to go to Applications -> Kali Linux -> Top 10 Security Tools. Then, among the Top 10, you will find Maltego at number 5, as shown in the screenshot below.
![](https://static.wixstatic.com/media/6a4a49_e23c742d69724328adc85bb3201c21f2~mv2.jpg/v1/fill/w_118,h_73,al_c,q_80,usm_0.66_1.00_0.01,blur_2,enc_auto/6a4a49_e23c742d69724328adc85bb3201c21f2~mv2.jpg)
When you open Maltego, you will need to wait a brief moment for it to startup. After it finishes loading, you will be greeted by a screen asking you to register Maltego.
![](https://static.wixstatic.com/media/6a4a49_fb8059e3166a47abb2dc30745a025afb~mv2.jpg/v1/fill/w_118,h_82,al_c,q_80,usm_0.66_1.00_0.01,blur_2,enc_auto/6a4a49_fb8059e3166a47abb2dc30745a025afb~mv2.jpg)
Go ahead and register and save and remember your password as you will need it again the next time you login into Maltego.
Step 2: Choose a Machine & Parameters
After successfully registering and logging into Maltego, we will have to decide what type of "machine" we want to run against our target. In Maltego's parlance, a machine is simply what type of footprinting we want to do against our target. Here, we are focusing on the network footprinting, so our choices are:
Company Stalker (this gathers email information)
Footprint L1 (basic information gathering)
Footprint L2 (moderate amount of information gathering)
Footprint L3 (intense and the most complete information gathering)
![](https://static.wixstatic.com/media/6a4a49_c89073ba83b54e779fbca383612a9747~mv2.jpg/v1/fill/w_109,h_79,al_c,q_80,usm_0.66_1.00_0.01,blur_2,enc_auto/6a4a49_c89073ba83b54e779fbca383612a9747~mv2.jpg)
Let's choose an L3 footprint that will gather as much information as we can; this is also the most time-consuming option, so be aware of that.
Step 3: Choose a Target
Now, that we have chosen a type of machine for our footprinting, we will need to choose a target. Let's choose our friends at SANS, one of the leading IT security training and consulting firms in the world.
![](https://static.wixstatic.com/media/6a4a49_644b9fb5a35f4fc3a885f2edfe9ebeb2~mv2.jpg/v1/fill/w_113,h_80,al_c,q_80,usm_0.66_1.00_0.01,blur_2,enc_auto/6a4a49_644b9fb5a35f4fc3a885f2edfe9ebeb2~mv2.jpg)
Now, click "Finish" and let Maltego do its work.
Step 4: Results
Maltego will now begin to gather info on our target domain, sans.org, and display it on screen. In the screenshot below, we can see that Maltego has already collected the email addresses from the site, while it collects the nameservers and mail servers.
![](https://static.wixstatic.com/media/6a4a49_7b63b4ba34914040be5ffb3d18296957~mv2.jpg/v1/fill/w_118,h_88,al_c,q_80,usm_0.66_1.00_0.01,blur_2,enc_auto/6a4a49_7b63b4ba34914040be5ffb3d18296957~mv2.jpg)
Finally, we can click on "Bubble View" when Maltego is done and see all of the relationships between our target and its sub-domains and linked sites.
![](https://static.wixstatic.com/media/6a4a49_7a12e0addba74ad7b894b68398be06c1~mv2.jpg/v1/fill/w_118,h_82,al_c,q_80,usm_0.66_1.00_0.01,blur_2,enc_auto/6a4a49_7a12e0addba74ad7b894b68398be06c1~mv2.jpg)
Maltego is an excellent tool to do network recon on our potential target, enabling us to do numerous types of recon in a single scan with a single tool.
Maltego is also capable of doing personal recon enabling us to see the individuals many connections via the Internet, but we will leave that for my next Maltego article.