CVE-2018-1000844: XML External Entity (XXE) vulnerability in Square Retrofit

Summary

21/12/2018
Yes i
Critical
9.1

CVE-2018-1000844: XML External Entity (XXE) vulnerability in Square Retrofit. Affects com.squareup.retrofit2:retrofit versions >= 2.0.0, < 2.5.0. Fixed in 2.5.0. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

Square Retrofit is an open-source library for making HTTP requests in Android and Java applications. It provides a simple and flexible way to interact with RESTful APIs. The library is widely used in various projects and offers features such as request customization, response parsing, and error handling. However, versions prior to commit 4a693c5aeeef2be6c7ecf80e7b5ec79f6ab59437 are vulnerable to an XML External Entity (XXE) vulnerability in JAXB.

Vulnerability Detail

The XML External Entity (XXE) vulnerability in Square Retrofit allows an attacker to exploit the JAXB component, potentially leading to remote file reading or Server-Side Request Forgery (SSRF) attacks. By sending specially crafted XML data, an attacker can trigger the parsing of external entities, which can result in unauthorized access to files on the file system or the ability to make requests to internal resources. This vulnerability has been assigned a CVSS score of 9.1 (Critical).

How To Fix

Minimum fixed version

2.5.0

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

There is no known workaround for this vulnerability. It is essential to upgrade to the fixed version of Retrofit to mitigate the risk.

Conclusion

The XML External Entity (XXE) vulnerability in Square Retrofit can pose a significant risk to applications using vulnerable versions of the library. It is crucial to upgrade to the fixed version (2.5.0 or later) to mitigate the risk of unauthorized file access or SSRF attacks. For further support on vulnerability remediation, please contact DevNack.com.

See every vulnerability recorded for com.squareup.retrofit2:retrofit →

Share this vulnerability

FAQ

An XML External Entity (XXE) vulnerability is a type of attack that exploits the processing of XML data by an application. By including external entities in the XML, an attacker can read files from the file system or perform SSRF attacks.

JAXB (Java Architecture for XML Binding) is a Java API for mapping XML to Java objects and vice versa. It is commonly used for XML data binding in Java applications.

The XXE vulnerability in Square Retrofit can allow an attacker to read sensitive files from the file system or make unauthorized requests to internal resources. This can lead to information disclosure, data loss, or further exploitation of the affected system.

Yes, upgrading to version 2.5.0 or later of the com.squareup.retrofit2:retrofit package fixes the XXE vulnerability. It is recommended to update the dependency in your project to the latest fixed version.

You can find more information about this vulnerability in the GitHub Advisory Database. Additionally, you can use Vulert (https://vulert.com) to monitor and receive real-time alerts for open-source vulnerabilities in your software.

Related vulnerabilities

Recent vulnerabilities recorded for com.squareup.retrofit2:retrofit.

How To Fix

Minimum fixed version

2.5.0

This is the first release that contains the fix.

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback