Commit Graph

18697 Commits

Author SHA1 Message Date
Svetoslav Dekov
0dd2cd4879
fix(nodes): use getNodeParameter with fallback for neverError option
Read neverError via getNodeParameter dot-path with explicit fallback
(true), matching the pattern used by HTTP Request node. Ensures the
option works for existing nodes where the collection entry is absent.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 09:16:03 +03:00
Svetoslav Dekov
4725f1a8c9
feat(nodes): add Never Error option to Data Table SQL Query tool
When enabled (default: true), SQL validation and execution errors are
returned as data instead of crashing the workflow. This lets the AI agent
see the error message and retry with corrected SQL.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 08:55:47 +03:00
Svetoslav Dekov
5c54f5a56d
fix(core): skip column-position identifiers during SQL table name rewriting
When a column name matched a table name (e.g. "employee"."department" where
"department" is also a table), the rewriter incorrectly replaced the column
with the physical table name, causing SQLITE_ERROR: no such column.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-08 08:11:55 +03:00
Svetoslav Dekov
08c8d93cd9
fix(core): remove ineffective PRAGMA query_only from SQLite read path
The PRAGMA was being set on the write pool connection while the SELECT
ran on the read pool — a different connection. Read-only is already
enforced at the connection level via SQLITE_OPEN_READONLY.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 10:21:54 +03:00
Svetoslav Dekov
bda769494e
fix(core): require double-quoted identifiers in SQL validator to prevent keyword confusion attacks
The closed-world validator allowed SQL keywords (INTO, FOR, UPDATE) to
pass as column names when a table had columns with those names. This
enabled write-oriented clauses like SELECT INTO and FOR UPDATE to bypass
validation.

All user-provided names (tables, columns, aliases) must now be
double-quoted. Unquoted identifiers can only be allowed function names
or CAST types, both validated against allowlists. This structurally
eliminates the entire class of keyword confusion attacks.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 09:33:43 +03:00
Svetoslav Dekov
fd2b9cfa26
fix(core): allow SELECT column aliases in ORDER BY and HAVING clauses
The SQL validator's closed-world identifier check rejected column aliases
(e.g. `SUM(amount) AS total_revenue ... ORDER BY total_revenue`) because
aliases were recognized at definition but never recorded for later reference.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 22:34:02 +03:00
Svetoslav Dekov
948632c1d9
Add more tests for the sql validation 2026-04-01 22:02:57 +03:00
Svetoslav Dekov
211502204e
fix(core): reject FROM-less queries and fix AS alias table extraction in SQL validator
FROM-less queries (e.g. SELECT NOW()) bypassed table authorization entirely.
AS aliases in FROM broke comma-separated table extraction, leaving subsequent
table names unrewritten — which could resolve to internal DB tables.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 21:52:41 +03:00
Svetoslav Dekov
e2a3283190
chore: revert pnpm-workspace.yaml to master
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 21:43:11 +03:00
Svetoslav Dekov
0e4e7a6670
refactor(core): rewrite SQL validator with token-based closed-world approach
Replace AST-based node-sql-parser validation with a custom tokenizer that
scans every character and validates every identifier against known tables,
columns, and functions. No aliases, no external parser dependency.

Security model:
- Every character must produce a recognized token
- First token must be SELECT, only one SELECT allowed
- Every identifier must be a known table, column, function, or cast type
- Table-qualified columns validated against schema
- CAST types validated only inside CAST() context

Also removes node-sql-parser dependency entirely and updates tool
description with explicit SQL format rules for the LLM.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 21:42:03 +03:00
Svetoslav Dekov
59628dfe40
refactor(core): rewrite SQL validator with strict allowlist approach
Replace blocklist-based validation with a strict allowlist that verifies
every AST node against an explicit set of permitted types and operators.
Anything not explicitly recognized is rejected.

