Bug 1375982

Summary: Updating Oracle JDK breaks links to JCE policies
Product: Red Hat Enterprise Linux 6 Reporter: Piyush Bhoot <pbhoot>
Component: java-1.8.0-oracleAssignee: jiri vanek <jvanek>
Status: CLOSED ERRATA QA Contact: Lukáš Zachar <lzachar>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.9CC: bodavis, dbhole, jherrman, jvanek, jwright, mnewsome, zzambers
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Previously, java-1.8.0-oracle packages contained incorrect links to Java Cryptography Extension (JCE) policies. As a consequence, the policies were not applied properly. This update fixes the affected links.
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-06-26 20:05:01 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On: 1449315, 1503647    
Bug Blocks: 1461138, 1503147, 1504312    

Description Piyush Bhoot 2016-09-14 12:02:05 UTC
Description of problem:
Updating Oracle JDK breaks links to JCE policies

Version-Release number of selected component (if applicable):

java-1.8.0-oracle-1.8.0.101-1jpp.1.el6_8.x86_64
How reproducible:
Always

Steps to Reproduce:
1.set alternatives 
update-alternatives --install   /usr/lib/jvm/jre-1.8.0-oracle.x86_64/lib/security/local_policy.jar     jce_1.8.0_oracle_local_policy.x86_64      /opt/UnlimitedJCEPolicyJDK8/local_policy.jar     1000000  --slave     /usr/lib/jvm/jre-1.8.0-oracle.x86_64/lib/security/US_export_policy.jar jce_1.8.0_oracle_us_export_policy.x86_64  /opt/UnlimitedJCEPolicyJDK8/US_export_policy.jar

2.yum update java-1.8.0-oracle


Actual results:

ls -lart /usr/lib/jvm/jre-1.8.0-oracle.x86_64/lib/security
...
local_policy.jar -> /etc/alternatives/jce_1.8.0_oracle_local_policy.x86_64
US_export_policy.jar -> /etc/alternatives/jce_1.8.0_oracle_us_export_policy.x86_64

Expected results:

Links should keep pointing to JCE jar

Comment 14 jiri vanek 2017-11-16 08:01:20 UTC
No build done, but switching to modified, as it is fixed by underlying component.

Comment 18 zzambers 2018-05-23 21:23:53 UTC
I tested this one and with current packages and everything seems to work as expected. Update was done from java-1.8.0-oracle-1.8.0.171-1jpp.2.el6 to java-1.8.0-oracle-1.8.0.171-1jpp.3.el6.

Links from /usr/lib/jvm/jre-1.8.0-oracle.x86_64/lib/security point to 
links in /etc alternatives (this is expected):
local_policy.jar -> /etc/alternatives/jce_1.8.0_oracle_local_policy.x86_64
and
US_export_policy.jar -> /etc/alternatives/jce_1.8.0_oracle_us_export_policy.x86_64


Initialy links in /etc/alternatives point to following files:
jce_1.8.0_oracle_local_policy.x86_64 -> /usr/lib/jvm-private/java-1.8.0-oracle.x86_64/jce/vanilla/local_policy.jar
and
jce_1.8.0_oracle_us_export_policy.x86_64 -> /usr/lib/jvm-private/java-1.8.0-oracle.x86_64/jce/vanilla/US_export_policy.jar


After update-alternatives ... (see higher links in /etc/alternatives are updated to:
jce_1.8.0_oracle_local_policy.x86_64 -> /opt/UnlimitedJCEPolicyJDK8/local_policy.jar
and
jce_1.8.0_oracle_us_export_policy.x86_64 -> /opt/UnlimitedJCEPolicyJDK8/US_export_policy.jar

These links (in /etc/alternatives) keep their target after update.

Comment 22 errata-xmlrpc 2018-06-26 20:05:01 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2018:2055