Flowise WriteFileTool can write files anywhere on the server
What this means
An authenticated person using Flowise can write files to any location on the server, including system directories and configuration files. An attacker could use this to run commands as the user who runs Flowise, take over the entire server, or steal data. This affects every Flowise deployment that allows users to build workflows with the WriteFileTool.
SecurityElites Manager Brief: the decision in one minute
Flowise's file-writing tool does not check whether paths are safe, so authenticated users can write to any file on the server and potentially run code. You need to upgrade Flowise immediately to version 3.0.8 or later and audit whether this was used to modify files.
| SecurityElites Fix-First Score | 51 of 100 Our own ranking of what to fix first. Real attacks count most, then the chance of attack, then severity. |
|---|---|
| SecurityElites fix window | Within 7 days Critical severity. This is our suggestion from common practice; your own policy comes first. |
| Who should own the fix | Platform or infrastructure team |
| Likely effort | About 30 minutes per deployment: download and deploy version 3.0.8 and restart Flowise. Checking logs for misuse will take longer depending on log retention. |
Questions to ask your team or supplier
- Who has authenticated access to our Flowise deployment, and do they all need to be able to build workflows with the WriteFileTool?
- Do we have logs of file write operations in Flowise, and have we searched them for writes to system directories during the time before we upgrade?
- What file system permissions does the Flowise process run with, and can we reduce them to only the directories Flowise needs?
Message you can forward to the owning team
Security notice: Flowise WriteFileTool can write files anywhere on the server (CVE-2025-61913)
Severity: Critical
SecurityElites Fix-First Score: 51 of 100
SecurityElites fix window: Within 7 days
Action: upgrade to flowise 3.0.8, flowise-components 3.0.8, Flowise 3.0.8 or later.
What we need from you: confirm whether we run this software, who owns it, and the date it will be fixed.
Full guide: https://securityelites.com/ai-vulnerabilities/cve-2025-61913-flowise-writefiletool-can-write-files-anywhere-on-the-server/
Source: SecurityElites AI Vulnerabilities Database, record SE-AIV-01660What is at stake in your AI setup
- Workflow definitions and tool configurations: an attacker could modify workflows or inject malicious tools into the Flowise instance.
- API keys and credentials stored in Flowise: an attacker could overwrite configuration files to steal integration keys for external AI services or databases.
- Flowise application code: an attacker could modify or inject code into the Flowise installation directory to persist backdoor access.
- Data on the server: an attacker could read, modify, or delete files the Flowise process can access, including training data, retrieval sources, or logs.
Who is exposed
- Teams that run Flowise in production and allow authenticated users to build or edit workflows
- Deployments where the Flowise process runs with broad file system permissions (such as root or a service account with sudo access)
- Flowise instances where logs of file operations are not retained or monitored
Upgrades you need
| Software | Affected versions | Move to |
|---|---|---|
| flowise npm | Every version before 3.0.8 | 3.0.8 or later |
| flowise-components npm | Every version before 3.0.8 | 3.0.8 or later |
| Flowise npm | Every version before 3.0.8 | 3.0.8 or later |
Am I affected?
Enter the version you run. Nothing you type is stored.
SecurityElites Developer Brief: the technical picture
| Is it being attacked | Working attack code is public, so expect attacks to follow |
|---|---|
| Where the attacker must be | Anywhere that can reach it over a network, including the internet if it is exposed |
| Account needed | An ordinary user account |
| Does a person have to do something | No. It works without anyone clicking or opening anything |
| How hard it is to do | Easy. It works reliably once the attacker can reach it |
| Risk of: data being read | High |
| Risk of: data or settings being changed | High |
| Risk of: the service being taken down | High |
| Can attackers automate it at scale | No, according to CISA. Each target needs manual work |
| How much control an attacker gains | Total control of the affected software, according to CISA |
Read from the official severity rating: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H
Kind of coding mistake
- CWE-22: file paths can escape the allowed folder
If you cannot upgrade today
- Restrict who can access Flowise: limit authentication to trusted users only, using firewall rules, VPN, or authentication middleware to block unauthorized access.
- Disable WriteFileTool: if WriteFileTool is not needed for your workflows, do not expose it in the tool catalog or remove it from the available tools in Flowise configuration.
- Run Flowise with minimal permissions: run the Flowise process as a low-privilege user (not root) with file system access limited to only its working directory and necessary application paths.
Signs it may already have been used against you
- File modification timestamps: check system files in /etc, ~/.ssh, /root, and application directories for unexpected changes during the period Flowise was vulnerable.
- Access logs: look for file write operations in Flowise logs or system audit logs (auditd on Linux) targeting paths outside Flowise's intended working directory.
- New SSH keys: run `cat ~/.ssh/authorized_keys` on the server user account and look for unexpected public keys added during the vulnerable period.
- System library files: check /etc/ld.so.preload and /etc/ld.so.cache for unexpected entries that might load malicious code.
Log searches to start from
File write operations via WriteFileTool to non-working-directory paths (adapt field names to your logs)Splunk
source=flowise_logs WriteFileTool OR write_file | regex file_path!="^/opt/flowise|^/app/flowise|^\./" | stats count by file_path, src_user, timestampAudit log entries showing file writes to /etc, ~/.ssh, or other sensitive paths during Flowise process execution (adapt field names to your Elastic
process.name:*flowise* AND file.path:(/etc/* OR */.ssh/* OR /root/* OR */ld.so* OR */package.json) AND event.action:write | fields @timestamp, file.path, process.pid, user.nameWritten with AI as a starting point. Review them and change the index and field names to match your own logs before you rely on the result.
SecurityElites Fix Guide: step by step
- Find where Flowise is installedCheck npm packages on each server: run `npm list flowise flowise-components Flowise 2>/dev/null | grep -E '(flowise|Flowise)'` or `npm ls -g flowise flowise-components Flowise 2>/dev/null | grep -E '(flowise|Flowise)'` for global installs. Check Docker: run `docker ps --format 'table {{.Image}} {{.Names}}' | grep -i flowise` to find running containers.
- Check the current versionFor npm: run `npm list flowise flowise-components Flowise` in the directory where Flowise is installed, or `npm ls -g` for global installs. For Docker: run `docker inspect | grep -i image` to find the image, then check its tag or digest against the Flowise releases.
- Stop Flowise before upgradingIf running as a service: use your system's service manager, such as `systemctl stop flowise`. If running in Docker: run `docker stop `. If running in npm: stop the process that is running `npm start` or similar.
- Upgrade to version 3.0.8 or laterFor npm: run `npm install flowise@3.0.8 flowise-components@3.0.8 Flowise@3.0.8` in the installation directory. For Docker: pull `flowiseai/flowise:3.0.8` or later and restart the container with the new image.
- Start Flowise and confirm it runsIf running as a service: run `systemctl start flowise` and check `systemctl status flowise`. If running in Docker: run `docker run -d flowiseai/flowise:3.0.8` and verify the container starts with `docker ps`. If running in npm: run the start command and check that the application binds to its expected port.
- Verify the upgraded version is in useFor npm: run `npm list flowise flowise-components Flowise` and confirm all show version 3.0.8 or later. For Docker: run `docker inspect | grep Image` and confirm it shows the 3.0.8 image or later.
- Search logs for signs the vulnerability was exploitedLook for file write events to system directories, home directories, or configuration files that should not have been modified. Check access logs, audit logs, or Flowise application logs for unusual file paths passed to WriteFileTool. Record any findings and preserve logs for investigation.
- If exploitation is suspected, investigate and respondCheck for new files in /etc, ~/.ssh, /root, and other sensitive locations created during the vulnerable period. Examine system command logs and process history for suspicious activity. If unauthorized files are found, isolate the server, document changes, and restore from a known-good backup if necessary.
How to confirm it is fixed: Confirm the installed version is 3.0.8 or later by running `npm list flowise flowise-components Flowise` or checking the Docker image tag, and confirm Flowise starts and responds to requests on its expected port.
SecurityElites Quick Fixes: copy and paste
Upgrade flowise with npmupgrade
npm install flowise@3.0.8
npm ls flowiseUpgrade flowise-components with npmupgrade
npm install flowise-components@3.0.8
npm ls flowise-componentsUpgrade Flowise with npmupgrade
npm install Flowise@3.0.8
npm ls FlowiseCheck installed Flowise version (npm)for this issue
npm list flowise flowise-components Flowise 2>/dev/null | grep -E '@[0-9]|flowise|Flowise'Check Flowise version in Docker containerfor this issue
docker ps --filter "ancestor=flowiseai/flowise" --format "{{.Image}}\t{{.Names}}"Search logs for writes to sensitive paths (Linux/Unix)for this issue
grep -r 'WriteFileTool\|write_file' /var/log /home /root /etc 2>/dev/null | grep -E '(/etc|/root|.ssh|authorized_keys|ld.so.preload|package.json)' || echo 'No suspicious paths found in logs'Keep file access inside one directory (Python)general hardening
from pathlib import Path
BASE = Path("/srv/app/data").resolve()
def safe_path(name: str) -> Path:
p = (BASE / name).resolve()
if not p.is_relative_to(BASE):
raise ValueError("path outside allowed directory")
return pTest in a non-production environment first. General hardening examples use placeholder names and ports; change them to match your setup.
Let your AI coding assistant do the upgrade
Paste this into the coding assistant you already use, inside the project. It checks first and asks before it changes anything.
Instruction for your coding assistant
You are helping me fix a security vulnerability (CVE-2025-61913) in this project.\n\n1. Search the whole repository, including lock files, container files and CI configuration, for these packages and list every place they are pinned or installed:\n - flowise (npm): must be 3.0.8 or later
- flowise-components (npm): must be 3.0.8 or later
- Flowise (npm): must be 3.0.8 or later
2. Tell me which version we use now and whether it is affected. Stop and ask me before changing anything.
3. After I agree, raise each one to the safe version, update the lock files, and keep every other dependency as it is.
4. Run the tests and tell me what failed.
5. Give me a short summary of the files you changed that I can put in the pull request.SecurityElites Incident Drill: could your team handle this?
Four questions to ask in your next team meeting. If any has no clear answer, that is the gap to close.
Ticket for your backlog
Paste into Jira, GitHub Issues or any tracker that reads Markdown.
Ready-made ticket
## Flowise WriteFileTool can write files anywhere on the server (CVE-2025-61913)
**Severity:** Critical | **SE Fix-First Score:** 51/100 | **Fix window:** Within 7 days
**Record:** SE-AIV-01660 https://securityelites.com/ai-vulnerabilities/cve-2025-61913-flowise-writefiletool-can-write-files-anywhere-on-the-server/
### Why this matters
An authenticated person using Flowise can write files to any location on the server, including system directories and configuration files. An attacker could use this to run commands as the user who runs Flowise, take over the entire server, or steal data. This affects every Flowise deployment that allows users to build workflows with the WriteFileTool.
### What to do
1. Find where Flowise is installed
2. Check the current version
3. Stop Flowise before upgrading
4. Upgrade to version 3.0.8 or later
5. Start Flowise and confirm it runs
6. Verify the upgraded version is in use
7. Search logs for signs the vulnerability was exploited
8. If exploitation is suspected, investigate and respond
Full steps: https://securityelites.com/ai-vulnerabilities/cve-2025-61913-flowise-writefiletool-can-write-files-anywhere-on-the-server/
### Done when
- [ ] flowise is at 3.0.8 or later everywhere it is installed
- [ ] flowise-components is at 3.0.8 or later everywhere it is installed
- [ ] Flowise is at 3.0.8 or later everywhere it is installed
- [ ] Lock files, container images and CI configuration are updated
- [ ] Confirm the installed version is 3.0.8 or later by running `npm list flowise flowise-components Flowise` or checking the Docker image tag, and confirm Flowise starts and responds to requests on its expected port.
- [ ] Logs were checked for signs of earlier use
SecurityElites Fix Tracker
Record who owns this fix, the date it is due and when it is done, and see everything still open in one list. Free with a SecurityElites account.
Related vulnerabilities
In the same software
- Flowise CSV and Airtable agents allow data theft via prompt injection Critical · CVE-2026-73487
- Flowise can run commands and read files outside its sandbox Critical · CVE-2026-119978
- Flowise OAuth2 token endpoint open to anyone, leaks access tokens Critical · CVE-2026-70478
- Flowise CSV Agent can run Python code sent by attackers Critical · CVE-2026-70477
- Flowise allows authenticated users to change other organizations' billing High · CVE-2026-70476
- Flowise allows any authenticated user to change execution records without permission check High · CVE-2026-70475
The same kind of mistake in other AI tools
- Nik Voice Ticketing AI allows upload and run of harmful files without login Critical · CVE-2026-143966
- NLTK can overwrite files outside its data folder via hardlinks during package extraction High · CVE-2026-128135
- MLflow can read files outside its data folder via model version prompts High · CVE-2026-116690
- LiteLLM proxy can be made to read files by authenticated users High · GHSA-g5ff-637f-6q2m
- MLflow can write files outside trace directory via crafted trace ID High · CVE-2026-53995
Change history
- 9 Oct 2025: Made public
- 2 Dec 2026: Published
Official record
### SummaryThe WriteFileTool in Flowise does not restrict the file path for reading, allowing authenticated attackers to exploit this vulnerability to write arbitrary files to any path in the file system, potentially leading to remote command execution.### DetailsFlowise supports providing WriteFileTool for large models, which is used to write files to the server's file system. The implementation of this tool is located at packages/components/nodes/tools/WriteFile/WriteFile.ts.``` /** * Class for writing data to files on the disk. Extends the StructuredTool * class. */ export class WriteFileTool extends StructuredTool { static lc_name() { return 'WriteFileTool' }schema = z.object({ file_path: z.string().describe('name of file'), text: z.string().describe('text to write to file') }) as anyname = 'write_file'description = 'Write file from disk'store: BaseFileStoreconstructor({ store, ...rest }: WriteFileParams) { super(rest)this.store = store }async _call({ file_path, text }: z.infer<typeof this.schema>) { await this.store.writeFile(file_path, text) return 'File written to successfully.' } }```This tool directly uses the file_path parameter passed to it without verifying whether the path belongs to Flowise's working directory. Authenticated attackers can exploit this vulnerability to write files with arbitrary content to any path on the server.There are numerous ways to achieve remote command execution through arbitrary file write vulnerabilities, which will not be elaborated here. For example, attackers could write their own public key to ~/.ssh/authorized_keys to gain remote SSH access, or overwrite /etc/ld.so.preload to hijack dynamic libraries and execute arbitrary code. Flowise's historical vulnerability information (https://github.com/FlowiseAI/Flowise/security/advisories/GHSA-8vvx-qvq9-5948) also describes steps to achieve remote command execution by overwriting the start command in package.json.### PoCThis file writing vulnerability has been verified to exist in the latest Flowise Docker image (https://hub.docker.com/layers/flowiseai/flowise/latest/images/sha256-26300377397818a451e0710389eb77615256b0f3ecc895194850ab35dda3ae7b). The reproduction steps are as follows:1. Pull the Flowise Docker image``` docker pull flowiseai/flowise ```2. Start the Flowise service``` docker run -d --name flowise -p 3000:3000 flowise ```3. Access the Flowise service at server ip:3000 in your browser and register an account 4. Save the following content as agent.json``` { "nodes": [ { "id": "startAgentflow_0", "type": "agentFlow", "position": { "x": -203, "y": 37 }, "data": { "id": "startAgentflow_0", "label": "Start", "version": 1.1, "name": "startAgentflow", "type": "Start", "color": "#7EE787", "hideInput": true, "baseClasses": [ "Start" ], "category": "Agent Flows", "description": "Starting point of the agentflow", "inputParams": [ { "label": "Input Type", "name": "startInputType", "type": "options", "options": [ { "label": "Chat Input", "name": "chatInput", "description": "Start the conversation with chat input" }, { "label": "Form Input", "name": "formInput", "description": "Start the workflow with form inputs" } ], "default": "chatInput", "id": "startAgentflow_0-input-startInputType-options", "display": true }, { "label": "Form Title", "name": "formTitle", "type": "string", "placeholder": "Please Fill Out The Form",
Weakness type: CWE-22
Use this record in your own tools
Get this record as JSON
curl https://securityelites.com/wp-json/se-aivd/v1/vulns/CVE-2025-61913For scanners and pipelines: OSV format · CycloneDX format · API guide · Email alerts · Fix tracker
The plain-language sections were written with AI from the official record, and the upgrade versions come directly from the official data. Last updated 2 Dec 2026. Read the vendor advisory before changing a production system.