Skip to main content

Why should we stop using SMS-based two-factor authentication?

 Today, securing an application is challenging as attackers are becoming increasingly sophisticated. A proper authentication system plays a significant role in application security, as, without one, the app’s vulnerability could allow a malicious person to gain unauthorized access. Poorly configured authentication systems and human error are the most common reasons for data breaches. Therefore, to address this issue, the concept of two-factor authentication (2FA) or multifactor authentication is applied.

In addition to user ID and password, 2FA requires users to input a temporary code unique to them to verify their identity. This creates an extra layer of security by adding one more element to the authentication process. If a user’s login credentials are compromised, malicious actors won’t be able to access the resources since they would need to have both the login credentials and the 2FA code. 

One of the most widely used methods of 2FA is an SMS-based code, where the user needs to enter a code sent to them through the SMS service to verify their identity. Almost every mobile device in the world supports a text messaging service, and developers might prefer it based on its simplicity and availability. Adding text-based 2FA on top of simple user ID- and password-based authentication might be safer than not having one, but it is not the most secure way of implementing multifactor authentication. 

 

So, what makes the SMS service vulnerable, and why is it not considered a secure method of authentication for 2FA? Here are a few vulnerabilities of SMS which make it the most insecure method for two-factor authentication:

SIMJacking
SIMJacking, also referred to as a port-out scam or SIM swap scam, is a type of attack where one would gain access to someone’s phone number by switching the service to another carrier. Port-out is a feature offered to users by their telecommunication companies where a customer can switch to different carriers and keep their current phone number. Usually, carriers require some form of identification before they provide a PIN to port out a phone number. Hackers are using sophisticated social engineering attacks and using publicly available information about a victim to gain access to their phone numbers by switching them to another carrier. After getting control over the phone number, the attacker would be able to gain access to 2FA codes.

Unencrypted protocol
SMS works through the Signaling System No 7 (SS7) protocol, sending clear text that is not encrypted by any encryption protocol. Because of this weakness, it is easy for hackers to intercept information sent via SMS. Since it doesn't use any encryption and the information is transmitted on a radio frequency, SMS is vulnerable to man-in-the-middle attacks, and third parties can get access to 2FA codes sent via SMS if they use the right tools and codex.

Device vulnerability
 SMS security also depends on the receiving device. If the phone is vulnerable, there is a risk of the 2FA code being stolen. SIM cards are also vulnerable to attack where a hacker could monitor all the conversations by installing malware on them.

As mentioned above, SMS-based 2FA is not the best way to implement multifactor authentication because of the multiple risks as described, and there are other better alternatives. Below we discuss two key alternatives to SMS-based authentication.

Hardware-based authentication
Hardware-based authentication uses dedicated physical hardware to generate authentication codes. These devices use time-based codes that expire after a certain time. New codes will be continuously generated based on the configured time. After logging in with a username and password, the user also needs to provide the 2FA code from the device before they are granted access to the application. Since users need to have this device with them physically to get the access code, this eliminates the risk of the code being compromised by an attacker through the internet. 

Software-based authentication
Software-based authentication works similarly to hardware-based, but instead of a physical device, it uses software to generate the 2FA codes. This provides user flexibility as they can install the application on their existing device. Google Authenticator and Microsoft Authenticator are two examples of widely used 2FA applications. Some hardware-based 2FAs also provide software applications that can be used in the same way without the need for hardware. Since the codes are generated locally without information being sent through insecure channels, it is considered more secure than SMS-based 2FA. 

Ultimately, SMS is convenient and easy to use, but it comes with risks when used as part of 2FA. Information sent through an unencrypted channel should never be trusted as secure. Physical devices that generate 2FA codes are much more secure than SMS-based solutions. Software-based 2FA codes provide better flexibility and are a much stronger solution than SMS. Since improper authentication could result in data breaches and losses to organizations, it is critical to select a secure multifactor authentication system.

Popular posts from this blog

Five Ways to Get Rid of Cryptojacking Malware

Cryptojacking is a growing threat in 2018 and there are several ways to prevent this threat. Few of the methods to prevent this emerging online threat are discussed below. Installing browsing extension Most of the crypto mining malware works from the web browser so we can stop that malware by installing a browser extension. There are few browser extensions like ublock origin & Malwarebytes that will help to block any cryptojacking scripts. If we have these extensions installed on the browser, they will automatically stop those scripts from running on the browser which will prevent the browser from running the mining code. Those extensions are available for free and they regularly update their signature. Since they will automatically filter the mining codes we don’t need to check them manually. Therefore, installing a proper extension will help to get rid of cryptojacking malware. Installing only trusted applications Another big source of crypto mining malware is untrusted ap

What is Ransomware & How to Prevent it?

Hackers are looking for a new and easier way to make money by entering on other people's system and ransomware is one of the tools they use to make money by locking the computer of people and organization. In my previous article, I discussed cryptojacking malware and why it is a big threat to information security. On that article, you can read how and why bad guys are injecting code on people's computer to make money from that. Ransomware is another major threat to cyberspace that I would like to discuss this article. What is ransomware? Ransomware is a software that is designed to block access to any system, files or operating system until we pay a certain amount to the attacker. Most of the time the attacker will encrypt the files of the computer and they will provide the key to decrypt only after paying the amount they are demanding. Most of the ransomware attack will give very limited time to the victim to pay the demanded amount and if they fail to decrypt it within th