Skip to content

Sync missing CVE/security fixes from upstream - #80

Merged
prashantbytesyntax merged 1 commit into
masterfrom
cve-sync-from-upstream
Aug 19, 2026
Merged

Sync missing CVE/security fixes from upstream#80
prashantbytesyntax merged 1 commit into
masterfrom
cve-sync-from-upstream

Conversation

@artursarlo

Copy link
Copy Markdown

Summary

This PR backports security fixes that landed in upstream (intel/gprofiler) but were never synced into our fork. The two forks diverged in May 2024, and a scan of upstream's CVE-related PRs found three runtime/build hardening changes we are missing. Each change below mirrors upstream exactly.

Changes & rationale

1. Bump pytest to 9.0.3 (+ pytest-rerunfailures==15.0)

Backports intel/gprofiler#1035.

  • CVE-2025-71176 (Medium, CVSS 6.8): pytest through 9.0.2 on UNIX relies on directories with the /tmp/pytest-of-{user} name pattern, which allows local users to cause a denial of service or possibly gain privileges via the predictable tmpdir handling.
  • Fix: upgrade to pytest 9.0.3+.
  • pytest-rerunfailures==15.0 is added alongside for pytest 9.x compatibility, matching upstream.

Test/dev dependency only — not shipped in the profiler runtime.

2. Pin Alpine base image to 3.24.1

Backports intel/gprofiler#1010 (later bumped to 3.24.1 in intel/gprofiler#1046).

  • Our container.Dockerfile used FROM alpine (floating latest), which is non-reproducible and can silently pull a stale/vulnerable image from cache.
  • Setting an explicit tag addresses security vulnerabilities in older Alpine images and guarantees a reproducible base.

3. Add backports.tarfile==1.2.0 + pyinstaller hidden import

Backports the tarfile-extraction hardening from intel/gprofiler#1010.

  • Adds backports.tarfile==1.2.0 to requirements.txt.
  • Declares hiddenimports=['backports.tarfile'] in pyinstaller.spec so the module is bundled into the PyInstaller executable.

Notes

  • Unrelated upstream changes bundled in the same PRs (e.g. the cpuid dependency, removal of bitmath) were intentionally excluded — this PR is scoped strictly to the CVE/security fixes.
  • Already-in-sync CVE fixes require no action here: requests==2.33.0 and black==26.3.1 are already present in our fork.

Test plan

  • CI build passes with the pinned Alpine image and bundled backports.tarfile.
  • Test suite runs on pytest 9.0.3.

- Bump pytest to 9.0.3 (CVE-2025-71176) + pytest-rerunfailures 15.0 (intel#1035)
- Pin Alpine base image to 3.24.1 instead of floating latest (intel#1010)
- Add backports.tarfile==1.2.0 and pyinstaller hiddenimport (tarfile hardening)
@prashantbytesyntax
prashantbytesyntax merged commit fdb64cc into master Aug 19, 2026
14 of 19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants