Repository navigation
fix(java): 升级 micrometer 至 1.15.12 修复 CVE-2026-40984 - #47
Conversation
micrometer-core 1.12.9 受 CVE-2026-40984 影响(HTTP server instrumentation 可被 构造请求触发 DoS),升到 OSS 修复版 1.15.12。 1.15 线将 Prometheus registry 包名由 io.micrometer.prometheus 改为 io.micrometer.prometheusmetrics。为保持 SDK 对外 API 的包名不变、接入方零改动, registry 依赖改用官方过渡产物 micrometer-registry-prometheus-simpleclient (仍提供旧包名)。仅改 pom 依赖坐标,无代码改动。
Welcome To opensourceways CommunityHey @wyhhai , thanks for your contribution to the community. Bot Usage ManualI'm the Bot here serving you. You can find the instructions on how to interact with me at Here . That means you can comment below every pull request or issue to trigger Bot Commands. Contact GuideIf you have any questions, please contact the SIG: infratructure , |
CLA Signature Guide@wyhhai , thanks for your pull request. The following commit(s) are not associated with a signed Contributor License Agreement (CLA).
To sign CLA, click here. To check if your email is configured correctly, refer to the FAQs. Once you've signed the CLA or updating your email, please comment |
Linking Issue Notice@wyhhai , the pull request must be linked to at least one issue. |
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
背景
安全扫描发现
java/pom.xml的io.micrometer:micrometer-core存在 CVE-2026-40984(HIGH / CVSS 7.5):HTTP server instrumentation 可被构造请求触发 DoS。当前 1.12.9 在官方受影响范围内(1.10.0–1.13.18),OSS 修复版为 1.15.12。改动
仅改
java/pom.xml的依赖坐标,无 Java 代码改动:micrometer.version:1.12.9→1.15.12micrometer-registry-prometheus→micrometer-registry-prometheus-simpleclient第 2 点是必须的:1.15 线把 registry 包名从
io.micrometer.prometheus改成io.micrometer.prometheusmetrics,改用官方过渡产物-simpleclient(仍提供旧包名)可让 SDK 对外 API 与接入方代码零改动。验证
mvn test:43 个用例全部通过(Tests run: 43, Failures: 0, Errors: 0)mvn dependency:list确认:micrometer-core:1.15.12、micrometer-registry-prometheus-simpleclient:1.15.12注意(重要,勿忽略)
dependencyManagement优先于传递版本)会把micrometer-core压回 1.12.9,CVE 在接入方仓库里不会真正清除;要真正清掉需接入方升级到 Boot 3.5.x(micrometer 1.15.12)。micrometer-registry-prometheus-simpleclient为官方过渡/弃用产物,其自动配置在 Boot 3.5 已被移除。建议后续 follow-up 将 SDK 迁移到官方新包io.micrometer.prometheusmetrics(届时为 breaking change,需同步更新 README 与接入方CollectorRegistryBean)。Test plan
mvn test全绿