Summary
act's built-in actions/cache server exposes an unauthenticated cache API on all network interfaces, allowing any reachable party to create and read cache entries.
An attacker who can connect to the cache server and predict cache keys used by local workflows may inject malicious cache contents, which can lead to arbitrary code execution inside the runner's Docker containers.
Affected context
This vulnerability affects environments where the act GitHub Actions runner is used with its built-in actions/cache server enabled and reachable over the network.
It is particularly risky when:
- act is run on machines that are directly or indirectly exposed to untrusted networks (including the public internet or shared corporate networks),
- the cache service listens on all interfaces without host-level firewalls or network access controls, and
- workflows rely on cached artifacts that are later executed or used as part of build/test steps.
Exploit preconditions
- Attack surface: Network-accessible cache server used by act's actions/cache implementation.
- Required access: Ability to establish a TCP connection to the cache service address/port (no authentication required).
- Trigger point: Use of actions/cache (or compatible logic) within a workflow that:
- reads from cache keys the attacker can predict, or
- restores files that influence build scripts, binaries, or runtime configuration.
- Why exploitation is possible: The cache API does not enforce authorization or client identity checks, and it listens on all interfaces. Any client that can reach the service can create, overwrite, and read caches, enabling cache poisoning and data exfiltration.
Why this happens
The underlying issue is a lack of authorization checks on a network-exposed service, corresponding to CWE-862: Missing Authorization.
The actions/cache server in act:
- binds to all network interfaces, unintentionally broadening its exposure, and
- accepts cache creation and retrieval operations from any client without verifying identity, permissions, or workflow association.
This design assumes a trusted local-only environment but does not technically enforce that trust boundary, leaving the service open to abuse when the host is reachable from untrusted networks.
Potential impact
- Remote modification of cache contents used by local GitHub Actions workflows.
- Cache poisoning leading to execution of attacker-controlled scripts or binaries within Docker containers.
- Exfiltration of cached artifacts, dependencies, or build outputs that may contain sensitive information.
- Interference with CI workflows, causing builds to fail, pass incorrectly, or produce compromised artifacts.
- Potential lateral movement if compromised workflows interact with other internal services or credentials.
General mitigation guidance
Effective mitigation focuses on restricting access to the cache service and enforcing trust boundaries around build artifacts:
- Network isolation: Prefer binding local services to loopback interfaces only and using host firewalls or container network policies to restrict access to localhost.
- Authorization & identity checks: Employ patterns where internal services validate client identity (e.g., via tokens, mTLS, or signed requests) before accepting cache operations.
- Defensive cache usage: Treat cache contents as untrusted:
- Avoid executing binaries or scripts directly from cache without integrity checks.
- Use cryptographic signatures, checksums, or reproducible builds to validate cached artifacts.
- Least-privilege containers: Run workflows in containers with minimal privileges, constrained filesystem access, and restricted capabilities, limiting the blast radius if cache poisoning occurs.
- Separation of secrets and artifacts: Ensure secrets are never stored in caches and keep sensitive data separate from mutable, shared build outputs.
How teams detect issues like this
Organizations can look for this class of issue and its symptoms using:
- Configuration and infrastructure review:
- Identify services that bind to 0.0.0.0 or unspecified addresses.
- Confirm that development/CI helpers (like act) are not exposed beyond localhost.
- Static and code-level analysis:
- Audit internal service endpoints for missing authorization middleware or access control checks.
- Search for cache or artifact services that do not associate requests with authenticated principals or workflows.
- Network monitoring and logging:
- Enable detailed logs for cache requests, including client IP and requested keys.
- Monitor for unexpected external IPs accessing cache services or unusual cache activity patterns.
- Policy enforcement in CI/CD:
- Use Git hooks, CI checks, or automated security review tools to flag configurations that expose local tooling services externally.

