CVE-2017-3160 in Retail Xstore Point of Serviceinfo

Summary

by MITRE

After the Android platform is added to Cordova the first time, or after a project is created using the build scripts, the scripts will fetch Gradle on the first build. However, since the default URI is not using https, it is vulnerable to a MiTM and the Gradle executable is not safe. The severity of this issue is high due to the fact that the build scripts immediately start a build after Gradle has been fetched. Developers who are concerned about this issue should install version 6.1.2 or higher of Cordova-Android. If developers are unable to install the latest version, this vulnerability can easily be mitigated by setting the CORDOVA_ANDROID_GRADLE_DISTRIBUTION_URL environment variable to https://services.gradle.org/distributions/gradle-2.14.1-all.zip

If you want to get best quality of vulnerability data, you may have to visit VulDB.

Analysis

by VulDB Data Team • 05/07/2025

The vulnerability described in CVE-2017-3160 represents a critical security flaw in the Apache Cordova development framework that specifically affects Android project builds. This issue stems from the default configuration of Cordova's build scripts which attempt to download the Gradle build tool from a non-secure HTTP endpoint rather than the secure HTTPS protocol. The vulnerability becomes exploitable during the initial project setup or when developers first execute build commands on a Cordova Android project, creating a window of opportunity for attackers to intercept and manipulate the downloaded Gradle executable. The timing of this vulnerability is particularly concerning because the build scripts automatically initiate the build process immediately after fetching Gradle, providing minimal opportunity for developers to detect or prevent the malicious interception.

The technical implementation of this vulnerability aligns with CWE-319, which addresses the exposure of sensitive information through improper use of network protocols. The flaw exists in the insecure transmission of critical build dependencies, where the lack of HTTPS encryption creates a man-in-the-middle attack vector that allows adversaries to replace legitimate Gradle distributions with malicious versions. This represents a classic supply chain attack pattern where attackers compromise the build environment rather than targeting the final application. The attack surface is broad as any developer working with Cordova Android projects on networks that are susceptible to interception could be affected, particularly in public Wi-Fi environments or corporate networks with insufficient network security controls.

The operational impact of this vulnerability is severe given that it affects the fundamental build infrastructure of Android applications developed with Cordova. When attackers successfully execute a man-in-the-middle attack, they can inject malicious code into the Gradle build process, potentially compromising all subsequent builds and deployments. This creates a persistent security risk where every application built using the vulnerable Cordova version becomes potentially compromised, as the malicious Gradle distribution could modify the build process to include backdoors or other malicious functionality. The vulnerability is particularly dangerous because it operates silently in the background without developer awareness, and the immediate execution of builds after Gradle download eliminates any manual verification steps that might have otherwise detected the compromise.

Organizations and developers facing this vulnerability should implement immediate mitigation strategies to protect their build environments. The primary recommended solution involves updating to Cordova-Android version 6.1.2 or higher, which addresses the insecure HTTP connection by implementing proper HTTPS protocols for Gradle distribution downloads. When upgrading is not immediately feasible, developers can manually override the default Gradle distribution URL by setting the CORDOVA_ANDROID_GRADLE_DISTRIBUTION_URL environment variable to point to the secure HTTPS endpoint at services.gradle.org. This manual mitigation approach directly addresses the root cause by ensuring that all Gradle downloads occur through encrypted channels, thereby preventing man-in-the-middle attacks and maintaining the integrity of the build process. The vulnerability also highlights the importance of implementing secure development practices and supply chain security measures as outlined in various cybersecurity frameworks and standards that emphasize the need for secure dependency management and encrypted communication channels throughout the software development lifecycle.

Reservation

12/05/2016

Moderation

accepted

Entry

2

Relate

show

CPE

ready

EPSS

0.00341

KEV

no

Activities

very low

Sources

Want to know what is going to be exploited?

We predict KEV entries!