Skip to content

fix(connections): ask again when a trusted link carries a filter - #3314

Merged
datlechin merged 5 commits into
mainfrom
fix/trusted-link-filter-prompt
Oct 10, 2026
Merged

datlechin merged 5 commits into
mainfrom
fix/trusted-link-filter-prompt

Conversation

@datlechin

Copy link
Copy Markdown
Member

Why

A database link (mysql://, postgresql://, ...) can carry a filter (condition, raw, query, or column, operation, value) that runs on the table it opens. Once a local database was set to Always Allow, such a link connected without asking. The filter alert that followed showed only the first 300 characters of the SQL, so the rest ran unseen. Always Allow also covered a link through an SSH tunnel to 127.0.0.1, whatever SSH server it named.

Change

  • A link with a filter always shows the connection alert, trusted or not, without Always Allow. The alert shows the whole filter in a selectable box, with invisible characters revealed and a scroller when it overflows. The separate Apply Filter from Link alert is gone.
  • The filter travels with the table it opens, in a new tab, so it is in place before the first load and never lands on another tab.
  • A filter longer than 51,200 characters is refused.
  • A link through an SSH tunnel is never trusted. Other links keep Always Allow, and saved trust entries are unchanged.

Verified

The new ExternalConnectionGateTests cases for a trusted target with a filter fail with main's trust rule and pass here. ExternalLinkFilterUITests opens a filtered postgresql:// link and checks the alert shows the filter and offers no Always Allow.

Screenshots

After

Not in this PR

  • docs/external-api/terminal.mdx still says Always Allow stops asking. Another PR is moving that page; it needs the filter and tunnel exceptions.
  • ClickHouse browse queries quote a table name without escaping a backslash (quoteIdentifierFromDialect), so a table= value can end the quoting early, and a link without a filter still opens a trusted target without asking.
  • Snowflake filter values escape only quotes (FilterSQLGenerator.escapeStringValue keys on likeEscapeStyle), so a backslash can end the literal.
  • ExternalConnectionTrustStore writes UserDefaults.standard, outside the UI test sandbox, so the trusted path has unit tests only.

@mintlify

mintlify Bot commented Oct 10, 2026 •

Copy link
Copy Markdown

Preview deployment for your docs. Learn more about Mintlify Previews.

Project Status Preview Updated
TablePro 🟢 Ready View Preview Oct 10, 2026, 7:14 AM

💡 Tip: Enable Automations to automatically generate PRs for you.

Signed-off-by: Dat Ngo Quoc <datlechin@gmail.com>
@datlechin
datlechin merged commit 593befd into main Oct 10, 2026
7 checks passed
@datlechin
datlechin deleted the fix/trusted-link-filter-prompt branch October 10, 2026 07:29

This branch was successfully deployed

1 active deployment
staging - docs — 5f41f5e1 Deployed Oct 10, 2026 by mintlify[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant