Deserialization of Untrusted Data in Apache Batik
Published 13 May 2022 · Updated 14 Mar 2024
Is your project on an affected org.apache.xmlgraphics:batik?
Look after several Java apps? Indie watches up to 15 repos, private ones too, for $5 a month. See Indie
Affected package
- Affected
- >=1.0 <1.10
- Fixed in
- 1.10
mvn versions:use-dep-version -Dincludes=org.apache.xmlgraphics:batik -DdepVersion=1.10 -DforceVersion=trueDetails
In Apache Batik 1.x before 1.10, when deserializing subclass of AbstractDocument, the class takes a string from the inputStream as the class name which then use it to call the no-arg constructor of the class. Fix was to check the class type before calling newInstance in deserialization.
Is GHSA-25gw-4pcc-45cf in any of your client repos?
Checking one package by hand is fine. Checking it across forty client projects is not. NPMscan reads the lockfiles in every GitHub repo you pick, finds each project with an affected org.apache.xmlgraphics:batik, and gives you the command that fixes it.
More advisories for org.apache.xmlgraphics:batik
- HighCVE-2022-41704Apache XML Graphics Batik vulnerable to code execution via SVG. · 25 Oct 2022
- HighCVE-2022-42890Untrusted code execution in Apache XML Graphics Batik · 25 Oct 2022
- HighCVE-2022-40146Apache Batik vulnerable to Server-Side Request Forgery · 23 Sept 2022
- MediumCVE-2022-38648Apache Batik vulnerable to Server-Side Request Forgery · 23 Sept 2022
- MediumCVE-2022-38398Apache Batik Server-Side Request Forgery · 23 Sept 2022
- MediumCVE-2015-0250Improper Input Validation in Apache Batik · 17 May 2022
References
- Advisorynvd.nist.gov/vuln/detail/CVE-2018-8013
- Linkgithub.com/apache/xmlgraphics-batik/commit/f91125b26a6ca2b7a1195f1842360bed03629839
- Linkxmlgraphics.apache.org/security.html
- Linkwww.oracle.com/technetwork/security-advisory/cpujul2019-5072835.html
- Linkwww.oracle.com/technetwork/security-advisory/cpujan2019-5072801.html
- Linkwww.oracle.com/technetwork/security-advisory/cpuapr2019-5072813.html
- Linkwww.oracle.com/security-alerts/cpuoct2020.html
- Linkwww.oracle.com/security-alerts/cpujul2020.html
- Linkwww.debian.org/security/2018/dsa-4215
- Linkusn.ubuntu.com/3661-1
- Linkubuntu.com/security/CVE-2018-8013
- Linksecurity.gentoo.org/glsa/202401-11
- Linkmail-archives.apache.org/mod_mbox/xmlgraphics-batik-dev/201805.mbox/%3c000701d3f28f%24d01860a0%24704921e0%24%40gmail.com%3e
- Linkmail-archives.apache.org/mod_mbox/xmlgraphics-batik-dev/201805.mbox/%3c000701d3f28f$d01860a0$704921e0$@gmail.com%3e
- Linklists.debian.org/debian-lts-announce/2018/05/msg00016.html
- Linklists.apache.org/thread.html/rc0a31867796043fbe59113fb654fe8b13309fe04f8935acb8d0fab19@%3Ccommits.xmlgraphics.apache.org%3E
- Linklists.apache.org/thread.html/rc0a31867796043fbe59113fb654fe8b13309fe04f8935acb8d0fab19%40%3Ccommits.xmlgraphics.apache.org%3E
- Linklists.apache.org/thread.html/r9e90b4d1cf6ea87a79bb506541140dfbf4801f4463a7cee08126ee44@%3Ccommits.xmlgraphics.apache.org%3E
- Linklists.apache.org/thread.html/r9e90b4d1cf6ea87a79bb506541140dfbf4801f4463a7cee08126ee44%40%3Ccommits.xmlgraphics.apache.org%3E
- Linkissues.apache.org/jira/browse/BATIK-1222
Advisory data from OSV.dev (opens OSV.dev in a new tab), refreshed daily.