RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1960024 - JDK-8266279: 8u292 NoSuchAlgorithmException unrecognized algorithm name: PBEWithSHA1AndDESede
Summary: JDK-8266279: 8u292 NoSuchAlgorithmException unrecognized algorithm name: PBEW...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: java-1.8.0-openjdk
Version: 7.9
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: rc
: ---
Assignee: Andrew John Hughes
QA Contact: OpenJDK QA
URL:
Whiteboard:
: 1964531 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-05-12 19:51 UTC by Mike Millson
Modified: 2024-12-20 20:04 UTC (History)
17 users (show)

Fixed In Version: java-1.8.0-openjdk-1.8.0.292.b10-2.el7_9
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-07-21 12:50:25 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
openjdk bug system JDK-8242565 0 None None None 2021-05-17 12:09:06 UTC
openjdk bug system JDK-8266279 0 None None None 2021-05-25 15:57:10 UTC
openjdk bug system JDK-8266929 0 None None None 2021-05-25 19:04:16 UTC

Description Mike Millson 2021-05-12 19:51:11 UTC
Upgrading from the RH build of OpenJDK 8 u282 to u292, JBoss EAP 7.3.6 fails to start with the following error:

2021-05-12 03:03:05,766 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-6) MSC000001: Failed to start service org.wildfly.core.management.security.realm.ApplicationRealm.key-manager: org.jboss.msc.service.StartException in service org.wildfly.core.management.security.realm.ApplicationRealm.key-manager: Failed to start service
    at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1731)
    at org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1559)
    at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
    at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1982)
    at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1486)
    at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1363)
    at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.IllegalStateException: org.jboss.msc.service.StartException in anonymous service: WFLYDM0018: Unable to start service
    at org.jboss.as.domain.management.security.FileKeyManagerService.loadKeyStore(FileKeyManagerService.java:179)
    at org.jboss.as.domain.management.security.AbstractKeyManagerService.createKeyManagers(AbstractKeyManagerService.java:128)
    at org.jboss.as.domain.management.security.AbstractKeyManagerService.start(AbstractKeyManagerService.java:93)
    at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1739)
    at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1701)
    ... 6 more
Caused by: org.jboss.msc.service.StartException in anonymous service: WFLYDM0018: Unable to start service
    at org.jboss.as.domain.management.security.FileKeystore.load(FileKeystore.java:147)
    at org.jboss.as.domain.management.security.FileKeyManagerService.loadKeyStore(FileKeyManagerService.java:175)
    ... 10 more
Caused by: java.security.KeyStoreException: Key protection  algorithm not found: java.security.UnrecoverableKeyException: Encrypt Private Key failed: unrecognized algorithm name: PBEWithSHA1AndDESede
    at sun.security.pkcs12.PKCS12KeyStore.setKeyEntry(PKCS12KeyStore.java:677)
    at sun.security.pkcs12.PKCS12KeyStore.engineSetEntry(PKCS12KeyStore.java:1384)
    at java.security.KeyStore.setEntry(KeyStore.java:1557)
    at org.jboss.as.domain.management.security.FileKeystore.load(FileKeystore.java:135)
    ... 11 more
Caused by: java.security.UnrecoverableKeyException: Encrypt Private Key failed: unrecognized algorithm name: PBEWithSHA1AndDESede
    at sun.security.pkcs12.PKCS12KeyStore.encryptPrivateKey(PKCS12KeyStore.java:921)
    at sun.security.pkcs12.PKCS12KeyStore.setKeyEntry(PKCS12KeyStore.java:614)
    ... 14 more
Caused by: java.security.NoSuchAlgorithmException: unrecognized algorithm name: PBEWithSHA1AndDESede
    at sun.security.x509.AlgorithmId.get(AlgorithmId.java:448)
    at sun.security.pkcs12.PKCS12KeyStore.mapPBEAlgorithmToOID(PKCS12KeyStore.java:938)
    at sun.security.pkcs12.PKCS12KeyStore.encryptPrivateKey(PKCS12KeyStore.java:895)

It looks to be caused by this upstream issue:
https://bugs.openjdk.java.net/browse/JDK-8266279

Comment 5 Severin Gehwolf 2021-05-17 12:14:38 UTC
This looks to be an 8u-only issue which seems fixed by the backport of JDK-8242565. At least the reproducer from JDK-8266279 fails for me for unpatched JDK 8u, passes with JDK 11 and passes with patched JDK 8u (patch from JDK-8242565).

Unpatched JDK 8u:

$ java -showversion -cp bcprov-jdk15on-168.jar:. TestAlgorithm
openjdk version "1.8.0_292"
OpenJDK Runtime Environment (build 1.8.0_292-b10)
OpenJDK 64-Bit Server VM (build 25.292-b10, mixed mode)

Exception in thread "main" java.security.NoSuchAlgorithmException: unrecognized algorithm name: PBEWithSHA1AndDESede
	at sun.security.x509.AlgorithmId.get(AlgorithmId.java:448)
	at javax.crypto.EncryptedPrivateKeyInfo.<init>(EncryptedPrivateKeyInfo.java:137)
	at TestAlgorithm.main(TestAlgorithm.java:8)


Patched JDK 8u:

$ java -showversion -cp bcprov-jdk15on-168.jar:. TestAlgorithm
openjdk version "1.8.0_292-internal"
OpenJDK Runtime Environment (build 1.8.0_292-internal-b05)
OpenJDK 64-Bit Server VM (build 25.292-b05, mixed mode)

JDK 11u:

$ java -showversion -cp bcprov-jdk15on-168.jar:. TestAlgorithm
openjdk version "11.0.11" 2021-04-20
OpenJDK Runtime Environment 18.9 (build 11.0.11+9)
OpenJDK 64-Bit Server VM 18.9 (build 11.0.11+9, mixed mode, sharing)

Comment 6 zzambers 2021-05-17 15:11:30 UTC
There is also this github issued against BouncyCastle (which seems related):
https://github.com/bcgit/bc-java/issues/941

Some (possible) workarounds are discussed there.

Comment 18 Andrew John Hughes 2021-06-03 00:17:40 UTC
*** Bug 1964531 has been marked as a duplicate of this bug. ***

Comment 52 errata-xmlrpc 2021-07-21 12:50:25 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 (Important: java-1.8.0-openjdk security and bug fix update), 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/RHSA-2021:2845

Comment 54 Andrew John Hughes 2021-07-21 15:51:45 UTC
The fix is also in the new RHEL 8.4 update to 8u302: https://access.redhat.com/errata/RHSA-2021:2776


Note You need to log in before you can comment on or make changes to this bug.