Sitemap

Sherlock: The Python-Based Tool for Automating Social Media OSINT and Reconnaissance

3 min readApr 11, 2023

--

Press enter or click to view image in full size

Social media platforms are often a treasure trove of personal and professional information that can be useful for reconnaissance during penetration testing or a targeted hack. Sherlock is a very simple tool that can be used to search for social media profiles by username. In this post, weโ€™ll go through the process of installing and using Sherlock on Kali Linux, and illustrate how the tool works.

First up is the installation. To install Sherlock, open a Linux terminal and run the command below.

sudo apt install sherlock

Once the installation is complete, verify that Sherlock is installed correctly by running the following command:

sherlock --help

This should display the help message for Sherlock, indicating that the tool is installed and ready to use.

Now letโ€™s put Sherlock to use. We can do this by simply running the following command in the terminal:

sherlock <username>

Replace <username> with the username you want to search for on social media platforms. Sherlock will then search for profiles on a variety of platforms, including Twitter, Instagram, GitHub, etc, and display the results in the terminal window.

Sherlock has uncovered 187 accounts for jdoe. As you can see, the tool identifies profiles on a variety of platforms and provides links to each profile for further investigation. But whatโ€™s also good to note is how you can use this to audit your own online accounts. You may have a bunch of stuff just sitting out there that you completely forgot about.

Additionally, Sherlock can be used to check the social media presence of a company by running the same search we performed earlier on a company name rather than a username.

Sherlock works by sending requests to the search API of each social media platform, using the specified username as a query parameter. The tool then parses the responses and extracts the profile URL, which is then displayed in the terminal window.

Sherlock supports a variety of social media platforms, each of which has its own search API and response format. To add support for a new platform, a new module can be created in the sherlock/modules directory, which defines the API endpoint and response parsing logic for that platform.

Sherlock is a powerful tool for social engineering and OSINT during penetration testing, providing a quick and easy way to search for social media profiles, across multiple platforms, associated with a given username.

--

--

Dave Probert

Written by Dave Probert

IT Professional | Ethical Hacker | Cybersecurity Specialist