Bug 1214422 (CVE-2022-46751)

Summary: VUL-0: CVE-2022-46751: apache-ivy: improper restriction of XML External Entity Reference
Product: [Novell Products] SUSE Security Incidents Reporter: Alexander Bergmann <abergmann>
Component: IncidentsAssignee: Gus Kenion <gus.kenion>
Status: RESOLVED FIXED QA Contact: Security Team bot <security-team>
Severity: Major    
Priority: P3 - Medium CC: gus.kenion, security-team, stoyan.manolov
Version: unspecified   
Target Milestone: ---   
Hardware: Other   
OS: Other   
URL: https://smash.suse.de/issue/375837/
Whiteboard: CVSSv3.1:SUSE:CVE-2022-46751:7.3:(AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L)
Found By: Security Response Team Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Alexander Bergmann 2023-08-21 06:52:57 UTC
CVE-2022-46751

Posted by Stefan Bodewig on Aug 20Severity: moderate

Affected versions:

- Apache Ivy 1.0.0 through 2.5.1

Description:

Improper Restriction of XML External Entity Reference, XML Injection (aka Blind XPath Injection) vulnerability in 
Apache Software Foundation Apache Ivy.This issue affects any version of Apache Ivy prior to 2.5.2.

When Apache Ivy prior to 2.5.2 parses XML files - either its own configuration, Ivy files or Apache Maven POMs - it 
will allow downloading external document type definitions and expand any entity references contained therein when used.

This can be used to exfiltrate data, access resources only the machine running Ivy has access to or disturb the 
execution of Ivy in different ways.

Starting with Ivy 2.5.2 DTD processing is disabled by default except when parsing Maven POMs where the default is to 
allow DTD processing but only to include a DTD snippet shipping with Ivy that is needed to deal with existing Maven 
POMs that are not valid XML files but are nevertheless accepted by Maven. Access can be be made more lenient via newly 
introduced system properties where needed.

Users of Ivy prior to version 2.5.2 can use Java system properties to restrict processing of external DTDs, see the 
section about "JAXP Properties for External Access restrictions" inside Oracle's "Java API for XML Processing (JAXP) 
Security Guide".

Upstream commit:
https://gitbox.apache.org/repos/asf?p=ant-ivy.git;a=commit;h=2be17bc18b0e1d4123007d579e43ba1a4b6fab3d

Credit:
CC Bomber, Kitri BoB (finder)
Jenkins Security Team (reporter)

References:
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2022-46751
https://seclists.org/oss-sec/2023/q3/116
https://docs.oracle.com/en/java/javase/13/security/java-api-xml-processing-jaxp-security-guide.html#GUID-94ABC0EE-9DC8-44F0-84AD-47ADD5340477
https://lists.apache.org/thread/9gcz4xrsn8c7o9gb377xfzvkb8jltffr
Comment 1 OBSbugzilla Bot 2023-08-22 00:15:02 UTC
This is an autogenerated message for OBS integration:
This bug (1214422) was mentioned in
https://build.opensuse.org/request/show/1105156 Factory / apache-ivy
Comment 3 Gus Kenion 2023-10-31 14:30:11 UTC
Submitted request to update Apache Ivy to 2.5.2, which includes a fix for this issue.
Comment 5 Maintenance Automation 2023-11-06 08:30:05 UTC
SUSE-SU-2023:4367-1: An update that solves one vulnerability can now be installed.

Category: security (important)
Bug References: 1214422
CVE References: CVE-2022-46751
Sources used:
openSUSE Leap 15.4 (src): apache-ivy-2.5.2-150200.3.9.1
openSUSE Leap 15.5 (src): apache-ivy-2.5.2-150200.3.9.1
Development Tools Module 15-SP4 (src): apache-ivy-2.5.2-150200.3.9.1
Development Tools Module 15-SP5 (src): apache-ivy-2.5.2-150200.3.9.1
SUSE Linux Enterprise High Performance Computing 15 SP2 LTSS 15-SP2 (src): apache-ivy-2.5.2-150200.3.9.1
SUSE Linux Enterprise High Performance Computing ESPOS 15 SP3 (src): apache-ivy-2.5.2-150200.3.9.1
SUSE Linux Enterprise High Performance Computing LTSS 15 SP3 (src): apache-ivy-2.5.2-150200.3.9.1
SUSE Linux Enterprise Server 15 SP2 LTSS 15-SP2 (src): apache-ivy-2.5.2-150200.3.9.1
SUSE Linux Enterprise Server 15 SP3 LTSS 15-SP3 (src): apache-ivy-2.5.2-150200.3.9.1
SUSE Linux Enterprise Server for SAP Applications 15 SP2 (src): apache-ivy-2.5.2-150200.3.9.1
SUSE Linux Enterprise Server for SAP Applications 15 SP3 (src): apache-ivy-2.5.2-150200.3.9.1
SUSE Enterprise Storage 7.1 (src): apache-ivy-2.5.2-150200.3.9.1

NOTE: This line indicates an update has been released for the listed product(s). At times this might be only a partial fix. If you have questions please reach out to maintenance coordination.