Back
Do I have to rebuild my PKI if RSA is broken? Moving your certificate authority from RSA to ECDSA and post-quantum cryptography

What Should I Do if RSA Is Broken? Do I Need a New PKI?

If you have been in tech Twitter over the past two weeks, you probably have heard about AI breaking cryptography and specifically targeting RSA encryption. First, lets make it clear that this is a hypothetical scenario for now, and all the information that they have released is that RSA could potentially be broken when quantum computers reach a certain level of capability. So don’t fall for the fear mongering those people are probably just trying to sell you something. Still, even if RSA is not currently compromised, it is important to be prepared and understand the steps you should take if RSA were to be compromised.

How to Prepare for RSA Being Broken

First let’s talk about how RSA works. RSA consists of a pair of keys: a public key and a private key. The private key is two very very large prime numbers multiplied together, and basically the whole security of RSA relies on how hard it is to figure out what those two prime numbers are to reconstruct the private key. If an attacker can factor the product of these two primes, they can break RSA and decrypt any message encrypted with the corresponding public key (Who would have thought that elementary math was the key to modern cryptography?).

What is the Difference Between RSA 2048 and RSA 4096?

RSA 2048 and RSA 4096 refer to the key sizes used in the RSA algorithm. RSA 2048 uses a 2048-bit key, while RSA 4096 uses a 4096-bit key. While it would look like a 2x increase in key size would double the security, the relationship is actually exponential (each bit you add in binary doubles the number of possible keys, making it exponentially harder to factor the product of the primes). RSA 4096 is significantly more secure than RSA 2048, so if RSA 2K gets broken with 1000 graphics cards, RSA 4K is not broken with 2000 graphics cards.

Is RSA the only X509 Algorithm available?

No, RSA is not the only algorithm used in X509 certificates. Other commonly used algorithms include Elliptic Curve Cryptography (ECC) algorithms like ECDSA, this one is based on even crazier math involving the properties of elliptic curves over finite fields. ECC algorithms generally offer similar security to RSA but with much smaller key sizes, and since it is not based on prime numbers, it is not vulnerable to the same factoring attacks that threaten RSA.

ECDSA vs. RSA Key Size Equivalency

So how much smaller is “much smaller”? Here is how RSA and ECDSA key sizes line up in terms of classical security strength, based on NIST SP 800-57 Part 1, along with the maximum lifetime NIST gives each one in its post-quantum transition guidance (NIST IR 8547). “Security bits” is the industry’s way of saying “an attacker would need roughly 2^n operations to break it,” so every extra bit doubles the work.

Security Strength RSA Key Size ECDSA Key Size (Curve) NIST Maximum Lifetime
80 bits RSA 1024 160-bit Already disallowed. If you still have these, stop reading and go replace them.
112 bits RSA 2048 224-bit (P-224) Through 2030 (deprecated after 2030, disallowed after 2035)
128 bits RSA 3072 256-bit (P-256) Through 2035
~128 bits RSA 4096 256-bit (P-256) Through 2035 (NIST does not list RSA 4096 separately, so it gets credited at 128 bits)
192 bits RSA 7680 384-bit (P-384) Through 2035
256 bits RSA 15360 521-bit (P-521) Through 2035

The takeaway: a 256-bit ECDSA key gives you more security than a 2048-bit RSA key, and to match P-384 with RSA you would need a 7680-bit key that nobody actually deploys. That is why ECDSA certificates are smaller, faster to sign with, and easier on constrained IoT devices. Keep in mind this table only measures resistance to classical computers. Against a large enough quantum computer running Shor’s algorithm, both RSA and ECDSA fall regardless of key size, which is why NIST plans to disallow both algorithms entirely after 2035 in favor of post-quantum algorithms like ML-DSA.

How is Breaking RSA Measured?

With current publicly available technology it would take billions of years to break RSA 2048 using classical computers. The exact time depends on the number of computational resources available, but it is generally considered imposible with today’s technology. Usually a new technology doesn’t mean that all RSA is broken, instead it means that instead of billions of years, it now takes x amount of CPU/GPU time to break it. For example in 2017, Roca vulnerability demonstrated that certain RSA keys generated by specific hardware were much easier to factor than expected, reducing the effective security of those keys, it was estimated that it would cost between $20,000-$50,000 of AWS to break a vulnerable key. At that time, I was working at Microsoft and we decided that the cost to break the vulnerable keys required immediate attention and mitigation, leading to the immediate replacement of affected keys. But many organizations saw that as a very expensive attack for what they were protecting, and chose to accept the risk instead. So depending on the cost and time to break a key, organizations may decide to either replace it immediately or accept the risk until a more cost-effective solution is available.

What Should I do to Protect My Systems if RSA is Broken?

