How to Configure Windsurf SSH Read Only Access

Published
Length
3 min read

Luis Felipe Dias

All posts

To set up windsurf ssh read only access, create a restricted Linux user and bind an OpenSSH key to a read-only wrapper script. You can also sign short-lived OpenSSH user certificates that lock the session to one safe command. Many teams start by giving their coding agent the developer's own SSH key. That shortcut lets the AI agent run any shell command that the human engineer can run. If a prompt goes wrong, an overly broad role lets the agent change files or restart services. How windsurf ssh

Auditor Read-Only Access + SSH Access Management: the complete guide

Architecture patterns, implementation strategies, and security best practices. Delivered to your inbox.

Free white paper. No spam. Unsubscribe anytime.

To set up windsurf ssh read only access, create a restricted Linux user and bind an OpenSSH key to a read-only wrapper script. You can also sign short-lived OpenSSH user certificates that lock the session to one safe command. Many teams start by giving their coding agent the developer's own SSH key. That shortcut lets the AI agent run any shell command that the human engineer can run. If a prompt goes wrong, an overly broad role lets the agent change files or restart services.

How windsurf ssh read only access works at the host level

In June 2026, Cognition renamed Windsurf to Devin Desktop, while keeping the same IDE features. Its agent can run terminal commands on its own after the user gives permission. The IDE opens a dedicated shell on macOS or Linux and loads the user's normal shell profile. Because that shell inherits local aliases, variables, and SSH keys, the agent reaches remote hosts like the user.

OpenSSH does not have a single toggle that turns a shell session into a read-only mode. Instead, Linux admins combine two controls on the remote host to block write actions. First, they create a dedicated Linux account that has no write permissions on app folders or system files. This user belongs only to groups that can read log files and inspect running status.

Second, admins restrict what the SSH key or OpenSSH certificate is allowed to run during login. OpenSSH certificates hold a public key, identity info, principal names, and options signed by a CA key. When the server checks the key, it can force the session to run one specific wrapper script. That script checks the incoming command string and allows only safe read commands to run on the host.

Why host accounts and forced commands fall short in production

Host-level users and OpenSSH options solve the first problem of who is allowed to log in. They stop an AI agent from logging in as root or using an admin account. A forced script also stops the agent from opening a raw interactive shell on the server.

Still, maintaining wrapper scripts across dozens of servers creates a heavy burden for platform teams. Shell syntax is tricky to parse with simple text matching rules inside a bash script. An agent might chain commands, use pipes, or call a flag that changes state on the host. If the wrapper script misses one flag, a read tool can still overwrite a local file.

Auditor Read-Only Access + SSH Access Management: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Linux file permissions also struggle when an agent needs to read live app logs or system metrics. Many log files hold raw customer emails, phone numbers, or card numbers inside error traces. A standard Linux read permission gives the agent the entire file without filtering those sensitive fields. Also, standard SSH setup happens at login time and does not ask a human to approve risky commands in flight.

Best practices for safer agent SSH sessions

Start by separating the AI agent's SSH identity from the engineer's personal workstation keys. Never let the IDE shell load a key that has sudo rights on remote hosts. Give the agent a distinct principal name so server logs show which commands came from the IDE.

Keep certificate lifetimes short when you sign keys with your OpenSSH authority key. By default, a signed OpenSSH user certificate remains valid forever unless you set a window. Short windows make sure that a leaked key or old session cannot reach your hosts the next day. Finally, pair host controls with command-level checks and data masking so sensitive fields get rewritten in output.

Inspect one-shot SSH commands and file tasks

SSH certificates and host rules decide who is allowed on a machine. Setup alone does not check single commands or block sftp reads on sensitive paths. By design, hoop.dev runs an inline open-source SSH listener on the host where engineers and AI agents keep their normal ssh, sftp, and scp tools. On every production command or file operation, hoop.dev decides whether to pass, mask, block, or hold it for approval.

First, hoop.dev guardrails check one-shot commands and file paths before they run, and hoop.dev data masking masks matched values in file downloads. The audit trail logs the certificate principal, requested action, and verdict without storing session content. Interactive shells carry no guardrails and can be turned off when every action must be checked. Explore the code on GitHub.

Frequently asked questions

Does Devin Desktop use the same SSH setup as Windsurf?

Yes, Devin Desktop is the new name for Windsurf and keeps the same IDE and terminal behavior. Its agent runs commands in a dedicated shell that loads your standard local SSH settings and keys.

Can OpenSSH certificates make an SSH session read-only by themselves?

No, OpenSSH certificates only handle login checks, principal matching, and forced command rules. You still need a restricted Linux user or a command filter to block write actions during the session.

How do you stop an SSH agent from seeing sensitive log data?

Linux file permissions only grant all-or-nothing read access to a log file. To protect sensitive data, you must rewrite matched emails, phone numbers, or card numbers before output reaches the IDE.

Save the open-source gateway.

hoop is MIT-licensed infrastructure for controlling how AI agents reach production data. Star hoophq/hoop so you can inspect it, deploy it, or share it when your team starts governing agent access.