• pixxelkick
    link
    fedilink
    arrow-up
    15
    ·
    3 months ago

    This is pretty much entirely why I built https://github.com/SteffenBlake/cli-mcp-mapper

    I map bespoke CLI commands, with parameters, to MCP tools, and then 100% just turn off the ability to invoke the CLI itself entirely.

    That way it can only explicitly invoke the whitelisted commands I have granted it access to run, with only the parameters I have allowed it to.

    So for example I can explicitly expose git commit, status, stage, unstage, but everything else git related is not available, not even git push or pull.

    This substantially seems to help prevent the LLM from going off the rails on stupid CLI nonsense, like when it starts cating files instead of just fucking reading them.

    • TechLich
      link
      fedilink
      arrow-up
      3
      ·
      3 months ago

      That’s a good idea. Be careful of the more advanced models finding ways to abuse/circumvent it though, even with only a limited set of parameters. Eg. A lot of git commands can be tricked into dropping into less which can drop into a full shell.

      They know all the gtfobins.org tricks.

      • pixxelkick
        link
        fedilink
        arrow-up
        2
        ·
        3 months ago

        It should theoretically be impossible with the way you set it up.

        You explicitly, opt in, expose which parameters are available to the LLM, it cant invoke any params beyond that.

        And you can set params to hard values that arent exposed.

        Finally, you can use the enum config to further specify a whitelist of valid values for a param, anything else gets rejected.

        This pretty much locks most tools down tight.

        Though, wouldn’t hurt to add integration tests covering scenarios like this explicitly.

  • P03 Locke@lemmy.dbzer0.com
    link
    fedilink
    English
    arrow-up
    9
    ·
    3 months ago

    This is why all of the claims that “Claude broke containment” are pure hype. They know how to truly design a secure box. They just don’t want to and put out headlines to boast its hacking skills.

    You want it secure for experimental model security testing?

    • No VMs
    • Physical hardware
    • Physically disconnected from the internet

    For the rest of us who ain’t doing that shit, a properly segregated dev network with firewalled access will suffice.

    • flying_sheep@lemmy.ml
      link
      fedilink
      arrow-up
      2
      ·
      3 months ago

      Doesn’t even need to be completely air gapped, they can still allow it to talk to one specific endpoint to e.g. actually drive the model. As long as all commands are executed on a machine that can’t reach the Internet, all is safe.

      I don’t actually doubt anything in the big post they sent out. I just doubt that running a LLM without the possibility of alignment drift is possible. It just doesn’t seem like they work that way.

    • eleitl@lemmy.zip
      link
      fedilink
      arrow-up
      3
      ·
      3 months ago

      Even if your tools have been all verified with formal proofs you can still attack the hardware directly as a side channel.