Local Privilege Escalation Vulnerability in Python3 on Alpine Linux

python3 Updated 02 Oct 2025

Summary

07/11/2022
N/A
Yes i
High
7.8

ALPINE-CVE-2022-42919: Python 3.9.x before 3.9.16 and 3.10.x before 3.10.9 on Linux allows local privilege escalation in a non-default configuration. Affects python3 versions < 3.10.9-r0. Fixed in 3.10.9-r0. 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 MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

Python3 is a widely-used programming language known for its simplicity and versatility. It supports multiple programming paradigms and is commonly used for web development, data analysis, artificial intelligence, and more. However, certain versions of Python3 on Alpine Linux are susceptible to a local privilege escalation vulnerability due to improper handling of the multiprocessing library when using the forkserver start method.

Vulnerability Detail

The vulnerability arises in Python versions 3.9.x before 3.9.16 and 3.10.x before 3.10.9 on Linux systems. It allows local privilege escalation in non-default configurations. Specifically, when the multiprocessing library is utilized with the forkserver start method, it permits pickles to be deserialized from any user within the same local network namespace. This can lead to arbitrary code execution, allowing a local user to escalate their privileges to that of the user running the forkserver process. This issue is specific to Linux due to its support for abstract namespace sockets, which are not utilized by default in earlier versions of CPython.

How To Fix

Minimum fixed version

3.10.9-r0

This is the first release that contains the fix.

sudo apk add --upgrade python3

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

Workaround

As a temporary workaround, you can set the following configuration in your Python code to mitigate the risk: 'multiprocessing.util.abstract_sockets_supported = False'. This setting disables the use of abstract namespace sockets, reducing the vulnerability surface.

Conclusion

In summary, the local privilege escalation vulnerability in Python3 on Alpine Linux poses a significant risk to users running affected versions. It is crucial to update to the patched version or implement the recommended workaround to mitigate potential exploitation. Regular monitoring with tools like Vulert can help maintain security against such vulnerabilities.

See every vulnerability recorded for python3 →

Share this vulnerability

FAQ

The CVSS score of this vulnerability is 7.8, indicating a high severity level.

Python 3.9.x before 3.9.16 and 3.10.x before 3.10.9 on Linux are affected by this vulnerability.

Local privilege escalation refers to a situation where a user gains elevated access to resources that are normally protected from the user, potentially allowing them to execute arbitrary code.

You can use Vulert's playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.

Vulert is a tool that monitors and alerts for open-source vulnerabilities in software using just a manifest file like package-lock.json, providing real-time insights.

Related vulnerabilities

Recent vulnerabilities recorded for python3.

How To Fix

Minimum fixed version

3.10.9-r0

This is the first release that contains the fix.

sudo apk add --upgrade python3

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