How to Fix Java Security Provider Error
NoSuchAlgorithmException or Cannot find any provider supporting means Java lacks an algorithm Minecraft needs. How to find what removed it and get it back.
Quick Fix
Run the game on the Java runtime the launcher provides and remove any -Djava.security.properties flag you added to the JVM arguments.
Error Message
java.security.NoSuchAlgorithmException: SHA256withRSA Signature not availableHow to Fix
Read which algorithm is missing. SHA256withRSA Signature not available or Cannot find any provider supporting AES/CFB8/NoPadding names it exactly.
Look at System Details in the crash report. Java Version and Java VM Version show which Java actually ran the game.
In the Minecraft Launcher, edit the installation and set Java executable back to the bundled Java runtime, which is the default. Minecraft 26.2 asks for its own Java 25 runtime.
Remove -Djava.security.properties from the installation's JVM arguments, or fix the provider lines in the file it points to.
If you changed conf/security/java.security inside your Java folder, put the provider lines back or reinstall that Java version.
On a server, check the start script and the startup settings of your panel or container for the same flags.
Common Causes
- The java.security file of your Java install was edited and a provider was removed. The default list starts with SUN, SunRsaSign, SunEC, SunJSSE and SunJCE, and together they supply RSA, AES and the SHA algorithms.
- A -Djava.security.properties flag loads a file that changes the provider list. With two equals signs, that file replaces java.security completely.
- The game runs on a different Java install than the launcher's own runtime, and that install has its own security settings.
- The error appears when the game first needs one of these algorithms. Minecraft uses RSA and AES/CFB8/NoPadding to encrypt the connection to a server, and SHA256withRSA for profile keys and chat signing.
Diagnostic Steps
- Note the algorithm named in the error.
- Switch to the launcher's Java runtime.
- Remove -Djava.security.properties.
- Restore java.security or reinstall Java.
FAQ
Does -Djava.security.egd=file:/dev/urandom fix this?
No. That flag only picks the source of seed data for SecureRandom and overrides securerandom.source, which is file:/dev/random by default. It can't bring back a missing algorithm.
Where is the java.security file?
In conf/security inside the Java installation folder on Java 9 and newer. A file passed with -Djava.security.properties adds to it, or replaces it when the flag uses two equals signs.
Which algorithms does Minecraft need from Java?
RSA and AES/CFB8/NoPadding for the encrypted server connection, SHA-1 for the login hash and SHA256withRSA for profile keys and signed chat. Every standard Java runtime includes them.