Skip to content

Fix CVE-2026-61487, CVE-2026-59878 (5.16.x) - #268

Merged
epearson-tt merged 2 commits into
tomitribe:activemq-5.16.x-TT.xfrom
epearson-tt:activemq-5.16.x-TT.x-cve61487-59878
Aug 27, 2026
Merged

Fix CVE-2026-61487, CVE-2026-59878 (5.16.x)#268
epearson-tt merged 2 commits into
tomitribe:activemq-5.16.x-TT.xfrom
epearson-tt:activemq-5.16.x-TT.x-cve61487-59878

Conversation

@epearson-tt

Copy link
Copy Markdown

Fixes the following CVEs:

… (apache#2172)

Add a negative size check for AMQP NIO transports.
This also adds a similar check to OpenWire. For OpenWire
the same IllegalArgumentException is thrown but this
improves the error message in the NIO transport.

(cherry picked from commit 6e9dd5b)
(cherry picked from commit cb03c48)
…ionBroker (apache#2219) (apache#2221)

For temporary destinations we need to iterate over the list of composite
destinations and compute the union using the same strategy as
DefaultAuthorizationMap.

Backport adaptation for the 5.16.x-TT.x branch: this branch builds at
source/target 1.8, but the upstream tests use language and library features
newer than Java 8. The test code has been rewritten with Java 8 equivalents,
leaving the assertions and the code under test unchanged:

* AuthorizationBrokerTest: Set.of(...) (Java 9) is replaced by a local
  setOf(Object...) helper returning new HashSet<>(Arrays.asList(items)), with
  a java.util.HashSet import added. Set equality is by size plus containsAll,
  so HashSet compares identically to the immutable set the upstream test built.
  The helper returns Set<Object> to match the Set<Object> parameter of
  AuthorizationEntry's setAdminACLs/setReadACLs/setWriteACLs.
* AuthorizationBrokerTest and SimpleSecurityBrokerSystemTest: the no-argument
  Optional.orElseThrow() (Java 10) is replaced by Optional.get(). Both throw
  NoSuchElementException when empty, so behaviour is unchanged.
* AuthorizationBrokerTest and SimpleSecurityBrokerSystemTest: local variables
  declared with var (Java 10) are given their explicit types,
  SimpleAuthorizationMap and TempDestinationAuthorizationEntry.

No main/ source is adapted: the fix itself is Java 8 clean, and the only new
library calls in the CVE-2026-59878 companion commit, Integer.toUnsignedLong
and Integer.compareUnsigned, are Java 8 APIs.

(cherry picked from commit 91e35e0)
(cherry picked from commit 106d181)
@epearson-tt
epearson-tt merged commit afc84ac into tomitribe:activemq-5.16.x-TT.x Aug 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants