You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, the custom code compiler uses raw exec() to execute user-provided Python code, which could potentially be unsafe as it has unrestricted access to Python builtins and the global namespace.
Proposed Solution
Implement RestrictedPython to provide a safer execution environment for custom code. This will:
Replace current exec() implementation with RestrictedPython's secure execution
Add tests to verify security restrictions are working as expected
Security Considerations
This enhancement will improve the security posture of the custom code execution feature by preventing potentially malicious code from accessing sensitive operations or resources.
The text was updated successfully, but these errors were encountered:
Background
Currently, the custom code compiler uses raw
exec()
to execute user-provided Python code, which could potentially be unsafe as it has unrestricted access to Python builtins and the global namespace.Proposed Solution
Implement RestrictedPython to provide a safer execution environment for custom code. This will:
References
Implementation Notes
exec()
implementation with RestrictedPython's secure executionSecurity Considerations
This enhancement will improve the security posture of the custom code execution feature by preventing potentially malicious code from accessing sensitive operations or resources.
The text was updated successfully, but these errors were encountered: