<![CDATA[Manish M. Shivanandhan]]>https://www.manishmshiva.com/https://www.manishmshiva.com/favicon.pngManish M. Shivanandhanhttps://www.manishmshiva.com/Ghost 4.13Wed, 08 Sep 2021 12:15:34 GMT60<![CDATA[Web Server Scanning With Nikto - An Introduction]]>https://www.manishmshiva.com/web-server-scanning-with-nikto-an-introduction/60ebb8076c562d003b3452faMon, 12 Jul 2021 15:17:21 GMTNikto is an open-source scanner that helps find vulnerabilities in web servers. You can scan your web apps for vulnerabilities like misconfigured services, dangerous files, and thousands of other potential security issues using Nikto.Web Server Scanning With Nikto - An Introduction

Websites are a critical part of almost every business or organization in the world. From your nearby florist to global brands, almost everyone uses a website as part of their branding.

Unfortunately, websites are also one of the most unsecured gateways through which an attacker can exploit your company. Since most websites are not backed by strong technical teams, it is important to understand website and web application security to protect your organization.

Introducing Nikto

Nikto is an Open Source web server and web application scanner. Nikto can perform comprehensive tests against web servers for multiple security threats, including over 6700 potentially dangerous files/programs. Nikto can also perform checks for outdated web servers software, and version-specific problems.

Nikto was written and maintained by Sullo, CIRT, Inc. It is written in Perl and was originally released in late 2001. It is currently maintained by David Lodge (you can find his blog here), though other contributors have been involved in the project as well.

Here are some of the cool things that Nikto can do:

  • Find SQL injection, XSS, and other common vulnerabilities
  • Identify installed software (via headers, favicons, and files)
  • Guess subdomains
  • Support for SSL (HTTPS) websites
  • Saves reports in plain text, XML, HTML or CSV
  • “Fish” for content on web servers
  • Report unusual headers
  • Check for server configuration items such as the presence of multiple index files, HTTP server options. etc.
  • Full HTTP proxy support
  • Template engine to easily customize reports
  • Guess credentials for authorization (including many default username/password combinations)
  • Exports to Metasploit

Installing Nikto

Since Nikto is a Perl-based program, it can run on most operating systems with the necessary Perl interpreter installed

If you’re using Kali Linux, Nikto comes preinstalled and will be present in the “Vulnerability Analysis” category. If you don’t have Nikto on Kali (for some reason), you can get Nikto from GitHub or just use the “apt install nikto” command.

For installing Nikto on windows, you must first install the Perl interpreter. It can be downloaded from: http://www.activestate.com/activeperl . For mac, you can use homebrew.

Complete installation instructions for all platforms can be found here.

Scanning With Nikto

Now that we know what Nikto is and how to install it, let's go ahead and run some scans.

Before we get into scanning, I would like to emphasize that I am not responsible for any damage you do trying to attack systems. Its illegal. You should have written permission before you even try to scan a system or a network.

Since Nikto is a command-line tool, you can use the help command to get a list of options.

nikto -Help
Web Server Scanning With Nikto - An Introduction

Scanning a Domain

To perform a simple domain scan, use the -h (host) flag.

> nikto -h scanme.nmap.org

Nikto will perform a basic scan on port 80 for the given domain and give you a complete report based on the scans performed.

Web Server Scanning With Nikto - An Introduction
Nikto Domain Scan

Scanning a Domain with SSL enabled

For domains with HTTPS enabled, you have to specify the -ssl flag to scan port 443.

> nikto -h https://nmap.org -ssl
Web Server Scanning With Nikto - An Introduction
Nikto SSL Enabled Scan

Scanning Ip Address

Sometimes you just want to scan an IP address where a web server is hosted. To do that, use the same -h flag we used for domain scanning.

> nikto -h
Web Server Scanning With Nikto - An Introduction
Nikto IP Address Scan

Scanning Multiple Ip Addresses from a Text File

To scan multiple IP addresses or domains, just put them in a text file separated by newlines. Nikto will know that the scan has to be performed on each domain / IP address.

Let's assume we have a file named domains.txt with two domain names: —

  • scanme.nmap.org
  • nmap.org.

To scan both of them with Nikto,

> nikto -h domains.txt

Nikto will start scanning the domains one after the other.

Web Server Scanning With Nikto - An Introduction
Nikto Multi Domain Scan

Exporting Scan Results

Nikto scans take a while to complete. When you are a professional pen-tester, you don't want to repeat scans very often unless there are major changes to the web application.

To export a scan result, use the -o flag followed by the file name.

> nikto -h scanme.nmap.org -o scan.txt

You can also use the -Format flag to specify an output format. You can choose from CSV, HTML, nbe (Nessus format), SQL, txt and XML.

> nikto -h scanme.nmap.org -o scan.csv -Format csv
Web Server Scanning With Nikto - An Introduction
Nikto Output Formats

Pairing with Metasploit

Metasploit is a powerful framework that lets you do everything from scanning to exploiting systems. Professional pen-testers use Metasploit almost every day. I wrote a detailed article on Metasploit recently and you can find it here.

Nikto offers a way to export scans to Metasploit so that it gets easier when you try to exploit systems based on the scan results from Nikto. To do that, append the “-Format msf+” flag to the end of a scan.

> nikto -h <domain/ip> -Format msf+

Nikto Alternatives

It is always good to have a backup tool in your pen-testing arsenal. Some of the best Nikto alternatives are:

  • Arachni: Open Source, modular, high-performance Ruby framework with a focus on evaluating the security of web applications.
  • OWASP Zed Attack Proxy (ZAP): Integrated pen-testing tool that provides automated scanners as well as a set of tools that allow you to find security vulnerabilities manually.
  • Skipfish: Fully automated, active web application security reconnaissance tool. Written in C to be fast, highly optimized HTTP handling, and minimal CPU footprint — easily achieving 2000 requests per second with responsive targets.


Nikto is an open-source scanner that helps you find potential security threats in your websites and web applications. It fully automates vulnerability scanning and can find issues like service misconfigurations, insecure files/programs, and thousands of other security issues. Great alternatives include Arachini, OWASP ZAP, and Skipfish.


Loved this article? Join my Newsletter and get a summary of my articles and videos every Monday.

<![CDATA[Social Engineering — The Art Of Hacking Humans]]>https://www.manishmshiva.com/social-engineering-the-art-of-hacking-humans/60b78265bc82b4003b872854Mon, 28 Sep 2020 03:30:00 GMTDisclaimer: My articles are purely educational. If you read them and cause damage to someone, that's on you. I don't encourage any malicious activity or black hat practices. Read the code of ethics here.Social Engineering — The Art Of Hacking Humans

Remember the Nigerian scammers sending you emails about the rich prince that needs your help? All you had to do was transfer a thousand dollars in exchange for a multi-million dollar fortune.

There are similar scams that have circulated the internet: The IRS scam, Lottery scams, and so on. These are broadly classified as the Advance offer scams. You have something waiting for you but you have to pay an advance to receive it.

To the average person, these will seem like poorly executed scam attacks, but these scams have made thousands of people lose their hard-earned money. In some cases, their life savings.

Social engineering is the act of manipulating someone into divulging information or doing something. This action is usually not in the best interest of the victim.

The idea behind social engineering is to take advantage of a potential victim’s natural tendencies and emotional reactions. Fear and greed are the most vulnerable emotions that are usually taken advantage of by Social Engineers. Below is a great example of a real-world Social engineering attack.

Types of Social Engineering Attacks

Social engineering can be broadly classified into five types based on the type of approach used to manipulate a target. Let's go through each one of them.

Spamming (Email, Text, Whatsapp)

Spamming is sending messages to large groups of people whose contacts are usually obtained through nefarious ways. Spamming is a general term used to define both malicious and non-malicious message broadcasting.

Non-malicious spamming is used by advertisers who try to promote their products to random strangers by emailing them in bulk. Their motive is not to cause damage, but to try and get people to buy their products or promote their services.

Malicious spamming includes messages that try to lure users to the attacker’s website to divulge personal information. This information is then used to craft targeted phishing/vishing attacks on the potential victim.

Phishing (and Vishing)

When the attacker uses text messaging, email, or voice calling (voice phishing = vishing), it is called Phishing. Phishing is used to make the target believe they are being called by a legitimate institution or an entity in order to extract valuable information from the target.

If someone calls your company pretending to be your printer supplier, they might be able to gain specific information about the printer — the model, IP address (if connected to the internet), and so on. Once this information is found, the printer might be attacked in order to gain access to your internal network.

Email-based phishing attacks are also common. An attacker can email someone in your company pretending to be Facebook. Once they click a link, they will end up on a page that looks like Facebook, asking them for the login information. This login information will be sent to the attacker’s server after which they have complete access to the victim’s Facebook account.

The major difference between Phishing and Scamming is that phishing attacks are highly targeted. The attacker knows who they want to attack and what type of information they are looking for.


Baiting is designing a trap and waiting for the potential victim to walk into the trap. As a simple example, if an attacker drops a few USB drives in your company’s parking lot, chances are, one of your employees will try and plug it into their computer to check the contents of the USB drive.

This might sound silly but there have been numerous instances where simple tricks by Social Engineers have resulted in massive corporate data breaches. It is usually easy to bait people with scams such as the Advance offer scams that are still circulating the internet, feeding on gullible people.

Another common type of baiting is found in pirated software. The attacker will embed malicious software within a popular operating system or a movie for the victim to download. Once the victim downloads and runs the software, the malicious code executes on the victim’s system, and the attacker gains full access to the victim’s machine.


PiggyBacking is using someone else to attack a potential victim. The attacker will use a third-party (usually innocent) who has access to the victim in order to carry out a piggybacking attack.

There are many variations of Piggybacking. If an attacker follows your employee to your office using his access card, it is one form of piggybacking called tailgating.

There have been many cases of piggybacking attacks, especially for classified information. Vendor companies that supply hardware/software to government organizations are usually the target of piggybacking attacks.

Once these vendors are compromised, it is easy to attack the target institution since the vendor already has a level of access to the target.

Piggybacking is also associated with some forms of active Wiretapping. The attacker will use a legitimate connection of the victim in order to eavesdrop on the network.

I recently wrote an article on Wireshark which you might find interesting.

Water Holing

Water Holing takes into account the routine actions of the target and using one of those actions to gain unauthorized access. For example, an attacker will find the websites that the target uses on a daily basis and tries to install malware on one of those websites.

The name “Water Holing” is derived from the fact that predators in the wild often wait for their prey near the common watering holes.

An example is the 2019 Holy Water Campaign, which targeted Asian religious and charity groups. The website was compromised after which the visitors were asked to install Adobe Flash on their browsers.

Since adobe flash has a number of vulnerabilities, it was easy for the attackers to then execute malicious code on the victim’s machines. Watering hole attacks are uncommon but they pose a considerable threat since they are very difficult to detect.

Protecting Yourself From Social Engineering

Now that we have seen the different types of approaches used by social engineers, let's look at how we can protect ourselves and our organization from social engineering attacks.

  • Install email & spam filters — Though spam filters cannot catch highly targeted attacks, they will prevent most of the spam and malicious emails from reaching your account.
  • Keep Antivirus and firewall updated — Similar to spam filters, an updated antivirus will prevent most of the common viruses, trojans, and malware.
  • Ask for verification — Always ask for verification when someone calls you claiming to represent an organization, eg. your bank. Never share confidential details such as credit card numbers or passwords over phone or email.
  • Create awareness — The best way to prevent your organization from getting exploited is to create security awareness programs. Educating your employees is a great long-term investment to keep your company secure.
  • If it’s too good to be true, it is. — Finally, if something sounds too good to be true, it usually is. Never trust strangers promising to get you rich quick. As someone once said, “trying to get rich quick is the quickest way to lose all your money”.


Social Engineers are masters of manipulation. Unless a company’s employees are trained in social engineering awareness, it is very hard for them to avoid falling into a social engineer’s trap.

Social engineers work with people’s emotions, usually fear and greed. So whenever you are performing an action based on these two emotions, you might want to take a step back and see if you are being manipulated.

There is a famous TED talk where someone started a conversation with a spammer. Watch the full video here.

Get a summary of my articles and videos sent to your email every Monday morning. You can also learn more about me here.

<![CDATA[Numpy Crash Course — Building Powerful n-Dimensional Arrays with NumPy]]>https://www.manishmshiva.com/numpy-crash-course-building-powerful-n-dimensional-arrays-with-numpy/60b3a411bc82b4003b87277dTue, 22 Sep 2020 03:30:00 GMTIntroductionNumpy Crash Course — Building Powerful n-Dimensional Arrays with NumPy

