← Back to context

Comment by solarkraft

4 days ago

Security misalignments OpenCode has a good few of (it used to have more).

I think the benefits of this one vastly outweigh the risks since it enables the self-modification Pi (!) became famous for.

These debates should be settled with an opinionated default, and a toggle.

  • This right here.

    There does not seem to be a flag for this, not finding any configuration options yet either, and there is the shared server aspect now too.

I switched to Pi last week, have not seen anything about self modification, but have seen a lot about security, the minimalism and customization by user are closest in common selling points from exiting users

you cannot have both and be serious about security

to be clear, I'm talking about hot reload, agent can manipulate its own environment in real time, that's asking for trouble, put some controls on that or reap the consequences from loss of control

  • Unless I’m out of the loop, Pi can self modify in the sense that plugins are just code it can edit. It doesn’t live reload that I’m aware of.

    Pi’s whole UI is customizable, so a lot of people were having their agents build their own interfaces.

    The distinction is probably irrelevant for most people. I secure the whole thing in a container, because I lack the willpower to audit a bajillion lines of LLM code just inside the harness.

    • See my peer comment for some other thoughts.

      What stops your agent from adding a new MCP server on its own? Would you consider that a gap in security posturing?

      9 replies →

  • > you cannot have both and be serious about security

    Why not? I think DSH does this pretty well with an agent preset that exposes the tools required for the agent to modify the harness.

    It's kind of like how the kernel can expose interfaces to allow userspace to load kernel modules at runtime: you "just" have to control which processes can use them.

    Between that, and a couple of extra injected bwrap args to make my SSH keys and LLM API credentials unreadable from the agent's shell by default, I'm pretty comfortable using the harness outside of a VM for most things.

    • > Why not?

      If an agent can change the harness it is running in, in real-time, all bets are off

      There is semantic ambiguity here. An agent being able to write plugin code for the harness it runs in is related, but orthogonal, to the real-time or not availability of that plugin to the current session.

      When I have my agents assist with plugins, I pay closer attention and either do the testing myself or have them run the altered harness in another instance.

      Part of this is because they have borked themselves and it can be super annoying to undo their f-ups. Little qwen did this once, breaking its own connection to vllm.

      2 replies →

  • > have not seen anything about self modification

    It was the big selling point of the harness a couple months ago.

    • I suspect there is a bit of language inflation going on here.

      1. agent != harness, Pi is a harness, agents running under Pi can do things, Pi is not the actor or agent

      2. self modification vs Pi supports customization / extension / plugin

      3. hot-reload (real time modification) vs restart/reload (agent can be blocked)

      but "self modification" sounds cooler, I guess