unsloth start: warn before running an agent's remote installer - #7024
Merged
Merged
Conversation
When a coding agent is missing, `unsloth start <agent>` offers to run the vendor's own installer (curl | bash, irm | iex, or npm) after an interactive confirm. Those installers execute with the user's privileges and there is no signature or hash check on the fetched content, so a blind "yes" is a supply-chain risk if the delivery path is compromised. Keep the auto-install convenience but make consent informed: before the prompt, name the exact remote source the installer fetches (or the command it runs for a package installer) and state that nothing verifies a signature or hash. Behavior is otherwise unchanged: non-interactive stdin still never executes anything, and the confirm still defaults to no.
Contributor
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
Member
Author
|
@codex review |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
This was referenced Jul 22, 2026
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.
Context
A security review flagged that
unsloth start hermeson Windows, after an interactive confirm, runs the vendor installerirm https://hermes-agent.nousresearch.com/install.ps1 | <scriptblock>with no signature or hash check. The same pattern applies to every agent whose vendor ships a shell installer rather than a package:claude(irm .../install.ps1 | iex),openclaw(iwr -useb .../install.ps1 | iex), and the POSIXcurl | bashvariants. The npm-based agents (codex,opencode,pi) get registry integrity instead.We cannot pin a hash or signature for a third-party remote installer we do not control (the content changes on every upstream release, so a pinned hash would break installs and give false assurance). The realistic hardening is to make the existing consent step fully informed, uniformly across all agents.
Change
_install_agentkeeps the confirm-then-run behavior, but before the prompt it now prints an explicit warning that names the exact source:This will download and RUN a script from <url> with your privileges; there is no signature or hash check.This will RUN \` with your privileges; there is no signature or hash check.`Everything else is unchanged: non-interactive stdin still never executes anything, the confirm still defaults to no, and the command that runs is identical.
Tests
unsloth_cli/tests/test_start.py:powershell -NoProfile -Command ...,/bin/sh -c ...) still pass unchanged.