NumPy is a Python library used to perform numerical computations with large datasets. Numpy stands for Numerical Python and it is a popular library used by data scientists, especially for machine learning problems. NumPy is useful during pre-processing the data before you train it using a machine learning algorithm.

Working with n-dimensional arrays is easier in Numpy compared to Python lists. Numpy arrays are also faster than Python lists since unlike lists, NumPy arrays are stored at one continuous place in memory. This enables the processor to perform computations efficiently with NumPy arrays.

In this article, we will look at the basics of working with Numpy including array operations, matrix transformations, generating random values, and so on.


Clear installation instructions are provided at the official website of NumPy, so I am not going to repeat it here again. Please find the instructions here.

Working with NumPy

Here is a google colab notebook if you want to try out these examples below.

Importing NumPy

To start using NumPy in your script, you have to import it.

import numpy as np

Converting Arrays to NumPy Arrays

You. can convert your existing python lists into NumPy arrays using the np.array() method.

arr = [1,2,3]

This also applies to multi-dimensional arrays. Numpy will keep track of the shape (dimensions) of the array.

nested_arr = [[1,2],[3,4],[5,6]]

NumPy Arange Function

When working with data, you will often come across use cases where you need to generate data.

Numpy as an “arange()” method with which you can generate a range of values between two numbers. The arange function takes the start, end, and an optional distance parameter.

print(np.arange(0,10)) # without distance parameter
OUTPUT:[0 1 2 3 4 5 6 7 8 9]
print(np.arange(0,10,2)) # with distance parameter
OUTPUT: [0 2 4 6 8]

Zeroes and Ones

You can also generate an array or matrix of zeroes or ones using NumPy (trust me, you will need it). Here's how.

OUTPUT: [0. 0. 0.]
OUTPUT: [1. 1. 1.]

Both these functions support n-dimensional arrays as well. You can add the shape as a tuple with rows and columns.

 [0. 0. 0. 0. 0.]
 [0. 0. 0. 0. 0.]
 [0. 0. 0. 0. 0.]
 [0. 0. 0. 0. 0.]
 [0. 0. 0. 0. 0.]
 [1. 1. 1. 1. 1.]
 [1. 1. 1. 1. 1.]
 [1. 1. 1. 1. 1.]
 [1. 1. 1. 1. 1.]
 [1. 1. 1. 1. 1.]

Identity Matrix

You can also generate an identity matrix using a built-in Numpy function called “eye”.


NumPy Linspace Function

NumPy has a linspace method that generates evenly spaced points between two numbers.

OUTPUT:[ 0.  5. 10.]

In the above example, the first and second params are the start and the end points, while the third param is the number of points you need between the start and the end.

Here is the same range with 20 points.

OUTPUT:[ 0. 0.52631579  1.05263158  1.57894737  2.10526316  2.63157895   3.15789474  3.68421053  4.21052632  4.73684211  5.26315789  5.78947368   6.31578947  6.84210526  7.36842105  7.89473684  8.42105263  8.94736842   9.47368421 10.]

Random Number Generation

When you are working on machine learning problems, you will often come across the need to generate random numbers. Numpy has in-built functions for that as well.

But before we start generating random numbers, let's look at two major types of distributions.

Numpy Crash Course — Building Powerful n-Dimensional Arrays with NumPy

Normal Distribution

In a standard normal distribution, the values peak in the middle. The normal distribution is a very important concept in statistics since it seen in many natural phenomena. It is also called as the “bell curve”.

Uniform Distribution

If the values in the distribution have the probability as a constant, it is called a uniform distribution. eg. A coin toss has a uniform distribution since the probability of getting either heads or tails in a coin toss is the same.

Now that you know the two main distributions work, lets generate some random numbers.

  • To generate random numbers in a uniform distribution, use the rand() function from np.random.
print(np.random.rand(10)) # array
OUTPUT: [0.46015141 0.89326339 0.22589334 0.29874476 0.5664353  0.39257603  0.77672998 0.35768031 0.95087408 0.34418542]

print(np.random.rand(3,4)) # 3x4 matrix
OUTPUT:[[0.63775985 0.91746663 0.41667645 0.28272243]  [0.14919547 0.72895922 0.87147748 0.94037953]  [0.5545835  0.30870297 0.49341904 0.27852723]]
  • To generate random numbers in a normal distribution, use the randn() function from np.random.
OUTPUT:[-1.02087155 -0.75207769 -0.22696798  0.86739858  0.07367362 -0.41932541   0.86303979  0.13739312  0.13214285  1.23089936]

OUTPUT: [[ 1.61013773  1.37400445  0.55494053  0.23133522]  [ 0.31290971 -0.30866402  0.33093618  0.34868954]  [-0.11659865 -1.22311073  0.36676476  0.40819545]]
  • To generate random integers between a low and high value, use the randint() function from np.random
OUTPUT:[64 37 62 27  4 33 23 52 70  7]

OUTPUT:[[92 42 38]  [87 69 38]]

A seed value is used if you want your random numbers to be the same during each computation. Here is how you set a seed value in NumPy.

  • To set a seed value in NumPy

OUTPUT:[0.37454012, 0.95071431, 0.73199394, 0.59865848]

Whenever you use a seed number, you will always get the same array generated without any change.

Reshaping Arrays

As a data scientist, you will work with re-shaping the data sets for different types of computations. In this section, we will look at how to work with the shapes of the arrays.

  • To get the shape of an array, use the shape property.
arr = np.random.rand(2,2)

[0.19890857 0.00806693]
[0.48199837 0.55373954]
(2, 2)
  • To reshape an array, use the reshape() function.
OUTPUT: [[0.19890857 0.00806693 0.48199837 0.55373954]]


In order to permanently reshape an array, you have to assign the reshaped array to the ‘arr’ variable. Also, reshape only works if the existing structure makes sense. You cannot reshape a 2x2 array into a 3x1 array.

Slicing Data

Let's look at fetching data from NumPy arrays. NumPy arrays work similarly to Python lists during fetch operations.

  • To slice an array
myarr = np.arange(0,11)

sliced = myarr[0:5]
OUTPUT: [0 1 2 3 4]

sliced[:] = 99
OUTPUT: [99 99 99 99 99]

OUTPUT:[99 99 99 99 99  5  6  7  8  9 10]

If you look at the above example, even though we assigned the slice of “myarr” to the variable “sliced”, changing the value of “sliced” affects the original array. This is because the “slice” was just pointing to the original array.

To make an independent section of an array, use the copy() function.

sliced = myarr.copy()[0:5]
  • Slicing multi-dimensional arrays work similarly to one-dimensional arrays.
my_matrix = np.random.randint(1,30,(3,3))
[21  1 20]
[22 16 27]
[24 14 22]

print(my_matrix[0]) # print a single row
OUTPUT: [21  1 20]

print(my_matrix[0][0]) # print a single value or row 0, column 0

print(my_matrix[0,0]) #alternate way to print value from row0,col0

Array Computations

Now let's look at array computations. Numpy is known for its speed when performing complex computations on large multi-dimensional arrays.

Let’s try a few basic operations.

new_arr = np.arange(1,11)
OUTPUT: [ 1  2  3  4  5  6  7  8  9 10]
  • Addition
print(new_arr + 5)
OUTPUT: [ 6  7  8  9 10 11 12 13 14 15]
  • Subtraction
print(new_arr - 5)
OUTPUT: [-4 -3 -2 -1  0  1  2  3  4  5]
  • Array Addition
print(new_arr + new_arr)
OUTPUT: [ 2  4  6  8 10 12 14 16 18 20]
  • Array Division
print(new_arr / new_arr)
OUTPUT:[1. 1. 1. 1. 1. 1. 1. 1. 1. 1.]

For Zero division errors, Numpy will convert the value to NaN (Not a number)

There are also a few in-built computation methods available in NumPy to calculate values like mean,standard deviation, variance, etc.

  • Sum — np.sum()
  • Square Root — np.sqrt()
  • Mean — np.mean()
  • Variance — np.var()
  • Standard Deviation — np.std()

While working with 2d arrays, you will often need to calculate row wise or column-wise sum, mean, variance, etc. You can use the optional axis parameter to specify if you want to choose a row or a column.

arr2d = np.arange(25).reshape(5,5)
[ 0  1  2  3  4]
[ 5  6  7  8  9]
[10 11 12 13 14]
[15 16 17 18 19]
[20 21 22 23 24]


print(arr2d.sum(axis=0))  # sum of columns
OUTPUT: [50 55 60 65 70]

print(arr2d.sum(axis=1)) #sum of rows
OUTPUT: [ 10  35  60  85 110]

Conditional Operations

You can also do conditional filtering using NumPy using the square bracket notation. Here is an example.

arr = np.arange(0,10)
OUTPUT: [0,2,3,4,5,6,7,8,9]

print(arr > 4)
OUTPUT: [False False False False False  True  True  True  True  True]

print(arr[arr > 4])
OUTPUT: [5 6 7 8 9]


When it comes to working with large datasets, Numpy is a powerful tool to have in your toolkit. It is capable of handling advanced numeric computations and complex n-dimensional array operations. It is highly recommended that you learn NumPy if you plan to start a career in machine learning.

Get a summary of my articles and videos sent to your email every Monday morning. You can also connect with me here.

<![CDATA[WiFi Hacking — Securing Wifi Networks With Aircrack-NG]]>https://www.manishmshiva.com/wifi-hacking-securing-wifi-networks-with-aircrack-ng/60b3a720bc82b4003b872806Thu, 17 Sep 2020 03:30:00 GMT

Imagine a world without wifi. We would still be using long wires of ethernet cables to connect to the internet.

There is no debate on how much WiFi has made our lives easier. Now we can connect to the internet on coffee shops, subway stations and almost anywhere we go.

However, WiFi is also a vulnerable network compared to the ethernet. Unless it is properly secured, it's easy to perform man-in-the-middle attacks using tools like Wireshark.

For example, if you are connected to a Starbucks network, anyone connected to that network can look at every other person’s network traffic. Unless you use a VPN or the website uses https, your data (including passwords and credit card details) will be visible to the entire network.

If you are working for a company, chances are, they use WiFi networks too. Have you wondered how secure it is? Do you know if someone in the parking lot is connected to your network and capturing your company’s confidential data?

With tools like Wireshark and Aircrack, you can perform security audits of your WiFi networks. While Wireshark can help you watch what is happening on your network, Aircrack is more of an offensive tool that lets you attack and gain access to WiFi networks.

A quick sidenote: I am in no way encouraging the use of illegal offensive tools. These are purely educational and to help you defend your networks better.

Before we look at Aircrack in detail, here are a few terms you should know.

  • Access Point — The WiFi network that you want to connect to.
  • SSID — The name of the access point. eg. “Starbucks”
  • Pcap file — Packet capture file. Contains captured packets on a network. The common format for tools including Wireshark and Nessus.
  • Wired Equivalent Privacy (WEP) — Security algorithm for wireless networks.
  • Wi-Fi Protected Access (WPA & WPA2) — Stronger security algorithm compared to WEP.
  • IEEE 802.11Wireless Local Area Network (LAN) protocol.
  • Monitor mode — Capturing the network packets in the air without connecting to a router or access point.

I recently wrote a post on the top 100 terms you should know as a penetration tester. You can check it out if you are interested.


Aircrack is a software suite that helps you to attack and defend wireless networks. Aircrack is not a single tool, but a suite of tools, each of which performs a specific function. These tools include a detector, packet sniffer, WEP/WPA cracker, and so on.

The main purpose of Aircrack is to capture the packets and read the hashes out of them in order to crack the passwords. Aircrack supports almost all the latest wireless interfaces.

Aircrack is open-source, and can work on Linux, FreeBSD, macOS, OpenBSD, and Windows platforms.

The ‘NG’ in Aircrack-ng stands for “new generation”. Aircrack-ng is an updated version of an older tool called Aircrack. Aircrack also comes pre-installed in Kali Linux.

WiFi Adapter

WiFi Hacking — Securing Wifi Networks With Aircrack-NG

Before we start working with Aircrack, you will need a WiFi adapter. Aircrack only works with a wireless network interface controller whose driver supports raw monitoring mode and can sniff 802.11a, 802.11b, and 802.11g traffic.

