Commons CodecのBlake3で派生鍵が同一に、要コード修正
Summary
Apache Commons CodecのBlake3で、同じインスタンスから鍵を続けて派生するJavaコードは、別々のはずの鍵が同じ値になります。1.23.0は文書の修正だけなので、更新に加えて自社コードを点検し、必要なら鍵を再発行してください。
AI summary
Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.
Apache Commons CodecのBlake3で、同じインスタンスから鍵を続けて派生するJavaコードは、別々のはずの鍵が同じ値になります。1.23.0は文書の修正だけなので、更新に加えて自社コードを点検し、必要なら鍵を再発行してください。
Affected packages
| Package | Affected → Fixed | |
|---|---|---|
| Apache Software FoundationApache Commons Codec |
≥ 1.16.0, < 1.23.0→ 1.23.0 |
1.23.0 |
Fix status by distribution
Records published by each distribution for this CVE. Fixed versions differ by release; check each link.
- Ubuntu UBUNTU-CVE-2026-119078 libcommons-codec-java No fixed version in this record
Original description The description as published by the source.
Apache Commons Codec's Blake3 class documented the output of its doFinalize methods as depending on any previously finalized bytes, so that consecutive calls would return different output. In fact, doFinalize does not change the hash state: calling it again without supplying more input returns the same bytes. The key-derivation example in the class Javadoc, shipped since 1.16.0, derives two keys with two consecutive doFinalize calls. Code that follows it gets identical keys, so the separation between the derived keys is lost. The same applies to any application that calls doFinalize more than once on one instance and expects new output each time.
This issue affects Apache Commons Codec from 1.16.0 before 1.23.0.
Version 1.23.0 corrects the documentation, but the behavior of doFinalize is unchanged. Upgrading alone does not fix affected code. Users should check their applications for repeated doFinalize calls on the same Blake3 instance and derive multiple keys by requesting the combined length in one call and splitting the output, as the updated Javadoc shows.
Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory
References
- web security@apache.org
- web nvd.nist.gov
- web github.com
- web openwall.com