n8n: Shared-Workflow Credential Check Misses Agent Node Parameter Credentials
What fixes it
No source in this snapshot names a fixed version.
Description
Impact
When a workflow is shared for editing, n8n checks on save that the editor is not introducing credentials they are not allowed to use. That check inspected a node's credentials field, but the agent node keeps its model and per-tool credential ids elsewhere in its parameters, where the check never looked. An editor of a shared workflow can therefore have the owner's credentials resolved for tools they control, sending decrypted secrets to a destination they choose.
Patches
The issue has been fixed in n8n versions 2.42.1 and 2.41.4. Users should upgrade to one of these versions or later to remediate the vulnerability.
Workarounds
If upgrading is not immediately possible, administrators should consider the following temporary mitigations:
- Restrict n8n instance access to fully trusted users only.
- Audit shared workflows that contain a
Message an Agentnode configured in inline mode and review which users hold editor access. - Remove editor access from any users who are not fully trusted until the instance is patched.
These workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.
Text from GitHub Advisory Database
Affected versions 2
- n8n, npm< 2.42.1GitHub
- n8n, npm< 2.41.4GitHub