Security: Fix critical OS mode auto-run and remote profile RCE#1741
Open
johnpippett wants to merge 1 commit intoopeninterpreter:mainfrom
Open
Security: Fix critical OS mode auto-run and remote profile RCE#1741johnpippett wants to merge 1 commit intoopeninterpreter:mainfrom
johnpippett wants to merge 1 commit intoopeninterpreter:mainfrom
Conversation
…ile exec - Change interpreter/terminal_interface/profiles/defaults/os.py: - Set auto_run=False and loop=False by default - Remove forced auto_run=True override - Update warning message to reflect approval-required default - Change interpreter/terminal_interface/profiles/profiles.py: - Disallow downloading and executing remote .py profiles - Add source URL guard in apply_profile to prevent exec() of remote start_script Addresses critical findings from security audit 2026-04-28.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes two critical security findings identified in audit 2026-04-28.
1. OS mode defaults to unattended execution with full system control
File:
interpreter/terminal_interface/profiles/defaults/os.pyauto_rundefault fromTruetoFalseloopdefault fromTruetoFalseauto_run = Trueoverride at the end of the profile2. Profile loading executes arbitrary code from remote URLs
File:
interpreter/terminal_interface/profiles/profiles.py.pyprofiles viarequests.get(); now raises a security exceptionsourceparameter toapply_profile()to track the original profile source URL/pathexec()guard that rejectsstart_scriptexecution for any profile sourced from anhttp://orhttps://URLThese are minimal, surgical changes that preserve local
.pyprofile functionality while eliminating the remote arbitrary code execution vector.Test Results
py_compile)<3.13requirement