lend Keeps Your Credentials on Your Laptop While Agents Work on Throwaway VMs

Running coding agents without handing them my credentials

lend Keeps Your Credentials on Your Laptop While Agents Work on Throwaway VMs

Antonio built lend, a proxy that sits in front of your SSH agent and forwards its socket to remote VMs. When a coding agent on a VM needs to run gh or use a secret, the request goes to your laptop, where you approve it with Touch ID. The command runs locally, so tokens and SSH keys never leave your machine. lend also supports command policies, biometric approval, leases, and an MCP server for Claude Code.

What I wanted was for the credentials to stay on the laptop and for the commands that need them to run there too. The agent asks to run something, I approve it with Touch ID, and the agent gets the output back.
  1. saagarjha

    I just don’t think I agree with these designs at all. Everyone seems to be super laser focused on “not allowing their AI to have keys” when basically giving their AI direct access to what the keys enable, optionally adding a layer of ceremony in front where you tap “approve”. I’m looking at the alert that is shown there and I don’t see anything that makes me feel like it allows for an informed choice at the time of it popping up. So then, what’s the benefit?

  2. LittleCloud

    I’m surprised how many people just let their LLM agents run free with their credentials. Yeah, I understand doing anything else is complicated, but people’s collective laziness/indifference is how we got so many security and privacy issues today.

    Beyond SSH key forwarding as described in TFA, I’ve also made (with agents of course) a filtering HTTP(S) proxy that injects Authorization credentials, so LLMs operating REST APIs (including commands like Github’s gh) don’t see my private keys either even if they try to hack my environment (which is sandboxes). Anybody else doing that?

  3. ryanczak

    Docker sandboxes support secret injection. https://docs.docker.com/reference/cli/sbx/secret/set/

  4. __MatrixMan__

    My solution to this is two laptops. No SSH between them, just a custom http API. Agents can run amok on the laptop without the secrets, but if they want to act as me, they have to use the API. If they need to do something not already in the API, they can add commits to the server, but I'm going to review those before I deploy that server on the laptop with the keys. This way I don't have to rely on the downstream services to have sufficiently granular permissions.

    I guess I could do the same thing with VM's, but for reasons I can't fully explain it's just easier to stay vigilant with separate hardware.

  5. knocte

    > I often have them review each other's work too. None of them run on my laptop. They run on VMs I can throw away,

    Good approach. I myself found issues with a VM approach such as latency (if the VM is in the cloud), efficiency (if the VM is local) and laziness to automate the VM creation & setup. So instead I just hand the agent an unprivileged user account in my system and stop worrying. I built a little tool to setup this: https://github.com/tarsgate/skynot

  6. zmmmmm

    They seem oblivious to secret replacement via TLS interception which are auto-supported in multiple existing microvm frameworks. These give you a straightforward way to not only shield the token but also limit the scope of the requests (eg: only particular projects on github rather than all of them, etc).

  7. h4kunamata

    For bash and python scripting I just use keepassxc-cli.

    Tokens in general is "never exposed":

    keepassxc-cli show --no-password -k $KEEPASS_KEY $KEEPASS_DB "GROUP_GOES_HERE/SECRET_NAME_HERE" --attributes Password

    When dealing with agents, they access the tokens the same way, it is the best balance I found between keeping things safe without adding too much complexity making my life harder.

    It can save tho, have the code to also save access_token to the vault the same way, so no log/execution will ever show the secrets.

    Tokens the agents use, are read-only with the minimalist access.

    Never ever ever grant an agent access to any token with destructive access, unless you accepted the risks.

  8. LeBit

    Nono does that.

    Smolvm does that.

    I make use of that feature which is super neat.

    One problem with that though is when you need to use such a credential on a tailscale node. It bypasses the proxy of those tools.

More from this day

2026-11-17