Currently, RSA is still considered secure with sufficiently large key sizes (I would try to aim to use at least 4096 keys), but it is also wise to start having a plan to transition to more secure algorithms, such as ECDSA or post-quantum cryptography, once they become widely available and standardized. This proactive approach ensures that your systems remain secure even if RSA is eventually broken.

Should I transition away from RSA now?

If you are currently using RSA, it is not an immediate emergency to switch, especially if you are using sufficiently large key sizes like 4096 bits. However, if you are starting a new CA, it is advisable to consider using more secure algorithms like ECDSA for the Root CA and if your PKI infrastructure allows, for the intermediate CAs as well (please note that many CAs do not support ECDSA for intermediates yet, since functions like SCEP would break under that scenario. EZCA does support ECDSA for intermediate CAs since we use an RA certificate in between the intermediate and the SCEP clients but that is a topic for another blog).

Also moving to more secure algorithms is not a binary decision, and this is where a well-designed CA hierarchy pays off. You can have your Root which is the Key that will last the longest be ECDSA so it can provide long-term security, while still using RSA for intermediate CAs or leaf certificates until the ecosystem fully supports the new algorithms and you are ready to make the complete transition.

What Should I do today to Protect against RSA being Broken?

Ok so let’s break this down into actionable steps:

  1. Assess your current RSA usage: Identify all systems and certificates that rely on RSA, and determine the key sizes in use.
  2. Evaluate the risk: Consider the sensitivity of the data protected by RSA and the potential impact if it were broken.
  3. Plan for transition: Start planning a migration strategy to more secure algorithms like ECDSA or post-quantum cryptography.
  4. Implement stronger keys: Where possible, upgrade RSA keys to at least 4096 bits to maximize security in the short term.
  5. Monitor developments: Keep an eye on advancements in cryptography and any new vulnerabilities affecting RSA.
  6. Test new algorithms: Begin testing ECDSA or post-quantum algorithms in non-critical environments to prepare for a smooth transition.
  7. Update policies and procedures: Ensure your organization’s security policies reflect the planned transition away from RSA and include guidelines for key management and replacement.
  8. Educate your team: Make sure your IT and security teams are aware of the potential risks associated with RSA and are trained on the new algorithms and procedures being implemented.

What things currently only work with RSA?

If you notice, I haven’t really talked much about ML-DSA (Modular Lattice-based Digital Signature Algorithm) or other post quantum algorithms. The reason is that currently, many systems and protocols are still heavily reliant on RSA, and transitioning to post-quantum algorithms is not yet widely supported so while you can test it with EZCA, it is still not ready for production use in most environments. In fact, there are many things that currently don’t work with ECDSA.

Does Entra ID Application Authentication Support ECDSA?

Currently, Entra ID Application Authentication primarily relies on RSA for signing tokens and certificates. While there is ongoing work to support ECDSA and other post-quantum algorithms, full support is not yet available. Therefore, if your applications depend on Entra ID for authentication, you may still need to use RSA until the ecosystem catches up with newer algorithms.

Does SCEP Device Enrollment Support ECDSA?

SCEP (Simple Certificate Enrollment Protocol) is widely used for device certificate enrollment (including in Intune) and traditionally relies on RSA for key generation and signing. While there is interest in supporting ECDSA and other post-quantum algorithms, many SCEP implementations still primarily support RSA. Therefore, if your device enrollment process depends on SCEP, you may need to continue using RSA in your devices until a move to ACME Device Enrollment or other protocols that support ECDSA is feasible. Note: In EZCA, your SCEP CA can be ECDSA, but the devices enrolling via SCEP will still need to use RSA. (and Windows devices using TPM for key storage will need to keep using RSA 2048 since the TPM does not yet support larger key sizes. However, remember what we talked about earlier regarding the time it takes to break a key so since SCEP certificates are automatically renewed and have relatively short lifetimes, the immediate risk is somewhat mitigated.)

Does ACME Device Enrollment Support ECDSA?

ACME (Automated Certificate Management Environment) is a protocol used for automated certificate issuance and management. Unlike SCEP, ACME has broader support for modern cryptographic algorithms, including ECDSA. Therefore, if you are planning to transition away from RSA for device enrollment, ACME with device attestation may provide a more flexible and future-proof solution compared to SCEP. However, ensure that your devices and infrastructure fully support ECDSA before making the switch.

Does S/MIME Support ECDSA?

S/MIME (Secure/Multipurpose Internet Mail Extensions) is commonly used for email encryption and signing. Traditionally, S/MIME has relied on RSA for key generation and digital signatures. While there is growing support for ECDSA and other modern cryptographic algorithms, many email clients and servers still primarily support RSA and if you are planning to use the certificate for encryption, you will need to continue to use RSA since ECDSA does not support encryption. In this scenario we recommend using an RSA 4096-bit key to ensure strong security for your encrypted emails.

