Skip to content

Instantly share code, notes, and snippets.

@enrique-fernandez-polo
Created September 20, 2016 08:25
Show Gist options
  • Save enrique-fernandez-polo/44a23b222d0e8abcae7a42152c4a0d93 to your computer and use it in GitHub Desktop.
Save enrique-fernandez-polo/44a23b222d0e8abcae7a42152c4a0d93 to your computer and use it in GitHub Desktop.
Download Java JDK 8 and install JCE
wget -q -N --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" "http://download.oracle.com/otn-pub/java/jdk/8u101-b13/jdk-8u101-linux-x64.tar.gz" -O jdk-8u101-linux-x64.tar.gz
tar -xf jdk-8u101-linux-x64.tar.gz
wget -q -N --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" "http://download.oracle.com/otn-pub/java/jce/8/jce_policy-8.zip" -O jce_policy-8.zip
unzip -qo jce_policy-8.zip
rm -rf jdk1.8.0_101/jre/lib/security/local_policy.jar
rm -rf jdk1.8.0_101/jre/lib/security/US_export_policy.jar
mv UnlimitedJCEPolicyJDK8/US_export_policy.jar jdk1.8.0_101/jre/lib/security/
mv UnlimitedJCEPolicyJDK8/local_policy.jar jdk1.8.0_101/jre/lib/security/
wget -q -N "https://www.bouncycastle.org/download/bcprov-jdk15on-154.jar" -O bcprov-jdk15on-154.jar
mv bcprov-jdk15on-154.jar jdk1.8.0_101/jre/lib/ext/
echo "security.provider.10=org.bouncycastle.jce.provider.BouncyCastleProvider" >> jdk1.8.0_101/jre/lib/security/java.security
rm -rf jdk-8u101-linux-x64.tar.gz
rm -rf jce_policy-8.zip
rm -rf UnlimitedJCEPolicyJDK8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment