CVE-2025-32798

9.8 CRITICAL

📋 TL;DR

CVE-2025-32798 allows arbitrary code execution during conda package builds due to unsafe eval() usage in recipe selectors. Attackers can inject malicious code into meta.yaml files to execute commands on build systems. This affects anyone using conda-build to create or process conda packages.

💻 Affected Systems

Products:
  • conda-build
Versions: All versions prior to 25.4.0
Operating Systems: All platforms where conda-build runs (Linux, macOS, Windows)
Default Config Vulnerable: ⚠️ Yes
Notes: Vulnerability is present in default configuration when processing any meta.yaml file with selectors.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete compromise of build infrastructure leading to supply chain attacks, credential theft, lateral movement, and persistent backdoors in distributed packages.

🟠

Likely Case

Malicious package maintainers or compromised repositories executing arbitrary code on developer/build systems to steal credentials or modify other packages.

🟢

If Mitigated

Limited to isolated build environments with no network access or sensitive data, resulting in minimal impact.

🌐 Internet-Facing: MEDIUM - Build servers exposed to internet could be targeted via malicious package submissions or repository compromises.
🏢 Internal Only: HIGH - Internal developers and CI/CD pipelines processing untrusted packages are at significant risk of compromise.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: LIKELY
Unauthenticated Exploit: ✅ No
Complexity: LOW

Exploitation requires ability to modify or submit meta.yaml files to conda-build, which could occur through package repositories, CI/CD pipelines, or developer workflows.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 25.4.0

Vendor Advisory: https://github.com/conda/conda-build/security/advisories/GHSA-6cc8-c3c9-3rgr

Restart Required: No

Instructions:

1. Update conda-build using: conda update conda-build
2. Or install specific version: conda install conda-build=25.4.0
3. Verify installation with: conda-build --version

🔧 Temporary Workarounds

Disable selector processing

all

Avoid processing meta.yaml files with embedded selectors by using static configurations

Use --no-selectors flag if available in your workflow
Manually review and sanitize all meta.yaml files before processing

Isolate build environments

all

Run conda-build in isolated containers or VMs with minimal privileges

docker run --rm -v $(pwd):/build conda/miniconda3 conda-build /build
Use CI/CD systems with ephemeral build environments

🧯 If You Can't Patch

  • Implement strict code review for all meta.yaml files before build processing
  • Run conda-build in sandboxed environments with no network access or sensitive credentials

🔍 How to Verify

Check if Vulnerable:

Run: conda-build --version and check if version is less than 25.4.0

Check Version:

conda-build --version

Verify Fix Applied:

Confirm conda-build version is 25.4.0 or higher with: conda-build --version

📡 Detection & Monitoring

Log Indicators:

  • Unexpected process execution during conda-build runs
  • Suspicious commands in build logs
  • Failed build attempts with unusual error patterns

Network Indicators:

  • Unexpected outbound connections from build systems during package processing
  • Downloads from unusual sources during builds

SIEM Query:

process_name:"conda-build" AND (command_line:"eval" OR command_line:"exec" OR command_line:"import os" OR command_line:"subprocess")

🔗 References

📤 Share & Export