Does Intune PKCS Support ECDSA?

Intune PKCS (Public Key Cryptography Standards) profiles are used to deploy certificates to devices managed by Microsoft Intune. Traditionally, these profiles have relied on RSA for key generation and signing. If your organization relies on Intune PKCS for certificate deployment, you may need to continue using RSA until full support for ECDSA is available.

Does Entra CBA Support ECDSA?

This one is a bit of a gray area. Microsoft’s Entra CBA documentation does not list which key algorithms are supported for user certificates, but a Microsoft employee confirmed on Microsoft Q&A that “Windows smart card sign-in with Microsoft Entra certificate-based authentication does not currently support elliptic curve cryptography (ECC) certificates,” and that there are no plans in the pipeline to add it. So if you are setting up Entra CBA or using it for smart card log on to Windows, the certificates on your users’ smart cards and YubiKeys need to be RSA. Until Microsoft documents ECC support, I would not roll out ECDSA user certificates for Entra CBA without testing every sign-in scenario your users depend on first.

Does Windows Hello for Business Support ECDSA?

No, and this is one you can’t configure your way out of. When a user enrolls in Windows Hello for Business, Windows generates an RSA 2048 key pair in the device’s TPM, and that is the key used whether you deploy key trust, certificate trust, or cloud Kerberos trust. You also can’t bump it to RSA 4096: Microsoft’s Intune SCEP documentation states that 4096-bit keys are not supported with the Windows Hello for Business key storage provider, and that “there’s no workaround for Windows Hello for Business at this time.” The good news is that the private key never leaves the TPM, so today’s attacks on Windows Hello for Business target the device, not the math. But if RSA 2048 falls, this is a place where you will be waiting on Microsoft to ship a new key type.

Does Azure VPN Gateway Support ECDSA?

Not for IKEv2. According to the Azure VPN Gateway FAQ, VPN Gateway supports RSA-based X.509 certificates for point-to-site certificate authentication, and it currently doesn’t support ECC/ECDSA certificates for IKEv2-based point-to-site connections. That means both the root certificate you upload to the gateway and the client certificates you deploy to your users’ devices need to be RSA. If you are issuing those client certificates through Intune, plan on an RSA 4096 key where your devices support it, keeping in mind that Windows devices storing the key in the TPM are limited to RSA 2048.

Has Encryption been Broken Before?

Yes, this is not our first rodeo. Cryptographic algorithms have been broken or weakened before, prompting the industry to transition to stronger alternatives. Starting with the Enigma machine during World War II, to the breaking of DES (Data Encryption Standard) in the late 1990s, and more recently the gradual deprecation of SHA-1, history has shown that no algorithm is immune to advances in cryptanalysis and computing power and just like in those cases, the industry will adapt and adopt stronger algorithms to maintain security.

One of the most modern examples was the transition from DES to AES (Advanced Encryption Standard). DES, which had been widely used for decades, was eventually found to be vulnerable to brute-force attacks due to its relatively short key length. While the industry moved to AES, which offers significantly stronger security with longer key lengths, the transition required updates to hardware, software, and protocols to support the new standard. In the meantime, 3DES (Triple DES) was often used as an interim solution, applying the DES algorithm three times to each data block to increase security until AES became widely adopted. This shows that even if RSA 2048 or other widely used algorithms are eventually broken, the industry has a track record of successfully transitioning to stronger cryptographic standards while maintaining security during the interim period.

In conclusion, while the potential breaking of RSA 2048 is a significant concern, history demonstrates that the cryptographic community is capable of adapting to new threats and evolving standards. By learning from past transitions, such as from DES to AES, organizations can better prepare for the eventual shift to stronger algorithms like ECDSA or post-quantum cryptography, ensuring continued security and resilience in the face of emerging challenges.

Get Your PKI Ready for a World Without RSA

You don’t have to rebuild your PKI overnight, but you do need to know where RSA lives in your environment and have a plan for moving off it. EZCA, our cloud PKI for Microsoft customers, supports RSA, ECDSA, and quantum-ready ML-DSA CAs, so you can start with an ECDSA Root today and move the rest of your hierarchy as the ecosystem catches up. And remember step one: you can’t replace what you can’t find. EZMonitor watches Certificate Transparency logs for your domains, so you can see every public certificate issued for your organization in one place, including the ones someone bought on a credit card three years ago and forgot about. Not sure where to start? Schedule a FREE call with one of our PKI experts and we will help you map out your transition.

Try EZCA for Free Find Your Public Certificates With EZMonitor Book a Free Consultation