Form3 has thousands of repositories, and its patch backlog keeps growing. Tools such as Dependabot and Renovate can update manifest versions, but may miss vulnerable packages in base images or downloaded binaries. Related upgrades can also trigger lint failures, so a patch needs to account for the wider CI impact.
We Gave an Agent Production Code Access and Then Tried to Sleep at Night
Speaker
Moritz Johner of Form3 explains how his team built Patch Pilot to remediate dependency vulnerabilities and limit the security risks of giving agents production code access; the talk is on the AI Engineer channel.
Patch Pilot uses a deterministic Go application to discover and scan production OCI images, then link findings to the repositories that built them. A remediation agent receives the CVE assessment and aims for the smallest effective change, then checks the build and rescans the image. The controller vets the changes, commits and opens a PR, and watches CI; a second agent can address failures before the retry limit sends the issue to a human.
The application needs GitHub and registry access, build tools, and network access, but the agent does not receive GitHub write access or permission to trigger CI. The deterministic controller handles commits, pushes, PR creation, and CI actions, which limits the damage a prompt injection could cause. Johner says prompt injection remains unsolved; the team steers the agent away from untrusted files and tests it against crafted malicious repository content.
Giving an agent access to a host Docker socket can let it start a privileged container and escape ordinary sandbox boundaries. Form3 moved away from that setup and explored a Firecracker microVM, where the Docker socket runs under its own kernel. A host process can apply network rules to traffic forwarded through vsock, while the deterministic and agentic parts receive different network policies.
Johner argues that an agent needs an environment with enough freedom to work, while keeping its capabilities contained. He says tools for sandboxing, Docker builds, network controls, and orchestration exist, but many are still early or lack features needed for enterprise use. His closing principle is that deciding which actions are deterministic and which are agentic defines the security model.
Takeaways
- Keep credentials for commits, PRs, and CI in a deterministic controller when the agent does not need them.
- Patch the specific vulnerable artifact and verify the resulting image and CI, rather than applying broad version upgrades.
- Treat repository contents and CI logs as untrusted input; test agents against crafted prompt injection attempts.
- A host Docker socket can undermine an ordinary sandbox; isolate build execution and apply network controls at the VM boundary.
- Collect brief agent retrospectives across PRs to identify recurring infrastructure problems and missing repository context.
Mentioned in this talk
Search inside this talk
What was claimed 8
- works atMoritz Johner works at
Form3
Staff Engineer“Moritz Johner: Thanks, everyone, for joining in.”
YouTube Verified2 sources· Talk, Web· archived
- built
Form3 built
Patch Pilot
“We built Patch Pilot and pushed it to production.”
YouTube Unverified1 source· Talk
- feature
Patch Pilot: Scans OCI images for CVEs and uses agents to make repository changes and remediate CI failures.
“The Go app discovers and scans those images”
YouTube Unverified1 source· Talk
- feature
Patch Pilot: Keeps GitHub write access and CI triggering in the deterministic layer rather than giving those credentials to the agent.
“We did not give the agent. Instead, we pushed that functionality out to the deterministic part”
YouTube Unverified1 source· Talk
- feature
Patch Pilot: Runs end-to-end tests with crafted repositories containing prompt injection attempts.
“we implemented an end-to-end test where we created a repository and sent Patch Pilot to work on it.”
YouTube Unverified1 source· Talk
- uses
Patch Pilot uses Docker
“When it works with Dockerfiles, it wants to build a Docker container.”
YouTube Unverified1 source· Talk
- uses
Patch Pilot uses Firecracker
“In our case, we're using Firecracker for proper isolation.”
YouTube Unverified1 source· Talk
- feature
Microsandbox: Includes network access controls.
“it comes with everything included: network access controls”
YouTube Unverified1 source· Talk











