google / google/langfun

Security ---- Unsandboxed code execution in PythonFunction

Open
#693 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
915
Forks
81
Avg merge
21d 21h
Merged PRs (30d)
7

Description

## Summary
A security issue exists in `PythonFunction.implementation` in
`langfun/core/coding/python/generation.py`.

The method calls `execution.run()` without explicit sandboxing,
which can allow arbitrary code execution in the host process when
processing untrusted input (LLM output, MCP server responses).

## Fix
A patch has been submitted in PR #692
## Disclosure
Reported to Google OSS VRP. Full details available upon request
to maintainers.

Would appreciate a review and merge of the linked PR.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.