How to Configure Flowise SSH Prevent Delete

Published
Length
3 min read

Luis Felipe Dias

All posts

To set up a flowise ssh prevent delete rule, restrict the target shell account and use signed OpenSSH certificates. You also need command checks to stop AI agents from running file removal calls. Many teams link visual AI builders to remote servers with a shared key. When that account has full write rights, one bad prompt can wipe out host files. A safe setup strips out broad rights and blocks destructive calls before they run. How flowise ssh prevent delete works in native OpenSSH Visual AI

SSH Access Management + End-to-End Encryption: 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 a flowise ssh prevent delete rule, restrict the target shell account and use signed OpenSSH certificates. You also need command checks to stop AI agents from running file removal calls. Many teams link visual AI builders to remote servers with a shared key. When that account has full write rights, one bad prompt can wipe out host files. A safe setup strips out broad rights and blocks destructive calls before they run.

How flowise ssh prevent delete works in native OpenSSH

Visual AI tools often run remote tasks on Linux hosts over SSH. Native OpenSSH gives you a few ways to lock down what that login can do. First, you can switch from static keys to OpenSSH certificates. A certificate holds a public key, identity info, principal names, and signed options from a CA key. OpenSSH added this simple certificate format in version 5.4.

When you sign a user key, you set the identity and list the allowed principals. You can also embed certificate options that restrict what the session can do. On the target host, the Linux admin pairs this certificate with a locked-down system account. The admin sets file permissions so the agent account can read logs or run safe scripts. The OS file tree blocks the account from removing files owned by other users.

Admins can also set a forced command in the key options or certificate options. When the AI tool starts a session, the server runs only that preset script. It ignores any raw shell string sent by the workflow. If you map the login to a read-only wrapper script, the agent cannot pass a delete call to the shell.

Where native host permissions fall short for AI workflows

Host accounts and forced scripts work well when an AI workflow does only one static job. Yet most teams build agents to fix issues, check services, and update app state. Those tasks need flexible shell commands and write rights inside app folders. Once a Linux user owns a folder, standard OS permissions let that user both write and delete files inside it.

Native OpenSSH checks who logs in at the start of a session. It does not parse individual shell commands inside an open channel to spot a delete flag. Building a custom bash wrapper to parse every possible delete syntax is brittle and hard to maintain. Attackers or confused models can bypass simple text filters with subshells, scripts, or aliases. Teams also struggle when a workflow needs to remove a temp file with human approval.

SSH Access Management + End-to-End Encryption: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Adding command checks and human approval for risky calls

To stop bad deletes without breaking useful workflows, you must check commands in flight. First, map each AI agent to its own distinct identity rather than a shared server account. Second, keep raw SSH private keys out of the visual builder store. Third, inspect every shell command before it reaches the remote host.

When the workflow sends a command that removes files or folders, the check should pause or block it. Safe read commands can run right away. Destructive calls can wait for a human on the team to review and approve them in Slack or Teams. If the server output contains sensitive text like emails, phone numbers, card numbers, or national IDs, data masking rewrites matched fields in results.

Add command and file guardrails to SSH access

Host firewalls and certificate principals control who opens an SSH session. Yet an allowed user or agent can still run a bad one-shot command or pull sensitive files over sftp. In practice, hoop.dev provides an open-source SSH server with guardrails on the host that uses OpenSSH certificates.

Using hoop.dev SSH controls, guardrails check one-shot commands, env variable names, and sftp or scp paths before they run. Port forwards default to deny unless the target is listed. Because interactive shells have no statement boundary and carry no guardrails, teams can turn them off so every command is checked and logged. Check out the MIT-licensed project on GitHub.

Frequently asked questions

Can Linux file permissions alone stop an AI agent from deleting files?

Linux permissions can block deletes in folders owned by root or other users. Still, if the agent needs to create or edit files in a directory, standard write permissions on that directory also allow file deletion unless you set special sticky bits.

How do OpenSSH certificates help secure automated workflows?

An OpenSSH certificate binds a public key to specific principals and options signed by your CA key. You can set a short validity window when signing so the credential expires on its own, unlike a static public key.

What is the safest way to let a Flowise agent run a cleanup script?

Do not give the agent open shell rights to run raw delete commands. Instead, allow only a specific script path and require a real-time human approval step before any file removal runs on the host.

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.