Performing encryption behind Java. Security. InvalidKeyException: illegal Key Size
Because the key is more than 128, sell Java. Security. InvalidKeyException: Illegal key size. Because the key length is limited, the Java runtime environment reads restricted policy files.
solution :
lution A:
g> the official download of the JCE unrestricted permission policy file, and replace the corresponding file
JDK7 download address: http://www.oracle.com/technetwork/java/javase/downloads/jce-7-download-432124.html
JDK8 download address: http://www.oracle.com/technetwork/java/javase/downloads/jce8-download-2133166.html
Download after decompression can see local_policy. Jar and US_export_policy jar and readme. TXT
if installed JRE, put the two jar files in % JRE_HOME % \ lib \ security directory under the cover of the original file
if installed JDK, and put the two jar files are in % JDK_HOME % \ JRE \ lib \ security directory to cover the original file
Option B:
Replace Oracle JDK with OpenJDK, the free and open source Java version of Oracle. OpenJDK does not have this limitation, and most Java services run on the OpenJDK environment
Read More:
- JavaScript emoticon package encryption
- Several problems caused by device encryption
- The fastest way to solve the problem of error reporting from crypto.cipher import AES
- Encryption unsuccessful, need to factory reset or crash after android restarts several times
- To solve the problem of loading rjava in installation of xlsx
- Install Java runtime JRE in Ubuntu 16.04
- Eclipse reported an error: an error has occurred
- Aptana studio 3 installation
- R language loading xlsx error error: JAVA_HOME cannot be determined from the Registry
- Android 8.1 compilation error Jack server problem
- OpenJDK11 failed: PKIX path building failed XXXXX
- Failed to create Oracle Oracle home user solution appears in oracle12c installation
- Solution: PIP install MySQL Python has the following problems
- Error running Eclipse: failed to load the JNI shared library
- Error “nbconvert failed: xelatex not found on path…” Solutions
- Oracle login error: Oracle error 6 initializing SQL * plus (normal before)
- Mobile app development: installation and configuration of react native
- Solve the problem of jdk8 after win7 is installed. Has value ‘1.8’, but ‘1.7’ is required
- Solution of visdom startup failure in Windows 10
- Could’t find path to unrear Library