Typical wifi adapters (usually built-in with your computer) don't have the ability to monitor traffic from other networks. You can only use them to connect to a WiFi access point.

With an Aircrack compatible wifi adapter, you can enable the ‘monitor mode’ with which you can sniff traffic from networks you are not connected to. You can then use that captured data to crack the password of that network.

Check out the list of WiFi adapters that are compatible with Kali Linux here.

Aircrack Tools

Now that you know what you can do with Aircrack, let’s look at each of its tools.


Airmon-ng is a script to place your network interface card into monitor mode. Once this is enabled, you should be able to capture network packets without the need to connect or authenticate with an access point.

You can use the command ‘airmon-ng’ to list the network interfaces and ‘airmon-ng start <interface name>’ to start an interface in monitor mode.

WiFi Hacking — Securing Wifi Networks With Aircrack-NG

In the above example, you can see that the network interface “wlan0” has been turned into “wlan0mon” — meaning the monitor mode has been enabled for it.


Airodump-ng is a packet capture utility that captures and saves raw data packets for further analysis. If you have a GPS receiver connected to your computer, airodump-ng can fetch the coordinates of the access points as well.

After enabling monitor mode using airmon-ng, you can start capturing packets using airodump. Running the command ‘airodump-ng’ will list the available access points. The ESSID (or SSID) is the name of the wireless network.

WiFi Hacking — Securing Wifi Networks With Aircrack-NG


Once you have captured enough packets using airodump-ng, you can crack the key using aircrack-ng. Aircrack uses statistical, brute force, and dictionary attacks to break the WEP / WPA key.

WiFi Hacking — Securing Wifi Networks With Aircrack-NG

It is important to note that you need enough packets in order to crack the key. Also, aircrack-ng uses sophisticated algorithms to crack the keys from the network packets. If you are interested in learning more about how Aircrack does this, this would be a good starting point.


Aireplay-ng is used to create artificial traffic on a wireless network. Aireplay can either capture traffic from a live network or use the packets from an existing Pcap file to inject it into a network.

With aireplay-ng, you can perform attacks such as fake authentication, packet injection, caffe-latte attack, etc.

The Cafe Latte attack allows you to obtain a WEP key from a client device. This is done by capturing an ARP packet from the client, manipulating it, and then sending it back to the client.

The client will then generate a packet that can be captured by airodump-ng. Finally, aircrack-ng can be used to crack the WEP key form that modified packet.


Airbase-ng is used to convert an attacker’s computer into a rogue access point for others to connect to. Using Airbase, you can pretend to be a legitimate access point and perform man-in-the-middle attacks on devices that connect to your system.

WiFi Hacking — Securing Wifi Networks With Aircrack-NG

This attack is also called the “Evil Twin Attack”. Assuming you are in Starbucks trying to connect to their Wifi, an attacker can create another access point with the same name (usually with better signal strength) making you think that the access point belongs to Starbucks.

It is hard for regular users to differentiate between a legitimate access point and a rogue access point. So the evil twin attack remains one of the dangerous wireless attacks we encounter today.

In addition to these, there are a few more tools for you to use in the Aircrack arsenal.

  • Packetforge-ng — Used to create encrypted packets for injection.
  • Airdecap-ng — Decrypts WEP/WPA encrypted capture files after you crack the key with aircrack-ng. This will give you access to usernames, passwords, and other sensitive data.
  • Airolib-ng — Stores pre-computed WPA/WPA2 passphrases in a database. Used with aircrack-ng while cracking passwords.
  • Airtun-ng — Creates virtual tunnel interfaces.


The world is a more connected place, thanks to WiFi. We enjoy the benefits of WiFi almost every single day. With all its benefits, it is also a vulnerable network capable of exposing our private information, if we are not careful.

Hope this article helped you understand WiFi security and Aircrack in detail. To learn more about Aircrack in detail, check out their official wiki.

Loved this article? Join my Newsletter and get a summary of my articles and videos sent to your email every Monday. You can also connect with me here.

