Arbitrary Code Execution Vulnerability in python-gnupg - CVE-2014-1928

python-gnupg Updated 02 Oct 2025

Summary

25/10/2014
N/A
Yes i
Unrated
Not published

CVE-2014-1928: The shell_quote function in python-gnupg 0.3.5 does not properly escape characters, which allows context-dependent attackers to execute arbitrary code via shell metacharacters in unspecified vectors, as demonstrated usin... Affects python-gnupg versions < 0.3.6-1. Fixed in 0.3.6-1. 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 Your last release was probably never penetration tested Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

python-gnupg is a Python wrapper for GnuPG, allowing developers to integrate GnuPG functionalities into their Python applications. It provides features for encryption, decryption, and signing of data. However, an issue in the shell_quote function of version 0.3.5 has been identified, which fails to properly escape shell metacharacters, making it susceptible to arbitrary code execution.

Vulnerability Detail

The vulnerability, identified as CVE-2014-1928, arises from the shell_quote function in python-gnupg version 0.3.5. It does not adequately escape characters, allowing attackers to execute arbitrary code through shell metacharacters. This can be exploited by injecting commands using backslash characters to create multi-command sequences. The vulnerability is a result of an incomplete fix for a previous issue (CVE-2013-7323), and its ramifications include potential unauthorized access and control over the affected systems.

How To Fix

Minimum fixed version

0.3.6-1

This is the first release that contains the fix.

sudo apt-get install --only-upgrade python-gnupg

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

Workaround

As a temporary workaround, avoid using the vulnerable version (0.3.5) of python-gnupg. If upgrading is not immediately possible, consider implementing input validation to sanitize user inputs and prevent the injection of shell metacharacters.

Conclusion

CVE-2014-1928 is a significant vulnerability in python-gnupg that can lead to arbitrary code execution due to improper handling of shell metacharacters. Users are strongly advised to upgrade to the latest version to mitigate risks associated with this vulnerability.

See every vulnerability recorded for python-gnupg →

Share this vulnerability

FAQ

CVE-2014-1928 is a vulnerability in python-gnupg that allows arbitrary code execution due to improper escaping of shell metacharacters.

Versions prior to 0.3.6-1 are affected, specifically version 0.3.5.

You can use Vulert to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without any signup.

The risks include unauthorized access to systems, execution of arbitrary commands, and potential data breaches.

Yes, upgrading to python-gnupg version 0.3.6-1 or later resolves the vulnerability.

Related vulnerabilities

Recent vulnerabilities recorded for python-gnupg.

How To Fix

Minimum fixed version

0.3.6-1

This is the first release that contains the fix.

sudo apt-get install --only-upgrade python-gnupg

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