Restricted SQL subset for v1:
- No CTEs (WITH), no UNION, no subqueries, no derived tables
- No window functions (OVER clause)
- Only simple SELECT with JOINs, WHERE, GROUP BY, ORDER BY, LIMIT
- Every expression type, operator, and function must be in the allowlist

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 17:24:41 +03:00
Svetoslav Dekov
0db47171d3
fix(nodes-langchain): add execute method to SQL tool node for standalone usage
Tool nodes need both execute and supplyData methods — execute for standalone
usage (SQL passed via input items), supplyData for agent tool usage. Also adds
Main input so the node can receive data when not connected as a tool.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 16:43:54 +03:00
Svetoslav Dekov
514f6498ca
chore: fix lint errors and update proxy test for SQL tool
- Fix eslint errors in sql-validator.ts (consistent-type-imports, no-unsafe-argument, unnecessary assertion)
- Fix existing proxy integration test to pass new DataTableSqlService constructor arg
- Fix node-param lint rules in tool node (displayName and description for dynamic multi-options)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 15:57:31 +03:00
Svetoslav Dekov
ab470393c6
feat(nodes-langchain): add Data Table SQL Query tool node for agent SQL access
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 15:33:10 +03:00
Svetoslav Dekov
46c15c83ff
feat(core): wire SQL query proxy, types, and helpers for data table SQL tool
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 15:27:40 +03:00
Svetoslav Dekov
93830d8289
feat(core): add DataTableSqlService for validated read-only SQL execution
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-01 15:25:41 +03:00
Svetoslav Dekov
b97cb8d363
feat(core): add SQL validator with AST-based security pipeline for data table SQL tool
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 15:14:09 +03:00
Svetoslav Dekov
008ec56f9b
feat(core): add SQL function allowlist for data table SQL tool
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-01 15:04:49 +03:00
Svetoslav Dekov
57050b8c16
chore: add node-sql-parser dependency for data table SQL tool
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-01 14:59:53 +03:00
Svetoslav Dekov
283849139f
chore: add gstack skill routing rules to CLAUDE.md 2026-04-01 10:48:01 +03:00
Iván Ovejero
5ee0e842b8
feat(core): Add isolate pooling for VM expression engine (#27573)
Some checks are pending
CI: Master (Build, Test, Lint) / Build for Github Cache (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (22.x) (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (24.13.1) (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (25.x) (push) Waiting to run
CI: Master (Build, Test, Lint) / Lint (push) Waiting to run
CI: Master (Build, Test, Lint) / Performance (push) Waiting to run
CI: Master (Build, Test, Lint) / Notify Slack on failure (push) Blocked by required conditions
2026-03-31 14:54:11 +00:00
Sandra Zollner
ccd04b0edf
feat(core): Improve public API middleware to handle different error types (#27562)
Some checks are pending
Build: Benchmark Image / build (push) Waiting to run
CI: Master (Build, Test, Lint) / Build for Github Cache (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (22.x) (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (24.13.1) (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (25.x) (push) Waiting to run
CI: Master (Build, Test, Lint) / Lint (push) Waiting to run
CI: Master (Build, Test, Lint) / Performance (push) Waiting to run
CI: Master (Build, Test, Lint) / Notify Slack on failure (push) Blocked by required conditions
Util: Sync API Docs / sync-public-api (push) Waiting to run
2026-03-31 14:06:23 +00:00
Stephen Wright
4471ee87e7
feat(core): Add Zod validation schemas for token-exchange external input (#27825)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-31 12:22:32 +00:00
Andreas Fitzek
e0eb8413b5
feat(core): Add Redis storage backend for instance registry (no-changelog) (#27527) 2026-03-31 12:04:23 +00:00
Declan Carroll
3922984b74
ci: Add rules engine and code health packages (no-changelog) (#27815)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 11:20:11 +00:00
Declan Carroll
3dde7e16f8
test: Fix flaky unit tests (#27750)
Co-authored-by: Claude Haiku 4.5 <noreply@anthropic.com>
2026-03-31 08:49:38 +00:00
Charlie Kolb
ada24f13fe
feat(core): Add instance version history table (#27740) 2026-03-31 08:44:54 +00:00
Eugene
6294b0e56f
feat(ai-builder): Add agent text response evaluation and workflow changes binary check (no-changelog) (#27755)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-31 07:49:10 +00:00
Declan Carroll
e947000d97
ci: Improve coverage reports (#27756) 2026-03-31 05:42:44 +00:00
n8n-assistant[bot]
d300568ee1
🚀 Release 2.15.0 (#27787)
Co-authored-by: Matsuuu <16068444+Matsuuu@users.noreply.github.com>
2026-03-30 20:55:37 +03:00
Matsu
f2ac7b5cce
ci: Pin provenance to version, not SHA (#27785) 2026-03-30 20:53:11 +03:00
Danny Martini
769e28cb36
fix(core): Remaining VM test fixes — error propagation, proxy traps, and cross-realm assertions (#27541)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-30 16:13:12 +00:00
Matsu
189c1047bc
ci: Prevent buffer overflow in other helper scripts (#27774) 2026-03-30 15:24:42 +00:00
Matsu
fdf9857344
ci: Parse pnpm ls with jq to prevent buffer overload (#27770) 2026-03-30 14:40:36 +00:00
Irénée
d9f8f04772
fix(core): Rename data table columns during source control pull (#27746)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-30 13:10:04 +00:00
Milorad FIlipović
4436e4b71c
fix(core): Fix /healthz endpoint when using N8N_PATH (#27665) 2026-03-30 13:05:07 +00:00
Svetoslav Dekov
de02036f47
fix(core): Treat sub-node connections as non-blocking for partial execution root detection (#27759)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-30 12:50:36 +00:00
Milorad FIlipović
cf56b9a530
fix(editor): Update mcp eligibility requirements in workflow settings (no-changelog) (#27502) 2026-03-30 12:33:07 +00:00
Svetoslav Dekov
dbe8cd10fc
fix(editor): Use execution data instead of stale NDV state for chat trigger check (#27752)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-30 12:29:28 +00:00
Eugene
f54453a419
refactor: Remove persistBuilderSessions feature flag (#27481)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-30 12:16:07 +00:00
Matsu
1963d9775d
ci: Disable chromatic, if not in main repo (#27747) 2026-03-30 11:08:16 +00:00
Svetoslav Dekov
21faa2e187
fix(editor): Handle chat trigger waiting state in setup cards (#27682)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-30 10:56:47 +00:00
Stephen Wright
af2af60a0f
feat(core): Add POST /role-mapping-rule/:id/move endpoint for reordering rules (#27677)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-30 10:46:05 +00:00
Charlie Kolb
91d56d2f61
fix(editor): Show tooltip on dependency pill (#27545) 2026-03-30 10:36:23 +00:00
Paul Issert
6d6a10c55e
fix(editor): Restore templates sidebar click tracking (#27623)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-30 10:23:00 +00:00
Charlie Kolb
706fc4360e
fix(editor): Avoid resource locator cache pollution (#27493) 2026-03-30 10:16:38 +00:00
Svetoslav Dekov
98d685111c
feat(editor): Group agent subnodes into multi-node setup cards (#27570)
Co-authored-by: Charlie Kolb <charlie@n8n.io>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-30 10:08:34 +00:00
Declan Carroll
a259295e62
feat(core): Add configurable minimum password length via N8N_PASSWORD_MIN_LENGTH (#26953)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-30 09:40:26 +00:00
Guillaume Jacquart
8ab168f787
chore(core): Query executions using a single query intead of two (#27081)
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
2026-03-30 08:19:32 +00:00
Eugene
6314cd4842
feat(ai-builder): Support dataset context and conversation history in evaluations (no-changelog) (#27618)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
2026-03-30 08:14:01 +00:00