<![CDATA[Penetration Testing — All The Terms You Need To Know]]>https://www.manishmshiva.com/penetration-testing-all-the-terms-you-need-to-know/60b3a3a9bc82b4003b872773Mon, 07 Sep 2020 03:30:00 GMT
  • Authentication — Authentication is the process of checking if a user is allowed to gain access to a system. This is commonly achieved by using username/passwords, ssh keys, etc.
  • Authorization — Authorization is the process of checking if the authenticated user has permission to perform an action. For example, after logging into Facebook, you are authorized to update your profile and settings, but not anyone else’s.
  • Audit —  Generally, audit means “inspection”. In Cybersecurity, an audit is to conduct a complete inspection of an organization’s network to find vulnerabilities. Also called “penetration testing”, cybersecurity professionals attack their own systems (or other’s systems with permission) in order to figure out how vulnerable their devices are.
  • Access Control List — A list that contains users and their level of access to a system. Users are usually grouped into “Roles” and permissions are combined into “policies”. So you can either assign a user into a role (with pre-defined permissions) or assign a policy to a user.
  • Aircrack-NG — Aircrack is a software suite that helps you to attack and defend wireless networks. Aircrack is not a single tool, but a suite of tools, each of which performs a specific function like a detector, packet sniffer, WEP/WPA cracker, and so on.
  • Backdoor — A Backdoor is a piece of code that lets hackers get into the system easily after it has been compromised. Since an attacker has to go through multiple stages in order to successfully exploit a system, they don't usually want to go through it again.
  • Burp Suite — Burpsuite is a web application security software that helps to test web apps for vulnerabilities. Burpsuite gives you fine-grained information about requests and responses and is used extensively in bug bounty hunting.
  • Banner Grabbing — Banner grabbing is the process of capturing basic information about a server. This includes the type of web server software (eg. apache), services, or even service versions running on the system.
  • Botnet — Network of computers controlled by a hacker to perform attacks such as Distributed Denial of Service.
  • Brute-Force Attack — Method of trying to gain access to a system by trying different login combinations to gain access to the system. eg. trying to crack a 9 -digit numeric password by trying all the numbers from 000000000 to 999999999.
  • Buffer Overflow — When a program tries to store more information than it is allowed to, it overflows into other memory partitions called “Buffers”. This leads to corrupting existing data on those buffers.
  • Cipher — Cryptographic algorithm for encrypting and decrypting data.
  • Domain Name System (DNS) — Helps convert domain names into server IP addresses. eg. Google.com ->
  • DNS Spoofing — Trikcnig a system's DNS to point to a malicious server. eg. when you enter ‘facebook.com’, you might be redirected to the attacker’s website that looks like Facebook.
  • Netcat — Simple but powerful tool that can view and record data on TCP or UDP network connections. Since it is not actively maintained, NCat is preferred.
  • Phishing — Building fake websites that look remarkably similar to legitimate websites (like Facebook) to capture sensitive information.
  • Rainbow Table — Pre-calculated password hashes that will help you crack password hashes of the target easily.
  • Secure Shell (SSH) — Protocol that establishes an encrypted communication channel between a client and a server. You can use ssh to log in to remote servers and perform system administration.
  • Secure Hashing Algorithm (SHA) — Widely used family of encryption algorithms. SHA256 is considered highly secure compared to earlier versions like SHA 1. It is also a one-way algorithm, unlike an encryption algorithm that you can decrypt. Once you hash a message, you can only compare it with another hash, you cannot re-hash it to its earlier format.
  • Trojan — Malware hidden within useful software. eg. a pirated version of MS office can contain trojans that will execute when you install and run the software.
  • Virus — A piece of code that is created to perform a specific action on the target systems. A virus has to be triggered to execute eg. automatically playing a USB drive.
  • Worm — A malware program capable of replicating itself and spreading to other connected systems. eg. a worm to build a botnet. Unlike Viruses, Worms don't need a trigger.
  • Zero-Day — A newly discovered vulnerability in a system for which there is no patch yet. Zero-day vulnerabilities are the most dangerous type of vulnerability since there is no possible way to protect against one.

  • Penetration Testing — All The Terms You Need To Know


    <![CDATA[Ethical Hacking Lifecycle —Five Stages Of A Penetration Test]]>https://www.manishmshiva.com/ethical-hacking-lifecycle-five-stages-of-a-penetration-test/60b3a664bc82b4003b8727e7Thu, 03 Sep 2020 03:30:00 GMTBefore we get into the article, I would like to emphasize that I am not responsible for any damage you do trying to attack systems. Its illegal. You should have written permission before you even try to scan a system or a network.Ethical Hacking Lifecycle —Five Stages Of A Penetration Test

    Cybersecurity is one of the hottest fields to be in, thanks to companies going remote. Cyber threats are increasing and cybercriminals are finding new ways to exploit systems.

    Penetration testing is how the good guys work. They think like hackers and attack their own systems. This helps them understand their strengths and weaknesses and protect their organizational assets.

    A pen-test comprises of multiple stages. You cannot simply get into a system by using a tool unless the target is hopelessly vulnerable.

    In most cases, systems are secured via firewalls, antiviruses, default operating system configurations, etc. It takes the right tools, a strong skill set, and most importantly, patience, in order to successfully exploit a network.

    So let's look at the five main stages a penetration tester will go through along with the tools they use to break into a network.

    You can also find the article I wrote on the top 10 tools cybersecurity professionals use here.



    Reconnaissance is the most important part of a penetration test. It is where you gain information about the target.

    The reason reconnaissance is important is because the more information you have about the target, the easier it gets when you try to gain access. Once you map out an entire network, you can identify the weakest spot and start from there.

    Commonly used Recon tools include Google (yeah!) and other social media where you can gather information about the target. If you are performing an audit of a company, you can go through the company’s job posting to see the type of technologies they use.

    Once you have gained enough information, you can use a tool like Maltego to map the targets.

    Ethical Hacking Lifecycle —Five Stages Of A Penetration Test

    Maltego also supports has the ability to automatically import data from social networks, DNS records, and custom plugins like FullContact.

    The important thing to remember in terms of recognisance is that you NEVER touch the target. Reconnaissance is similar to scouting and looking for information while you are far away from the target.


    This is the part where you come in contact with the target. Scanning is sending packets of data to the target and interpreting their response.

    Scanning gives you useful information about the target like open ports, IP addresses, operating system information, services installed, etc.

    Nmap is the best scanner to scan a network. Nmap will help you map out a network and provide detailed information about the target systems.

    Ethical Hacking Lifecycle —Five Stages Of A Penetration Test

    Nmap also provides a number of CLI options including scan exports that you can then import into exploitation tools.

    Nessus is another scanning tool but it is a commercial product. While Nmap will give you information about the target, Nessus will tell you how you can exploit the target by matching the vulnerabilities from the Common Vulnerabilities and Exposures database.

    OpenVas is another open-source alternative that is similar to Nessus.


    This is the part where you gain access to the system. A successful exploit should give you control of the system to at least a user level. From there you perform privilege escalation to gain root access to the target.

    When it comes to Exploitation, Metasploit is hands down the best tool in the market. It is open-source (with a commercial version as well) and is easy to work with.

    Ethical Hacking Lifecycle —Five Stages Of A Penetration Test

    Metasploit is updated frequently updated with new exploits published in the Common Vulnerabilities and Exposures (CVE) database. So you can match your scan results with the available exploits and use that exploit from Metasploit to attack the target.

    Metasploit has an advanced payload called Meterpreter. Once you have gained access to the target system, Meterpreter gives you options like opening webcams, dumping password hashes, and so on. Meterpreter also lives in the memory of the target, so it is very hard to detect.

    For example, if your scan results tell you that the target has Samba version 3.5, you can use the Samba CVE-2017–7494 Remote Code Execution Vulnerability to send a payload through Metasploit and gain access to the target system.

    Metasploit also has a GUI tool called Armitage. Armitage helps you to visualize targets and it recommends exploits by matching the vulnerabilities with the exploits database.

    Maintaining Access

    Gaining access to systems is not easy, especially on corporate networks. After all the hard work you have done to exploit a system, it won't make sense to go through the same process to exploit the target again.

    This is where maintaining access comes in. You can install backdoors, keyloggers, and other pieces of code that let you into the system whenever you want to.

    Metasploit gives you tools like keyloggers and Meterpreter backdoors to maintain access to an exploited system. You can also install custom Rootkits or Trojans after gaining access.

    A rootkit is a piece of code that lets the attacker have admin access to the system it is attached to. Rootkits can also be installed when you download files from malicious websites.

    Trojan horses are software that looks like useful software (eg. adobe photoshop) but can contain a hidden piece of malicious software. This is common among pirated software where attackers embed trojans within popular software like MS Office.


    Reporting is the final part of a penetration test. It is what differentiates between an attacker and an ethical hacker.

    Once your penetration test is complete, you summarize all the steps you have taken from recon to gaining access. This will help the organization to understand its security architecture and defend itself better.

    A report is also useful when you are working as a team. You will not be able to conduct a penetration test for a large organization alone. Reports will also make the client understand the efforts of the team and helps justify the compensation.

    Here is a sample report created after a successful penetration test.


    Cybersecurity is a great career choice, especially during these uncertain times. More devices are exposed to the network every single day. It is the job of the penetration tester to help defend an organization’s network.

    Hope this article helped you understand the different stages of a penetration test. If you have any questions, let me know in the comments.


    <![CDATA[TinyML — How To Build Intelligent IoT Devices with Tensorflow Lite]]>https://www.manishmshiva.com/tinyml-how-to-build-intelligent-iot-devices-with-tensorflow-lite/60b3a5a6bc82b4003b8727c4Mon, 31 Aug 2020 03:30:00 GMT

    When you combine large data sets with high computing power, these neural networks can understand patterns between data.

    Deep learning has given rise to self-driving cars, personal assistants like Siri, and many others. Engineers are adopting deep learning models into their applications to solve complex problems for their customers.

    Tensorflow is a leading Deep learning library developed by Google. It supports a variety of neural network models like Convolutional and Recurrent Neural Networks.

    I recently wrote an article on Machine learning called “Machine Learning For Managers — What You Need To Know”. It should give you all the basics you need.

    Embedded Systems

    If hardware scares you, don't worry. I'll make this simple.

    A microprocessor is a small computer similar to your CPU. The difference is that it is really tiny and can only perform low-level operations.

    TinyML — How To Build Intelligent IoT Devices with Tensorflow Lite

    These tiny microprocessors are present in devices like your air-conditioner and your refrigerator. But microprocessors alone cannot do much. They need input through sensors and send outputs to perform an action.

    When you press a button on your remote and change a channel on your TV, the device takes in an input, understands the command, and performs an operation. The combination of these sensors and the microprocessor is called Embedded Systems. (coz they are embedded together on a circuit board)

    Embedded systems are present in devices like your smartphone, electric guitar, and many others we use on a daily basis.

    Internet of Things (IoT)

    IoT is any device connected to the internet. If your air conditioner is connected to the internet, you can turn it on/off from your office through a mobile app. That makes it an IoT device.

    TinyML — How To Build Intelligent IoT Devices with Tensorflow Lite

    IoT devices are usually grouped together to perform various actions. A few examples would be:

    • Devices on a farm to check weeds and pests using cameras.
    • Traffic cameras for real-time monitoring
    • A network of drones to monitor a construction site.

    There are pre-built embedded systems like Raspberry Pi and Arduino that come packaged with a microcontroller, sensors, support for wifi, and even a USB port. You can connect to them using a keyword and a monitor, just like you would do with a CPU.

    TinyML — How To Build Intelligent IoT Devices with Tensorflow Lite

    What is TinyML

    Most IoT devices perform a specific task. They take input through a sensor, perform computation, and send the data out or perform an action.

    The usual approach to IoT is to collect data and send it to a centralized logging server. From here, you can use machine learning to draw conclusions.

    But why don't we make these devices intelligent at the embedded system level? We can build solutions like smart traffic signals based on traffic density, send you an alert when your refrigerator goes out of stock, or even predict rainfall based on weather data.

    The challenge with embedded systems in that they are tiny. And most of them run on battery power. Since machine learning models consume a lot of processing power, machine learning tools like Tensorflow are not well suited to build models on IoT devices.

    This is where TinyML comes in.

    TinyML can perform on-device analysis of sensor inputs with extremely low power. With hardware improvements and the advancements in TinyML tools like Tensorflow Lite, it is now possible to install intelligence in these tiny devices.

    Tensorflow Lite

    TinyML — How To Build Intelligent IoT Devices with Tensorflow Lite

    So how do you achieve TinyML? There are a few tools that help us run machine learning models on IoT devices.

    The most famous one is Tensorflow Lite. With Tensorflow Lite, you can wrap your Tensorflow models to run on embedded systems. Tensorflow Lite will give you small sized binaries capable of running on low powered embedded systems.

    Tensorflow Lite also supports major platforms including Android, iOS, Arduino, and so on.

    Python is usually the preferred language to build machine learning models. But with TensorFlow Lite, you can use C, C++ or Java to build machine learning models.

    Connecting to the network is a power-consuming operation. With Tensorflow Lite, you can deploy machine learning models without the need to connect to the internet. This also solves security concerns since embedded systems are relatively easier to exploit.

    Tensorflow Lite offers pre-trained machine learning models for common use cases. These include:

    • Object Detection — Recognizes multiple objects within an image. Supports up to 80 different classes of objects.
    • Smart RepliesGenerates smart replies, similar to interacting with a chatbot.
    • RecommendationsPersonalized recommendation systems based on user behavior.


    There are a few alternatives to Tensorflow Lite. Two strong contenders are:

    • CoreML — Apple’s library for building machine learning models on iOS devices.
    • PyTorch Mobile — Mobile version of Facebook’s deep learning library PyTorch.


    TinyML is still in its early stages. There are improvements being made in Tensorflow Lite and other TinyML frameworks to support complex machine learning models.

    It might take a couple of years before we begin to see the mainstream adoption of TinyML. But no mistake, intelligent devices are coming.



    <![CDATA[Metasploit — A Walkthrough Of The Powerful Exploitation Framework]]>https://www.manishmshiva.com/metasploit-a-walkthrough-of-the-powerful-exploitation-framework/60b3a4a4bc82b4003b87278dWed, 26 Aug 2020 03:30:00 GMTIntro to Penetration TestingMetasploit — A Walkthrough Of The Powerful Exploitation Framework

    If you are new to penetration testing, let me explain what it is before I introduce you to an exploitation tool.

    Penetration testing is hacking with permission. You might have seen cool hackers on TV attacking computer systems without getting caught. But that’s not how it works in the real world.

    If you hack someone without permission, there is a high chance that you will end up in jail. So if you are planning to learn hacking with evil intentions, I am not responsible for any damage you cause. All my articles are purely educational.

    So, if hacking is bad, why learn it in the first place? Every device on the internet is vulnerable by default unless someone secures it.

    Its the job of the penetration tester to think like a hacker and attack his or her organization’s systems. The penetration tester then informs the organization about the vulnerabilities and advises on patching them.

    Penetration testing is one of the highest-paid jobs in the industry. There is always a shortage of pen-testers since the number of devices on the internet is growing exponentially.

    I recently wrote an article on the top ten tools you should know as a cybersecurity engineer. If you are interested in learning more about cybersecurity, check out the article here.

    Right. Enough pep talk. Let’s look at one of the coolest pen-testing tools in the market — Metasploit.

    Metasploit — The Complete Framework

    Metasploit is a penetration testing framework that helps you to find and exploit vulnerabilities in systems. It gives you everything you need from scanners to third-party integrations that you will need throughout an entire penetration testing lifecycle.

    This includes reconnaissance, scanning, exploitation, privilege escalation, and maintaining access.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    Metasploit is an open-source framework written in Ruby. Metasploit is written to be an extensible framework so that if you want to build custom features using Ruby, you can easily do that via plugins.

    Rapid7, the company behind Metasploit offers a premium version of Metasploit with advanced features.

    Metasploit is also frequently updated with new exploits published in the Common Vulnerabilities and Exposures (CVE). So if a new vulnerability is found and published, you can start scanning your systems right away.

    Metasploit comes with anti-forensic and evasion tools built into it. Metasploit is also pre-installed in the Kali operating system.


    Now that you know what Metasploit is, let's look at the core concepts of Metasploit.

    Metasploit offers you a few key components to find and exploit vulnerabilities on a network. This includes exploits, payloads, auxiliaries, and so on. Let's look at each one of them in detail.


    An exploit is a piece of code that takes advantage of a vulnerability in a system. These exploits perform specific actions based on how bad the vulnerability is.

    Exploits can take advantage of software vulnerabilities, hardware vulnerabilities, zero-day vulnerabilities, and so on. Some of the common exploits include buffer overflows, SQL injections, and so on.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    Metasploit offers a number of exploits that you can use based on the existing vulnerabilities in the target system. Metasploit exploits can be classified into two types:

    • Active Exploits — Active exploits will run on a target system, exploit the system, gives you access or performs a specific task, and then exits.
    • Passive Exploits — Passive exploits will wait until the target system connects to the exploit. This approach is often used by hackers on the internet asking you to download files or software. Once you do, you connect yourself to a passive exploit running on the hacker’s computer.


    A payload is a piece of code that runs through the exploit. You use exploits to get into a system and payloads to perform specific actions.

    For example, you can use a keylogger as a payload along with an exploit. Once the exploit is successful, it will install the keylogger in the target’s system.

    Metasploit offers a good collection of payloads like reverse shells, bind shells, Meterpreter, and so on.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    There are a few payloads that will work with the majority of exploits, but it takes some research to find the right payload that will work with the exploit. Once you choose an exploit, you can list the payloads that will work with that exploit using the ‘show payloads’ command in Metasploit.

    There are a few types of payloads in Metasploit. The ones you will end up using the most are these three types:

    • Singles — Payloads that work on their own. eg. keyloggers.
    • Stagers — Payloads that work with others eg. two payloads: one to establish a connection with the target, the other to execute an instruction.
    • Meterpreter — Advanced payload that lives on the target’s memory, hard to trace, and can load/unload plugins at will. We have a section on Meterpreter where I will explain it in detail.


    Auxiliaries are modules that help you perform custom functions other than exploiting a system. This includes port scanners, fuzzers, sniffers, etc.

    For example, you can use the CERT auxiliary to check for expired SSL certificates on a network. This is useful for system administrations to automate certificate management.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    If you are familiar with Ruby, you can write your own auxiliaries. If you want to scan a network for specific vulnerabilities every week, you can write your own custom auxiliary module to do that. You can then use it to scan your network instead of using an existing scanner like Nmap.


    Now that you know how Metasploit functions, let's look at the tools that Metasploit offers.


    MsfConsole is the default interface for Metasploit. It gives you all the commands you need to interact with the Metasploit framework.

    It takes a bit of a learning curve to familiarize yourself with the CLI, but once you do, it is easy to work with. Also, MsfConsole is the only way you can access all the features of Metasploit.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    MsfConsole also offers tab-completion for common commands. Making yourself familiar with the MsfConsole is an important step in your journey to becoming a Metasploit professional.


    If you are working with large networks on a regular basis, chances are, you will need a place to store your data. This includes scan results, login credentials, and so on.

    Metasploit offers a database management tool called msfdb. msfdb works on top of a PostgreSQL database and gives you a list of useful commands to import and export your results.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    With msfdb, you can import scan results from external tools like Nmap or Nessus. Metasploit also offers a native db_nmap command that lets you scan and import results using Nmap within the msfconsole.


    Finally, we have msfvenom (cool name, huh?). msfvenom enables you to generate custom payloads depending on your target.

    Using an antivirus or a firewall can make a target system relatively secure. In those cases, existing Metasploit payloads might not work since they are generic for all systems falling under an operating system or a service.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    msfvenom was built by combining two older tools that Metsploit had: msfpayload and msfencode. msfvenom lets you create and encode custom payloads for your exploits.

    Based on the additional information you have on the target, you can craft your own payloads to achieve a higher success rate during your penetration test.


    Meterpreter is an advanced payload in Metasploit. Unlike other payloads that perform a specific function, Meterpreter is dynamic and can be scripted on the fly.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    If you can exploit a system and inject Meterpreter as the payload, here are some of the things you can do:

    • Establish an encrypted communication between your system and the target.
    • Dump password hashes from the target system.
    • Search for files on the target’s filesystem
    • Upload / Download files
    • Take webcam snapshots

    Meterpreter is also incredibly stealthy. Since Meterpreter lives in the memory of the target, it is extremely hard to detect. It is also hard to trace Meterpreter using forensic tools.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    You can write Meterpreter scripts on the fly using Ruby to carry out custom functions. Meterpreter also has a Python module that gives you additional commands to execute python scripts on the target machine.


    Armitage is a graphical user interface for Metasploit, written in Java. Armitage is considered to be a great addon for pen-testers familiar with the command-line interface.

    Metasploit — A Walkthrough Of The Powerful Exploitation Framework

    The core feature of Armitage is to visualize targets and recommend exploits. Armitage is also scriptable, which means you can automate redundant tasks like host discovery.

    Armitage is extremely useful when you are working with a large number of systems in a network. You can use Armitage’s GUI to escalate privileges, browse files, dump password hashes, and so on.


    Metasploit provides a suite of tools for you to perform a complete security audit of a network. Metasploit is frequently updated with the vulnerabilities published in the Common Vulnerabilities and Exploits database.

    You can also use other tools like Nmap and Nessus with Metasploit through integrations or by importing their scan reports into Metasploit. Metasploit also has a GUI tool called Armitage that lets you visualize targets and recommend exploits.

    If you are interested in learning more about Metasploit, check out the detailed reference guide published by Offensive Security.


    <![CDATA[Rust — Getting Started With The Most Loved Programming Language]]>https://www.manishmshiva.com/rust-getting-started-with-the-most-loved-programming-language/60b3a2f6bc82b4003b872763Thu, 20 Aug 2020 03:30:00 GMT

    Rust is a systems programming language that you can use to write applications with high performance. Rust is being used by some of the top companies like Dropbox and Cloudflare to deliver speed and concurrency to their customers.

    For the last five years in a row, Rust has been voted as the most loved programming language. But chances are, you might not have worked with Rust. Or worse, you might not have heard it before.

    Rust — Getting Started With The Most Loved Programming Language

    Why Rust?

    Let’s look at why a developer would choose Rust.

    Typical programming languages like Python and C++ abstract a lot of details from developers. If you are a junior developer working on a simple web application, this might not an issue. You just want to find a solution to a problem.

    For large scale applications that millions of users will use on a daily basis, the ‘problem-solving’ approach will not work. More users consume more system resources. And more resources mean bigger bills for your company.

    This is where Rust shines. Rust combines ease of programming with access to core system configurations. Rust is built with memory-safety, concurrency, and security from the ground up.

    Rust is a “systems programming language that focuses on speed, memory safety, and parallelism”.

    Rust is also considered to be a great alternative for C++. Rust offers high performance in addition to helping you eliminate common bugs caused by languages like C++.

    Now that you know what Rust can do for you, let's look at Rust in detail.

    Rust — Origins

    Rust is an open-source programming language. Rust was first introduced to the world in 2010 by Graydon Hoare, while he was working at Mozilla. Shortly after, Mozilla began sponsoring this project and is still a core contributor to Rust.

    Rust started gaining popularity over the years. Even Microsoft uses Rust to build secure and safety-critical software components.

    Rust — Core Features

    Let's look at some core features that make Rust stand out from other programming languages.


    Rust was build to be high performant form the ground up. Rust offers fine-grained control of memory management and has a minimal standard library.

    Rust — Getting Started With The Most Loved Programming Language

    If you look at some of the metrics shared by Figma, they had incredible improvements in performance once they switched to Rust.

    Rust’s low memory footprint also makes it an ideal choice for embedded systems programming. You can use Rust to write software for IoT devices like home automation hubs, smart security systems, etc.


    One of the major reasons Microsoft decided to root for Rust is its security. The majority of vulnerabilities in Microsoft software was due to poor memory management in C & C++. This leads to simple yet powerful exploits like the Buffer Overflow exploit that had crippled Windows for years.

    So Microsoft decided to look for the best alternative to C++. And they found Rust.

    Using Rust eliminates an entire class of security vulnerabilities from software applications. Rust helps companies build applications with better performance and higher security.


    Concurrency is when two or more tasks start, run, and complete in overlapping time. Database operations are a great example to explain concurrency.

    When thousands of users are using your application at the same time to perform different actions, your database handles them concurrently. Concurrency is a key concept when it comes to scaling applications.

    Concurrency and parallelism are also built into Rust. Rust solves most of the concurrency problems during compile time by using the concept of Ownerships. Learn how Rust handles concurrency here.

    Working With Rust

    Now that you understand the core features of Rust, let's write a few lines of code. You can find installation instructions here if you want to try out Rust on your computer.

    Let's start with a simple “Hello World!” function.

    // Main function
    fn main() {
        println!("Hello World!");

    Yep. That's pretty much it. Let's try to add two numbers.

    // Main function
    fn main() {
       let a = 100;
       let b = 200;
       println!("Result is {}",a+b);

    Again, pretty standard. Now let's look at an array operation.

    // Main function
    fn main(){
       let arr:[i32;4] = [1,2,3,4];
       println!("array size is {}",arr.len());

    If you look at line number 3, we use “:[i32;4]”. Here we tell Rust that we are declaring an array of length 4 with 32-bit integers.

    Declaring data types in detail is a key factor in improving the performance of a program. You are helping the compiler save time by explicitly declaring what type of data you are about to assign to a variable.

    Letting the compiler figure out the data type is one of the main reasons you run into performance issues while scaling your application. Also, Rust is a statically typed language, which means it must know the types of all variables at compile time.

    Though Rust is syntactically similar to C and C++, don't let its simplicity fool you. Rust does come with a steep learning curve. But it is totally worth it once you get a good grasp of the basics.

    Who Uses Rust?

    Now that you have a good grasp of what Rust is, let's look at who uses Rust.


    Rust — Getting Started With The Most Loved Programming Language

    Once a fierce adversary of open source, Microsoft is now an avid contributor to a number of open-source projects. Their .net core project is one of the most popular open-source frameworks used by developers today.

    Microsoft has chosen Rust where security and performance-critical applications. Rust is also used extensively in Azure, especially in its IoT Edge platform to run AI applications on IoT devices.


    Rust — Getting Started With The Most Loved Programming Language

    Dropbox uses Rust to improve its data center efficiency. Rust is now powering core services of Dropbox serving more than 500 million users. Dropbox recently wrote a detailed article on how they re-wrote their core engine.

    In Dropbox’s own words,


    Rust was also a contributing factor that helped Dropbox move its infrastructure from AWS to its own data centers.


    Figma is a cloud-based designing and prototyping tool that you can work using your browser. It is an excellent tool for designing, prototyping, and exporting your designs into code. Learn more about Figma here.

    Concurrency is crucial for a collaborative tool where many users will be working on a single design at a time. Figma used Rust to write a high-performance server that helped them scale their product and achieve the performance they were looking for.

    Here is the article Figma wrote about their experience with Rust.


    Rust is a systems programming language that has been voted as StackOverflow’s most loved programming languages, four years in a row. Rust gives you control over low-level details and provides remarkable improvements in speed and stability. Rust has helped companies like Dropbox, Figma, and Microsoft build better applications for their customers.

    Rust is being increasingly adopted by companies looking to scale their applications with higher performance and concurrency. Sounds interesting? Start learning Rust here.


    <![CDATA[Wireshark — A Walkthrough Of The Best Packet Analyzer In The World]]>https://www.manishmshiva.com/wireshark-a-walkthrough-of-the-best-packet-analyzer-in-the-world/60b3a28fbc82b4003b872755Sat, 15 Aug 2020 03:30:00 GMT

    Wireshark is a network analyzer that lets you see what’s happening on your network. Wireshark lets you dissect your network packets at a microscopic level, giving you in-depth information on individual packets.

    Wireshark was first released in 1998. It was called Ethereal back then. Wireshark can run on all major operating systems. Most enterprises and government organizations now prefer Wireshark as their standard network analyzer.

    Wireshark is also completely open-source, thanks to the community of network engineers around the world. While most security tools are CLI based, Wireshark comes with a fantastic user interface.

    OSI Model

    I am assuming you are new to networking, so we will go through some basics of the OSI model. This is important to understand the core functions of Wireshark.

    The Open Systems Interconnection (OSI) model standardizes the way two or more devices connect with each other. The OSI Model segments network architecture into 7 layers: Application, Presentation, Session, Transport, Network, Datalink, and Physical.

    Here is what each layer does:

    • Physical Layer — Responsible for the actual physical connection between devices. Data is transferred in the form of bits.
    • Data Link Layer- Makes sure the data is error-free. Data is transferred in frames.
    • Network Layer — Takes care of finding the best (and quickest) way to send the data. Sender’s and receiver’s IP addresses are added to the header at this layer.
    • Transport Layer — Acts as a bridge between the network and session layer. Uses protocols like TCP and UDP to send and receive data. Data at this layer is called a Segment.
    • Session Layer — Establishes and maintains a session between devices.
    • Presentation Layer — Data from segments are converted to a more human-friendly format here. Takes care of encryption and decryption.
    • Application Layer — The layer that interacts with the user. If you are using a browser, it is on the application layer.

    The below diagram should help you to understand how these components work together.

    Wireshark — A Walkthrough Of The Best Packet Analyzer In The World

    If you are interested in learning more about the OSI model, here is a detailed article for you.


    Now that you have a solid grasp of the OSI model, let’s look at network packets. When data is transferred from one computer to another, the data stream consists of smaller units called packets.

    When you download a file from the internet, the data is sent from the server as packets. These packets are re-assembled by your computer to give you the original file.

    Wireshark — A Walkthrough Of The Best Packet Analyzer In The World

    A packet can contain the following data:

    • source and destination IP addresses
    • protocol
    • source and destination ports
    • Data
    • Length, flags, TTL, etc.

    Each packet contains valuable information about the devices involved in a packet transfer. Each data transfer involves thousands or even millions of these packets of data being sent between the source and the destination devices.

    Now you would have understood the importance of Wireshark. Wireshark lets you capture each of these packets and inspect them for data.

    Wireshark, to a network engineer, is similar to a microscope for a biologist. Wireshark lets you ‘listen’ to a live network (after you establish a connection to it), capture and inspect packets on the fly.

    As a network engineer or ethical hacker, you can use Wireshark to debug and secure your networks. As a bad guy (which I don’t recommend), you can ‘sniff’ packets in the network and capture information like credit card transactions.

    This is why it is unwise to connect to a public network like Starbucks and perform financial transactions or access private data. Even though sites with HTTPS can encrypt your packets, it is still visible over the network. If someone really wants to crack it, they can.

    Wireshark Basics

    Now let's look at how you can play with Wireshark. Download and install Wireshark from here.

    Wireshark has an awesome GUI, unlike most penetration testing tools. Here’s how Wireshark looks when you load it.

    Wireshark — A Walkthrough Of The Best Packet Analyzer In The World

    Wireshark lists out the networks you are connected to and you can choose one of them and start listening to the network.

    Wireshark — A Walkthrough Of The Best Packet Analyzer In The World

    There are three panes in Wireshark.

    Packet List Pane

    Wireshark — A Walkthrough Of The Best Packet Analyzer In The World

    This pane displays the packets captured. Each line represents an individual packet that you can click and analyze in detail using the other two panes.

    Packet Details Pane

    Wireshark — A Walkthrough Of The Best Packet Analyzer In The World

    You can select a packet and then look at the packet information in more detail using the Packet Details pane. It displays information such as IP addresses, ports, and other information contained within the packet.

    Packet Bytes Pane

    Wireshark — A Walkthrough Of The Best Packet Analyzer In The World

    This pane gives the raw data of the selected packet in bytes. The data is displayed as a hex dump, which is displaying binary data in hexadecimal.


    Wireshark has filters that help you to narrow down the type of data you are looking for. There are two main types of filters: Capture filter and Display filter.

    Capture Filter

    You can set a capture filter before starting to analyze a network. When you set a capture filter, it only captures the packets that match the capture filter.

    For eg, if you only need to listen to the packets being sent and received from an IP address, you can set a capture filter as follows.


    Once you set a capture filter, you cannot change it till the current capture session is completed.

    Display Filters

    Display filters are applied to capture packets. For example, if you want to display only the requests originating from a particular ip, you can apply a display filter as follows:


    Since display filters are applied to captured data, they can be changed on the fly.

    In short, capture filters enable you to filter the traffic while display filters apply those filters on the captured packets. Since Wireshark can capture hundreds of packets on a busy network, these are useful while debugging.

    Core Features of Wireshark

    Now that you have a good grasp of Wireshark basics, lets look at some core features. With Wireshark, you can:

    • Identify security threats and malicious activity on a network
    • Observe network traffic for debugging complex networks
    • Filter traffic based on protocols, ports and other parameters
    • Capture packets and save it to a Pcap file for offline analysis
    • Apply coloring rules to the packet list for better analysis
    • Export captured data to XML, CSV, or plain text file.


    Wireshark is always ranked among the top 10 network security tools every year. With its simple yet powerful user interface, Wireshark is easy to learn and work with. It is a valuable asset in every penetration tester’s toolkit.

    Hope this article helped you to get a solid grasp of Wireshark. I recently wrote an article on the top 10 tools you should know as a cybersecurity engineer. Do check it out if you are into cybersecurity.


    <![CDATA[Machine Learning For Managers — What You Need To Know]]>https://www.manishmshiva.com/machine-learning-for-managers-what-you-need-to-know/60b3a18abc82b4003b872728Thu, 13 Aug 2020 03:30:00 GMT

    Machine learning and deep learning have been popular buzz words for the last five years. The demand for .ai domains has skyrocketed. But beyond all the hype surrounding machine learning, it is hard to grab the basic concepts with ease if you are an absolute beginner.

    AI and machine learning gained so much popularity in the last five years. Almost every product can have a machine learning use case now. Let’s look at machine learning in-depth and equip you with the knowledge you need for your next technical conversation.

    What is Machine Learning?

    Machine learning is a branch of Artificial Intelligence. Artificial Intelligence as a whole includes many general concepts to simulate human thinking. Machine learning focuses only on one key aspect: Making machines learn.

    Machine learning is the science of getting computers to make decisions without being explicitly programmed.

    In the past decade, machine learning has given us self-driving cars, face recognition, chatbots, and many other useful applications. Machine learning is powering so many tools that we use on a daily basis.

    How Does Machine Learning Work?

    Machine learning uses algorithms to analyze massive amounts of data and draw conclusions from it. When you combine large data sets with high computing power, these algorithms can understand patterns and relationships between data.

    For eg, lets look at a simple dataset

    x = 1,2,3,4,5

    y = 1,4,9,16,25

    It is obvious to someone that the relationship between x and y is that y is a square of x. i.e y = x2

    In machine learning, the job of an algorithm is to find this function that defines the relationship between the input and output. Once this function has been established, it is easy to predict future values.

    eg. if x is 10, y is 100.

    Though this example is too simple, it should give you an idea of how machine learning models work.

    Consider a complex dataset like predicting housing prices.

    Machine Learning For Managers — What You Need To Know

    This dataset will contain area codes, square foot, and many other inputs with the price as the output. If you have a dataset with thousands of these inputs features and the final price, you can train a model to predict the average price based on new inputs.

    Machine learning problems usually involve finding the relationship between the inputs and outputs to find the ‘hypothesis function’. In our earlier example, the hypothesis function was y = x².

    Real-world hypothesis functions are much more complex than this. We then use that function to find answers for custom inputs.

    In a nutshell, machine learning, in most cases, is advanced statistics combined with computational capacity. Today, Machine learning powers technologies like facial recognition, sentiment analysis, and many others.

    Types of Learning Algorithms

    Let's look at the type of problems you will come across when working with machine learning. Firstly, there are three ways by which you can make machines learn.

    Machine Learning For Managers — What You Need To Know

    Supervised Learning

    In supervised learning, you provide clear inputs to a machine learning algorithm. The algorithm knows what to learn from the data and the conclusions expected from it.

    For eg. for recognizing the difference between a cat and a dog, you train an algorithm with thousands of images. Each of these images will be labeled accordingly.

    Once you run this data through the algorithm, the algorithm learns and understands the differences. Thus, it can predict, with reasonable accuracy, whether a new image is a cat or a dog.

    Unsupervised Learning

    Labeling data is important to build a supervised model. However, companies collect large datasets on a daily basis. Labeling these datasets to make the job of a machine learning model easier is not an elegant way to approach this problem.

    This is where unsupervised learning comes in. You can use unsupervised learning algorithms to cluster data based on available attributes. This data can then be fed into supervised learning models to achieve higher prediction accuracy.

    Unsupervised learning models are more challenging than supervised learning models. You can find more information and examples here.

    Reinforcement Learning

    No machine learning algorithm is 100% accurate. The level of accuracy depends on the dataset you train the algorithm with.

    This means that after you train an algorithm, there can be new datasets available. These datasets might have the potential to improve the accuracy of your model considerably.

    You can use reinforcement learning for these types of scenarios. Reinforcement learning is the concept of updating the algorithm while it is in production. Reinforcement learning models can retrain based on new inputs.

    For example, a self-driving car can learn about a new type of terrain after it has traveled through one. this will be taken into account by the self-driving car’s algorithm the next time it has to choose a route.

    Types of Machine Learning Problems

    Machine Learning problems can be classified into four subcategories based on the type of result you are looking for.


    Classification models produce a result that belongs to a finite set. Examples of classification models include spam/not spam, 0 or 1 (binary classification), positive/negative/neutral, etc.


    Regression models produce results that belong to a range. Examples include predicting stock market prices, weather forecasting, etc. These are not limited to a finite set of values and hence are called regression problems.


    Clustering is a key concept in unsupervised learning. Clustering helps you group data that have similar attributes. Once these groups have been established, it becomes easier to train them using supervised models. Learn more about clustering here.

    Dimensionality Reduction

    Dimensionality Reduction is another unsupervised learning technique. Using Dimensionality reduction, you can reduce a complex dataset with thousands of features into a simple one with maybe a hundred inputs.

    Similar to clustering, Dimensionality reduction is often used to reduce noise from large datasets before feeding them into supervised training models. You can find a more in-depth article on Dimensionality reduction here.

    What is Deep Learning?

    Machine Learning For Managers — What You Need To Know

    Deep learning is Machine learning on steroids.

    There are many algorithms in machine learning. One that stands out is a Neural Network.

    The difference between other machine learning algorithms and a neural network is that you can stack neural networks together — as many as you want.

    This helps us solve complex problems like facial recognition and self-driving since these types of problems come with thousands of inputs in real-time. Using neural networks, you can solve almost any complex problem with high accuracy, if you have the data and computing power needed for the model to run.

    Neural Networks have been around for decades but it was the availability of large datasets and computing power that bought it back to life. Now deep learning is one of the most exciting fields in the industry.

    Why Do You Need Machine Learning?

    Let's look at some popular machine learning solutions that we use every day.

    Voice assistants

    Machine Learning For Managers — What You Need To Know

    Ever wondered how Siri can understand and interpret your voice commands? The answer is machine learning. You can find a voice assistant in almost every smartphone now, thanks to the advancements in Natural Language Processing.

    Even though it is hard for computers to understand natural language, thanks to machine learning, we have Alexa, Cortana, and Siri.

    Product recommendations

    Machine Learning For Managers — What You Need To Know

    Recommendation engines are a profitable use case for e-commerce companies. If you can find the right products to recommend, chances are your customer will make multiple purchases.

    Machine learning algorithms can understand user behavior from past purchases. This helps them recommend similar products when a customer is shopping on your website.

    Recommendations are not limited to e-commerce. This applies to products like Spotify or Netflix that recommend the music or movies you like.


    Machine Learning For Managers — What You Need To Know

    Customer support can make or break your company, especially if you are a startup. The more number of users you attract, the more customer support you have to provide.

    Chatbots are a huge time saver when it comes to interacting with customers. Since the majority of your customers will have common questions, you can design a chatbot that can answer redundant questions.

    You don't have to employ additional customer service professionals or make your customers wait in a queue. Chatbots are saving businesses time and money, thanks to Machine Learning.

    Spam filtering

    Machine Learning For Managers — What You Need To Know

    Spam filtering is a simple yet powerful application of Machine Learning. It is the reason why Gmail or Outlook can filter out spam emails for you with high accuracy.

    Spam filtering systems are also built to learn from experience. This model, also called reinforcement learning, can understand your preferences better when you mark an email as spam.

    We now have cleaner inboxes, thanks to Machine Learning.

    Language translation

    Machine Learning For Managers — What You Need To Know

    What would we do without Google Translate! Machine learning-based language translation engines save businesses millions every year.

    Before machine learning, translation services were entirely human-powered. Thanks to machine learning, you can translate large data sets to any language in a matter of mere minutes.

    Tools and Frameworks

    Machine learning and deep learning are accomplished by using different libraries and frameworks. Though other languages have their own tools, Python is usually the preferred language for machine learning.

    Here are a few Python frameworks you can use to build your next machine learning or deep learning product.

    Machine Learning For Managers — What You Need To Know
    • Scikit — Popular for machine learning problems. Great community support. Not suitable for complex deep learning models.
    • Tensorflow — Most popular deep learning framework. Built by Google. Supports all complex deep learning models like CNNs and RNNs
    • PyTorch — Built by Facebook, scalable, and offers high performance.

    I recently wrote a blog post on popular deep learning frameworks if you are more interested.


    Machine learning has the potential to transform every industry. From voice assistants to self-driving cars, the applications of machine learning are all around us today. It can help you understand your customers better and make smarter decisions with data.

    Hope this article helped you get a good grasp of machine learning and deep learning concepts. If you are fascinated by machine learning as much as I do, check out the Machine Learning course on Coursera by Prof. Andrew Ng.


    <![CDATA[Everything you need to know about AWS S3]]>https://www.manishmshiva.com/everything-you-need-to-know-about-aws-s3/60b3a0f7bc82b4003b872713Tue, 11 Aug 2020 03:30:00 GMT

    If you have ever worked as a developer, you would have come across file storage use cases. From simple images to large videos, uploading, storing, and accessing those files back when you need them is always tricky to implement.

    The usual answer to file storage is the same server where you host your web application. But with the advent of serverless architectures and single-page applications, storing files on the same server is not a good idea.

    You could argue that you can store files in databases. Trust me, it won’t be a pleasant experience.

    What is S3?

    Let's look at AWS S3. S3 is an easy-to-use, scalable, and cheap storage service from Amazon. You can use S3 to store any amount of data for a wide range of use cases.

    Static website hosting, data archival, and software delivery are a few general scenarios where S3 would be a perfect tool. You can easily push and pull data with S3 using the AWS SDK.S3 also supports a good number of popular programming languages, so you can use your existing stack and integrate S3 pretty easily.

    Everything you need to know about AWS S3
    AWS Management Console

    S3 also offers a great user interface via the AWS console. You can use it to view the data pushed to S3 along with additional options such as security and version control.


    In S3, files are stored in buckets. Buckets are similar to folders on your computer.

    Every bucket has its own unique name which can be used only once. For eg, if there is a bucket called “freecodecamp”, neither you nor anyone else can re-use the same bucket name.

    This is useful to uniquely identify resources and for static website hosting with domain names.

    There are no limits on the number of files you can store in a bucket. Buckets also provide additional features such as version control and policies.

    You can also use different buckets for a single application. For example, an app that stores medical records can use two buckets. One for private customer data and another public bucket that contains whitepapers.

    S3 is also an object-based storage service which means S3 considers each file as an object. Every object can have its own metadata that includes the name, size, date, and other information.

    S3 Storage Types

    S3 has three storage classes based on general use cases.

    S3 Standard

    S3 Standard is the default storage plan you will be put into when you start using S3. The standard storage class has excellent performance, durability, and availability. S3 Standard is best if you have data that you have to access frequently.

    S3 Infrequent Access (S3-IA)

    S3 Infrequent Access offers a lower price for data compared to the standard plan. You can use S3-IA for data that is needed less often. S3-IA is great for use cases such as backups and disaster recovery


    Glacier is the least expensive storage option in S3 but is designed for archival storage. You cannot fetch data from Glacier as fast as Standard or S3-IA, but it is a great option for long term data archival.

    In addition to choosing one of these three storage classes, you can also set lifecycle policies in S3. This means that you can schedule files to be moved automatically to S3-IA or Glacier after a certain period of time.

    Why S3?

    Companies like Netflix, Dropbox, and Reddit are avid users of S3. The popular file storage system Dropbox built its entire storage capacity on top of Amazon S3. Let’s look at some of the core features of S3 and understand why S3 is popular among enterprises and startups alike.


    S3 is cheap. I mean super cheap compared to other storage solutions. And with S3, you only pay for what you use. There is no upfront costs, no setup. Its just plug and play.

    In addition to affordable pricing, S3 offers a Free tier. This free tier comes with 5GB of storage space, 20,000 GET Requests, 2,000 PUT, COPY, POST, or LIST Requests and 15GB of Data Transfer. The free tier is available every month for the first year.

    With S3 you can avoid paying for space or bandwidth you might not even need.


    S3 scales with your application. Since you pay only for that you use, there is no limit to the data you can store in S3.

    This is helpful during multiple scenarios, especially during an unexpected surge in user growth. You don’t have to buy extra space. S3 has you covered.


    One of the many reasons companies prefer S3 is its inclination to security. While you have to secure custom server setups, S3 is secure by default.

    This does. not mean you cannot store publicly accessible information in S3. S3 locks up all your data with high security unless you explicitly configure not to.

    S3 also maintains compliance programs, such as PCI-DSS, HIPAA/HITECH, FedRAMP, EU Data Protection Directive, and FISMA, to help you meet your industry’s regulatory requirements.


    Versioning is keeping multiple copies of a file and track changes over time. This is useful, especially when you handle sensitive data.

    You can also retrieve accidentally deleted files when you enable versioning with S3.

    However, if you enable versioning, you are storing multiple copies of the same document. This can have an effect on pricing as well as read/write requests you make. You should take that into account while integrating versioning for your application.

    Versioning is disabled by default for S3 but you can enable versioning using the AWS Console.


    Data durability is an underrated feature of S3. Given how common data loss is among companies, data durability is a core factor to consider when building enterprise software.

    S3 provides a highly durable storage infrastructure. S3 redundantly stores data in multiple facilities, making you data safe in the event of a system failure. S3 also performs regular data integrity checks to make sure your data is intact.

    S3 offers 99.999999999% durability (called the 9s durability) and 99.99% availability of objects over a given year.

    S3 Use Cases

    Static Website Hosting

    You can use S3 as a static website hosting platform. The difference between static and dynamic websites is that dynamic websites receive and process user input. Static websites are used only for displaying information.

    With the advent of Single Page Applications, you can host a complete web app on S3, often free of charge. Frameworks like React and Angular have made user input processing happen within the browser. You can build a SPA that listens to third party APIs and host it within S3. S3 also has great support for routing, so you can use your own custom domain as well.

    I recently wrote an article on hosting a react web app using S3 and you can find the article here.


    You can run queries on your S3 data without moving your data to an analytics platform. This makes S3 a great use case for building powerful analytics applications.

    S3 offers multiple options including S3 Select, Amazon Athena, and Amazon Redshift Spectrum. You can also combine these with AWS Lambda to perform data processing on the fly.

    File Sharing

    Amazon S3 can be also used as a cheap file sharing solution. Like I mentioned earlier in the article, the famous file sharing service Dropbox was first built on top of S3.

    With flexible security policies, you can configure your S3 buckets with custom permissions for different customers. S3 also offers transfer acceleration to speed up large file transfers across longer distances.


    Amazon S3 is a great tool to work with for your web or mobile application storage requirements. With on-demand pricing and scalability at its core, S3 has been the favored cloud storage solution for small and large businesses alike.

    Companies from Netflix to Pinterest trust S3 with their data, thanks to the 99.999999999% data durability promise from Amazon. You can also use Amazon S3 as a personal storage solution or host your next project via static site hosting. In a nutshell, S3 is a great multi-purpose storage solution catering to a wide range of use cases.


    <![CDATA[10 Tools You Should Know As A Cybersecurity Engineer]]>https://www.manishmshiva.com/10-tools-you-should-know-as-a-cybersecurity-engineer/60b39f9abc82b4003b8726cdFri, 07 Aug 2020 03:30:00 GMTIntroduction10 Tools You Should Know As A Cybersecurity Engineer

    Being a cybersecurity engineer means being responsible for an entire network. This network includes computers, routers, mobiles, and everything that connects to the internet.

    Thanks to the rise of Internet of Things, we see more and more devices connecting to the internet every day. Services like Shodan are proof of how dangerous it is to have an internet-connected device without adequate security.

    We cannot rely on Antivirus software either, given how sophisticated today’s hackers are. Besides, most attacks nowadays use social engineering as their entry point. This makes it even harder for cybersecurity professionals to detect and mitigate these attacks.

    Covid-19 has become another major catalyst for growing cyber-attacks. Employees working from home don’t have access to the same enterprise-level security architectures in their workplace.

    Growing cyber-attacks have also increased the demand for cybersecurity professionals around the world. Due to this increasing demand, Cybersecurity has been attracting a lot of experts as well as beginners.

    For those of you who are new to Cybersecurity, hacking is not as cool as it looks on TV. And there is a high probability that you will end up in jail.

    However, being a penetration tester or a white hat hacker is different — and beneficial — since you will be playing with the same tools black hat hackers (the bad ones) play with. Except for this time, it’s legal, and your goal is to help companies discover security vulnerabilities so they can fix them.

    You can learn more about the types of hackers here.

    It is always hard to find the right tools to get started in any domain, especially if you are a beginner. So here are 10 tools to get you started as a cybersecurity engineer.



    10 Tools You Should Know As A Cybersecurity Engineer

    Having a solid foundation in Networking is essential to becoming a good penetration tester. After all, the internet is a bunch of complex networks that communicate with each other. If you are new to Networking, I recommend this playlist by Network Direction.

    Wireshark is the world’s best network analyzer tool. It is an open-source software that enables you to inspect real-time data on a live network.

    Wireshark can dissect packets of data into frames and segments giving you detailed information about the bits and bytes in a packet. Wireshark supports all major network protocols and media types. Wireshark can also be used as a packet sniffing tool if you are in a public network. Wireshark will have access to the entire network connected to a router.

    10 Tools You Should Know As A Cybersecurity Engineer

    Sites like Facebook and Twitter are encrypted now, thanks to https. This means that even though you can capture packets from a victim computer in transit to Facebook, those packets will be encrypted. Still, being able to capture data packets in realtime is an important utility for a penetration tester.


    10 Tools You Should Know As A Cybersecurity Engineer

    Nmap is the first tool you will come across when you begin your career as a penetration tester. Nmap is a fantastic network scanning tool that can give you detailed information about a target. This includes open ports, services, and the operating system running on the victim’s computer.

    Nmap is popular among penetration testers for many reasons. It is simple, flexible, and extensible. It offers a simple command-line interface where you can add a few flags to choose different types of scans. Nmap offers simple ping scans to aggressive scans that provide detailed ports and service information.

    10 Tools You Should Know As A Cybersecurity Engineer

    Nmap also provides a GUI tool called Zenmap with added utilities. You can build visual network maps and choose scans via dropdowns. Zenmap is a great place to start playing with Nmap commands if you are a beginner.

    I recently wrote a detailed article on Nmap and you can read it here.

    Ncat (Previously Netcat)

    10 Tools You Should Know As A Cybersecurity Engineer

    Netcat is often referred to as the swiss-army knife in networking.

    Netcat is a simple but powerful tool that can view and record data on a TCP or UDP network connections. Netcat functions as a back-end listener that allows for port scanning and port listening.

    You can also transfer files through Netcat or use it as a backdoor to your victim machine. This makes is a popular post-exploitation tool to establish connections after successful attacks. Netcat is also extensible given its capability to add scripting for larger or redundant tasks.

    In spite of the popularity of Netcat, it was not maintained actively by its community. The Nmap team built an updated version of Netcat called Ncat with features including support for SSL, IPv6, SOCKS, and HTTP proxies.


    10 Tools You Should Know As A Cybersecurity Engineer

    If there is one tool I love, its Metasploit. Metasploit is not just a tool, but a complete framework that you can use during an entire penetration testing lifecycle.

    Metasploit contains exploits for most of the vulnerabilities in the Common Vulnerabilities and Exposure database. Using Metasploit, you can send payloads to the target system and gain access to it through a command-line interface.

    Metasploit is very advanced with the ability to do tasks such as port scanning, enumeration, and scripting in addition to exploitation. You can also build and test your own exploit using the Ruby programming language.

    Metasploit was open-source till 2009 after which Rapid7 acquired the product. You can still access free community edition for free and use all its features.

    10 Tools You Should Know As A Cybersecurity Engineer

    Metasploit used to be a purely command-line tool. A Java-based GUI called Armitage was released in 2013. Offensive Security has an in-depth tutorial on Metasploit if you are interested.


    10 Tools You Should Know As A Cybersecurity Engineer

    Nikto is an open-source tool that is capable of performing extensive web server scans. Nikto can help you scan for harmful files, misconfigurations, outdated software installations, etc.

    It also checks for the presence of multiple index files, HTTP server configurations, and the installed web server software.

    Nikto is the preferred tool for general web server security audits. Nikto is fast, but not quiet. You can scan a large web server pretty quickly but intrusion detection systems will easily pick up these scans. However, there is support for anti-IDS plugins in case you want to perform stealthy scans.

    Burp Suite

    10 Tools You Should Know As A Cybersecurity Engineer

    When it comes to pen-testing web applications, Burpsuite has all the answers for you. BurpSuite aims to be an all in one set of tools for a variety of web application pen-testing use cases. It is also a popular tool among professional web app security researchers and bug bounty hunters.

    Burpsuite’s tools work together to support the entire web application testing lifecycle. From scanning to exploitation, Burpsuite offers all the tools you need for breaking into web applications.

    One of Burp Suite’s main features is its ability to intercept HTTP requests. HTTP requests usually go from your browser to a web server and then the web server sends a response back. With Burp Suite, you can perform Man-in-the-middle operations to manipulate the request and response.

    Burpusite has an excellent user interface. Burpsuite also has tools for automation to make your work faster and more efficient.

    In addition to its default features, Burpsuite is extensible by adding plugins called BApps.

    John the Ripper

    10 Tools You Should Know As A Cybersecurity Engineer

    Passwords are still the de-facto standard of authentication in most systems. Even if you successfully get into a server or a database you will have to decrypt the password to gain privilege escalation.

    John the Ripper is a simple tool used for cracking passwords. It is a super-fast password cracker with support for custom wordlists. It can run against most types of encryption methods like MD5 and SHA.


    10 Tools You Should Know As A Cybersecurity Engineer

    Aircrack-ng is a set of tools that help you to work with wireless networks. Aircrack comprises of tools that can capture wireless networks, crack WPA keys, inject packets, etc.

    A few tools in Aircrack-ng suite include:

    • airodump — Captures packets
    • aireplay — Packet injection
    • aircrack — Crack WEP and WPA
    • airdecap — Decrypt WEP and WPA

    Aircrack contains excellent algorithms for cracking WiFi passwords and to capture wireless traffic. It can also decrypt encrypted packets, making it a complete suite of tools for wireless penetration testing. In short, you can use Aircrack for monitoring, attacking, and debugging all types of wireless networks.


    10 Tools You Should Know As A Cybersecurity Engineer

    Nessus is a popular enterprise vulnerability scanner. Nessus is built to be a complete vulnerability analysis and reporting tool. While you can scan and find ports or services using Nmap, Nessus will tell you the list of vulnerabilities and how they can be exploited.

    Nessus has an excellent user interface, tens of thousands of plugins, and supports embedded scripting. Nessus is favored by enterprises since it helps companies audit for various compliances like PCI and HIPPA. Nessus will also tell you the severity of the vulnerabilities so that you can focus on those threats accordingly.

    10 Tools You Should Know As A Cybersecurity Engineer

    Nessus is not a free software but offers a limited free home edition. Nessus has an open-source alternative called Open-Vas that offers similar features to Nessus.


    10 Tools You Should Know As A Cybersecurity Engineer

    Snort is an open-source software for detecting and preventing intrusions in a network. It can perform live traffic analysis and log incoming packets to detect port scans, worms, and other suspicious behavior.

    Snort is used for defense compared to most of the other tools in this list. However, snort helps you understand the attacker’s methods by logging their activity. You can also build DNS sinkholes to redirect attacker traffic while finding attack vectors through Snort.

    Snort also has a web-based GUI called BASE (Basic Analysis and Security Engine). BASE provides a web front-end to query and analyze the alerts coming from Snort.


    In today’s networked world, everyone from government agencies to banks stores critical information in the cloud. Cyber-attacks even have the potential to cripple an entire nation. Hence, protecting these networks is not an optional choice, but an absolute necessity.

    Whether you are a beginner or an experienced cybersecurity engineer, you will find these ten tools invaluable. Good luck on your journey to becoming a successful penetration tester. Learn more tools from the Security Tools Directory.


    <![CDATA[A Detailed Comparison Of The Popular Deep Learning Frameworks]]>https://www.manishmshiva.com/a-detailed-comparison-of-the-popular-deep-learning-frameworks/60b39e3dbc82b4003b872697Mon, 27 Jul 2020 03:30:00 GMT

    Deep Learning is a branch of Machine Learning. Though machine learning has various algorithms, the most powerful are the neural networks. Deep learning is the technique of building complex multi-layered neural networks. This helps us solve tough problems like image recognition, language translation, self-driving, etc.

    There are tons of real-world applications of deep learning from Tesla cars to AI assistants like Siri. To build these neural networks, we use different frameworks like Tensorflow, CNTK, and MxNet. If you are new to deep learning, start here.


    Without the right framework, constructing quality neural networks can be hard. With the right framework, you only have to worry about getting your hands on the right data. That doesn’t imply that knowledge of the deep learning frameworks alone is enough to make you a successful data scientist.

    You need a strong foundation of the fundamental concepts to be a successful deep learning engineer. But the right framework will make your life easier.

    Also, not all programming languages have their own machine learning / deep learning frameworks. This is because not all programming languages have the capacity to handle machine learning problems. Languages like Python stand out among others due to their complex data processing capability.

    Let's go through some of the popular deep learning frameworks in use today. Each one comes with its own set of advantages and limitations. It is important to at least a basic understanding of these frameworks to choose the right one for your organization.


    A Detailed Comparison Of The Popular Deep Learning Frameworks

    TensorFlow is the most famous deep learning library around. If you are a data scientist, you would have started with Tensorflow. It is one of the most efficient open-source libraries to work with. Google built TensorFlow to use as an internal deep learning tool before open-sourcing it. TensorFlow powers a lot of useful applications including Uber, Dropbox, and Airbnb.

    Advantages of Tensorflow

    • User Friendly. Easy to learn if you are familiar with Python.
    • Tensorboard for monitoring and visualization. It is a great tool to see your deep learning models in action.
    • Community support. Experts engineers from Google and other companies improve TensorFlow almost on a daily basis.
    • You can use TensorFlow Lite to run TensorFlow models on mobile devices.
    • Tensorflow.js enables you to run real-time deep learning models on the browser using javascript.

    Limitations of Tensorflow

    • TensorFlow is a bit slow compared to frameworks like MxNet and CNTK.
    • Debugging can be challenging.
    • No support for OpenCL.

    Apache MXNet

    A Detailed Comparison Of The Popular Deep Learning Frameworks

    MXNet is another popular Deep Learning framework. Founded by the Apache Software Foundation, MXNet supports a wide range of languages like JavaScript, Python, and C++. MXNet is also supported by Amazon Web Services to build deep learning models. MXNet is a computationally efficient framework used in business as well as in academia.

    Advantages of Apache MXNet

    • Efficient, scalable, and fast.
    • Supported by all major platforms.
    • It provides GPU support, along with multi-GPU mode.
    • Support for programming languages like Scala, R, Python, C++, and Javascript.
    • Easy model serving and high-performance API.

    Disadvantages of Apache MXNet

    • Compared to TensorFlow, MXNet has a smaller open source community.
    • Improvements, bug fixes, and other features take longer due to a lack of major community support.
    • Despite being widely used by many organizations in the tech industry, MxNet is not as popular as Tensorflow.

    Microsoft CNTK

    A Detailed Comparison Of The Popular Deep Learning Frameworks

    Large companies usually use Microsoft Cognitive Toolkit (CNTK) to build deep learning models. Though created by Microsoft, CNTK is an open-source framework. It illustrates neural networks in the form of directed graphs by using a sequence of computational steps. CNTK is written using C++, but it supports various languages like C#, Python, C++, and Java.

    Microsoft’s backing is an advantage for CNTK since Windows is the preferred operating system for enterprises. CNTK is also heavily used in the Microsoft ecosystem. Popular products that use CNTK are Xbox, Cortana, and Skype.

    Advantages of Microsoft CNTK

    • CNTK offers reliable and excellent performance.
    • The scalability of CNTK has made it a popular choice in many enterprises.
    • CNTK has numerous optimized components.
    • It is easy to integrate with Apache Spark, an analytics engine for data processing.
    • CNTK works well with Azure Cloud, both being backed by Microsoft.
    • Resource usage and management are efficient in CNTK.

    Disadvantages of Microsoft CNTK

    • Minimal community support compared to Tensorflow but has a dedicated team of Microsoft engineers working full time on CNTK.
    • Significant learning curve.


    A Detailed Comparison Of The Popular Deep Learning Frameworks

    PyTorch is another popular deep learning framework. Facebook developed Pytorch in its AI research lab (FAIR). Pytorch has been giving a tough competition to Google’s Tensorflow.

    Pytorch supports both Python and C++ to build deep learning models. Released 3 years ago, it has already been in use by companies like Salesforce, Facebook, and Twitter.

    Image Recognition, Natural Language Processing, and Reinforcement Learning are some of the many areas in which PyTorch shines. It is also used in research by universities like Oxford and organizations like IBM.

    PyTorch is also a great choice for creating computational graphs. Moreover, it supports cloud software development and offers useful features, tools, and libraries. It also works well with cloud platforms like AWS and Azure.

    Advantages of PyTorch

    • PyTorch has a user-friendly design and structure that makes constructing deep learning models transparent.
    • PyTorch has useful debugging tools like PyCharm debugger.
    • It contains many pre-trained models and supports distributed training.

    Disadvantages of PyTorch

    • PyTorch does not have interfaces for monitoring and visualization like TensorFlow.
    • Comparatively, PyTorch is a new deep learning framework and currently has less community support.


    A Detailed Comparison Of The Popular Deep Learning Frameworks

    DeepLearning4j is an excellent framework if your main programming language is Java. It is a commercial-grade, open-source, distributed deep-learning library. Deeplearning4j supports all major types of neural network architectures like RNNs and CNNs.

    Deeplearning4j is written for Java and Scala. It also integrates well with Hadoop and Apache Spark. Deeplearning4j also has support for GPUs, making it a great choice for java based deep learning solutions.

    Advantages of DeepLearning4j

    • It is scalable and can easily process large amounts of data.
    • Easy integration with Apache Spark.
    • Excellent community support and documentation.

    Disadvantages of DeepLearning4j

    • Limited to the Java programming language.
    • Relatively less popular compared to Tensorflow and PyTorch.


    Each framework comes with its list of pros and cons. Choosing the right framework is crucial to the success of a project. You have to consider various factors like security, scalability, and performance. For enterprise-grade solutions, reliability becomes another primary contributing factor.

    If you are just getting started, begin with Tensorflow. If you are building a windows based enterprise product, choose CNTK. If you prefer Java, choose DL4J.

    I hope this article helps you choose the right deep learning framework for your next project. If you have any questions, let me know in the comments.


    <![CDATA[A Complete Guide To Sentiment Analysis And Its Applications]]>https://www.manishmshiva.com/a-complete-guide-to-sentiment-analysis-and-its-applications/60b39690bc82b4003b872667Sat, 25 Jul 2020 03:30:00 GMTIntroductionA Complete Guide To Sentiment Analysis And Its Applications

    Sentiment analysis is a technique through which you can analyze a piece of text to determine the sentiment behind it. It combines machine learning and natural language processing (NLP) to achieve this. Using basic Sentiment analysis, a program can understand if the sentiment behind a piece of text is positive, negative, or neutral.

    It is a powerful technique in Artificial intelligence that has important business applications. For example, you can use Sentiment analysis to analyze customer feedback. You can collect customer feedback through various mediums twitter, Facebook, etc. and run sentiment analysis algorithms on them to understand your customer ‘s attitude towards your product.

    How Sentiment Analysis Works

    The simplest implementation of sentiment analysis is using a scored word list. For example, AFINN is a list of words scored with numbers between minus five and plus five. You can split a piece of text into individual words and compare them with the word list to come up with the final sentiment score.

    eg. I love cats, but I am allergic to them.

    In the AFINN word list, you can find two words, “love” and “allergic” with their respective scores of +3 and -2. You can ignore the rest of the words (again, this is very basic sentiment analysis). Combining these two, you get a total score of +1. So you can classify this sentence as mildly positive.

    There are complex implementations of Sentiment analysis used in the industry today. Those algorithms can provide you with accurate scores for long pieces of text. Besides that, we have reinforcement learning models that keep getting better over time.

    For complex models, you can use a combination of NLP and machine learning algorithms. There are three major types of algorithms used in sentiment analysis. Let's take a look at them.

    Automated Systems

    Automatic approaches to sentiment analysis rely on machine learning models like clustering. Long pieces of text are fed into the classifier, and it returns the results as negative, neutral, or positive. Automatic systems are composed of two basic processes:

    Rule-based Systems

    Unlike automated models, rule-based approaches are dependent on custom rules to classify data. Popular techniques include tokenization, parsing, stemming, and a few others. You can consider the example we look at earlier as a rule-based approach.

    A good thing about rule-based systems is the ability to customize. These algorithms can be tailor-made based on context by developing smarter rules. However, you will have to regularly maintain these types of rule-based models to ensure consistent and improved results.

    Hybrid Systems

    Hybrid techniques are the most modern, efficient, and widely-used approach for sentiment analysis. Well-designed hybrid systems can provide the benefits of both automatic and rule-based systems.

    Hybrid models enjoy the power of machine learning along with the flexibility of customization. An example of a hybrid model would be a self-updating wordlist based on Word2Vec. You can track these wordlists and update them based on your business needs.

    Use Cases

    Analyzing Customer Feedback

    A Complete Guide To Sentiment Analysis And Its Applications

    Customer feedback analysis is the most widespread application of sentiment analysis. Direct customer feedback is gold for businesses, especially startups. Accurate audience targeting is essential for the success of any type of business.

    Well-made sentiment analysis algorithms can capture the core market sentiment towards a product. You can also extend this use case for smaller sub-sections. eg. analyzing product reviews on your amazon store. The more customer-driven a company is, the better sentiment analysis can be of service.

    Campaign Monitoring

    A Complete Guide To Sentiment Analysis And Its Applications

    Manipulating voter emotions is a reality now, thanks to the Cambridge Analytica Scandal.

    Another great use-case of sentiment analysis is a measure of influence. Taking the 2016 US Elections as an example, many polls concluded that Donald Trump was going to lose.

    But experts had noted that people were generally disappointed with the current system. They backed their claims with strong evidence through sentiment analysis. I had worked on a tool called Sentiments (Duh!) that monitored the US elections during my time as a Software Engineer at my former company. We noticed trends that pointed out that Mr. Trump was gaining strong traction with voters.

    This should be evidence that the right data combined with AI can produce accurate results, even when it goes against popular opinion.

    Brand Monitoring

    A Complete Guide To Sentiment Analysis And Its Applications

    Brand monitoring is another great use-case for Sentiment analysis. Companies can use sentiment analysis to check the social media sentiment of their audience.

    KFC is a perfect example of a business that uses sentiment analysis to track, build, and enhance its brand. KFC’s social media campaigns are a great contributing factor to its success. KFC tailors its marketing campaigns to appeal to the young crowd and to be “present” in social media.

    Tools like Brandwatch can tell you if something negative about your brand is going viral. Other brands that use social media to promote a positive brand sentiment include Amazon, Netflix, and Dominoes.

    Stock Market Analysis

    A Complete Guide To Sentiment Analysis And Its Applications

    If you are a trader or an investor, you understand the impact news can have on the stock market. Whenever a major news breaks, it is bound to have a strong positive or negative impact on the stock market.

    Sentiment analysis is a powerful tool for traders. You can analyze the market sentiment towards a stock in real-time, usually in a matter of minutes. This can help you plan your long or short positions for a particular stock.

    Recently, Moderna announced the completion of phase I of its COVID-19 vaccine clinical trials. This news saw a strong rise in the stock price of Moderna. But today, Moderna’s stock stumbled after losing a patent. Using sentiment analysis, you can analyze these types of news in realtime and use them to influence your trading decisions.

    Compliance Monitoring

    A Complete Guide To Sentiment Analysis And Its Applications

    Regulatory and legal compliance can make or break large organizations. Often, these compliance documents are stashed into large websites like Financial Conduct Authority.

    Large organizations spend a good chunk of their budgets into regulatory compliance. In these cases, traditional data analytics cannot offer a complete solution. Tools like ScrapingHub can help fetch documents from these websites. But companies need intelligent classification to find the right content among millions of web pages.

    Sentiment analysis can make compliance monitoring easier and cost-efficient. It can help build tagging engines, analyze changes over time, and provide a 24x7 watchdog for your organization.


    Sentiment analysis is a powerful tool that you can use to solve problems from brand influence to market monitoring. New tools are built around sentiment analysis to help businesses become more efficient.

    And by the way, if you love Grammarly, you can go ahead and thank Sentiment Analysis.
