Repository navigation
chore(deps): bump log4j to 2.25.5 and jsoup to 1.23.2 in core and the Tika bundle (#37975) - #38369
jcastro-dotcms wants to merge 2 commits into
Conversation
… Tika bundle (#37975) - bom/logging: log4j.version 2.23.1 -> 2.25.4 (webapp jars and tomcat log4j2/lib) - bom/application: jsoup.version 1.21.1 -> 1.23.2 - Tika plugin: import log4j-bom 2.25.4 and manage jsoup 1.23.2 so the embedded copies move from 2.20.0 / 1.22.2 to the same versions; drop the hardcoded log4j-slf4j2-impl version - Tika plugin: keep OSGi bundle annotations from embedded jars out of the bundle manifest (log4j 2.25 declares its own activator and exports), so the bundle keeps a single activator and exports nothing, as before - Tika plugin: import org.osgi.framework.wiring, which log4j 2.25 needs to initialize inside an OSGi bundle Co-Authored-By: Claude Mythos 5.1 <noreply@anthropic.com>
|
Claude finished @jcastro-dotcms's task in 1m 33s —— View job PR Review: bump log4j 2.25.5 & jsoup 1.23.2
New Issues
Notes (non-blocking, no action required)
SummaryThe change is well-scoped: all log4j artifacts in |
Same 2.25 patch line as the previous commit; 2.25.5 is the newest patch of that line and supersedes 2.25.4 everywhere the bom and the Tika bundle pin it. Co-Authored-By: Claude Mythos 5.1 <noreply@anthropic.com>
Security assessment
Why: Carries the score and priority of the issue it fixes (#37975). Labels: added Automated triage by the dotCMS Security team (Claude), 2026-10-30. To override, change the project's Priority field or the CVSS label. The next refresh keeps a manual change. |
Summary
Minor/patch dependency upgrades, same shape as #37904.
log4j-api,log4j-core,log4j-1.2-api,log4j-jcl,log4j-slf4j2-impl,log4j-appserver)bom/logging(webappWEB-INF/liband Tomcatlog4j2/lib)bom/applicationlog4j-api,log4j-core,log4j-slf4j2-impl, embedded)tika-parser-code-module)log4j-slf4j2-impl)Changes
bom/logging/pom.xml:log4j.version2.23.1 → 2.25.5.bom/application/pom.xml:jsoup.version1.21.1 → 1.23.2.independent-projects/core-plugins/tika-plugin/pom.xml:dependencyManagementimportslog4j-bom2.25.5 and managesorg.jsoup:jsoup1.23.2 (same pattern as the existingjackson-bomimport); the hardcodedlog4j-slf4j2-impl2.20.0 version is dropped.maven-bundle-plugininstructions,_bundleannotationsand_removeheaders. log4j 2.25 jars carry OSGi bundle annotations (their ownBundle-Activator, capabilities and package exports). bnd applies them to every class in the bundle, embedded jars included, which fails the build with a three-classBundle-Activatorheader and would export every log4j package from the Tika bundle. The instructions limit annotation processing to our own classes and drop the computedExport-Package, so the bundle manifest keeps the same header set as today: one activator, no exports,Require-Capabilityunchanged.Import-Packagegainsorg.osgi.framework.wiring. log4j 2.25 resolves its providers through the OSGi wiring API when it runs inside a bundle, and without that import the bundle activator failed to initialize its logger, so the Tika service never registered and file metadata extraction logged errors on every asset. Found on a local stack; Felix exports the package from the system bundle.Notes for reviewers
The first commit targeted 2.25.4; the second moves to 2.25.5, the newest patch on the same line, which carries one more
log4j-apifix. Its release notes list only fixes (rolling-filecreateOnDemand, JSON/XML encoding of messages, stack-trace rendering, a configuration-source resource leak); no configuration or OSGi changes.No Java changes. Core does not use the Log4j 1.x API and changes log levels through the log4j-core classes directly, so the 2.24 change that stops the 1.x and JUL bridges from reconfiguring core does not apply.
log4j 2.25 changed the default exception rendering and sends the status logger to stderr. Our
log4j2.xmlsets an explicit%xEx{filters(...)}pattern; startup output was compared on a local stack (see Tests).jsoup 1.22/1.23 changed parser defaults (depth limit 512,
noscriptparsed into the DOM, trailing comments after</body>kept underhtml). The classes core uses (Jsoup,Document,Element,Elements,Node,TextNode,Comment) are unchanged.The host-exported package versions in
osgi-extra.confstill read 2.20.0 fororg.apache.logging.*; bnd-generated import ranges ([2.20,3)) keep resolving, so that file is untouched.Tests
./mvnw install -pl :dotcms-core --am -DskipTests -Dmaven.build.cache.enabled=false: all 13 modules pass;openapi.yamlunchanged.dependency:tree: core resolves log4j 2.25.5 and jsoup 1.23.2; the Tika bundle resolves log4j-api/core/slf4j2-impl 2.25.5 and jsoup 1.23.2.LoggerTest,StringUtilsTest,TiptapHtmlTest,TiptapHtmlRichNodeTest,LongTextPreviewStrategyTest,HtmlMinifierIntegrityTest,AIViewToolErrorHandlerTest,ContentFactoryIndexOperationsPhaseRoutingTest,ReindexThreadUnitTest,RuleActionRefusedNameTest).WEB-INF/liband Tomcatlog4j2/libship 2.25.5, jsoup 1.23.2; the Tika bundle embeds the new versions. Its manifest has the same header set as the bundle in 26.10.29-01 (single activator, no exports, sameRequire-Capability), plus theorg.osgi.framework.wiringimport.GET/PUT /api/v1/loggerlevel changes round-trip. The only visible difference is eight log4j status-logger lines on stderr at startup (2.25 writes the status logger to stderr; ourlog4j2.xmlsetsstatus="INFO").Risk
Low. Patch/minor upgrades within the same major lines; no API changes in the code paths core uses. The Tika bundle manifest is byte-for-byte the same header set as the current release, verified by diffing against the shipped
com.dotcms.tika-26.10.29-01.jar.This PR fixes: #37975
🤖 Generated with Claude Code