-
Notifications
You must be signed in to change notification settings - Fork 9.8k
fix(security): harden multi-tenant surfaces #13530
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 49 commits
Commits
Show all changes
70 commits
Select commit
Hold shift + click to select a range
294effc
fix(security): harden multi-tenant code-exec and env-var leak surfaces
jordanrfrazier 2137de4
fix(security): close 4 multi-tenant secret-leak, SSRF, and file-read …
jordanrfrazier b0a6350
fix(security): close 5 multi-tenant RCE, code-exec, and SSRF holes
jordanrfrazier 9f15a60
fix(security): harden review-found gaps in the multi-tenant security …
jordanrfrazier bc38345
fix(security): address review findings on security-hardening PR
jordanrfrazier f226c36
fix(security): clarify connector SSRF errors and document hardening t…
jordanrfrazier ee274f1
fix(security): deny server secrets/DB within the local-file-access bo…
jordanrfrazier c206127
fix(security): bind agentic MCP tools to the authenticated user; clos…
jordanrfrazier 8b473e4
fix(security): serve download_image with nosniff + attachment
jordanrfrazier cf4dab7
docs(security): warn against shared SaaS tracing in multi-tenant depl…
jordanrfrazier 2f44a77
fix(security): gate agentic assistant codegen behind agentic_experien…
jordanrfrazier a91b967
fix(security): escape LIKE wildcards and allowlist message order_by
jordanrfrazier d9e2ed7
fix(security): pin watsonx orchestrate run target to the deployment r…
jordanrfrazier 2fa4731
refactor(security): cleanup pass on the multi-tenant hardening PR
jordanrfrazier a459b48
[autofix.ci] apply automated fixes
autofix-ci[bot] 8f259a9
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] a7bc0c5
[autofix.ci] apply automated fixes (attempt 3/3)
autofix-ci[bot] 79fca45
fix(security): harden MCP docker args, vector-store paths, env-var leaks
jordanrfrazier babdbc1
refactor(security): dedupe the local-file-access restriction reader
jordanrfrazier 3355be9
docs(security): tighten over-explained comments in the MCP/env-var gu…
jordanrfrazier 513423c
fix(security): address hardening review feedback
erichare 770deea
[autofix.ci] apply automated fixes
autofix-ci[bot] 961ffe8
[autofix.ci] apply automated fixes (attempt 2/3)
autofix-ci[bot] 0aafdbe
chore: update generated hash secrets baseline
erichare ad73cc7
test(lfx): expect resolved confined symlink path
erichare 36c6d11
fix(security): enforce KB-root containment for username-derived paths…
erichare 1f39a4b
fix(security): stop trusting X-Forwarded-For for the MCP install loca…
erichare 331b637
fix(security): scrub stored secrets from public flow read (#13914)
erichare 2121a7f
fix(security): allow loopback for connector/model-provider URLs by de…
erichare 304a132
Merge branch 'release-1.11.0' into security-hardening
erichare c9b9b60
test(lfx): add connector_ssrf_allow_loopback to expected settings fields
erichare 34318c0
Merge branch 'release-1.11.0' into security-hardening
erichare 068c983
fix(security): run server-trusted component code on the restricted bu…
erichare a868152
test(mcp): use allowlisted commands + disable SSRF in mocked MCP unit…
erichare 461e6f0
fix(security): stabilize backend tests broken by multi-tenant SSRF ha…
erichare 15a7777
[autofix.ci] apply automated fixes
autofix-ci[bot] 402e7bf
Merge branch 'release-1.11.0' into security-hardening
erichare 186e2a0
Merge branch 'release-1.11.0' into security-hardening
erichare db276d6
chore: auto-bake note keys and regenerate backend locales/en.json [sk…
github-actions[bot] 1a4505b
Merge branch 'release-1.11.0' into security-hardening
erichare fc38da2
Merge branch 'release-1.11.0' into security-hardening
erichare d9a5abc
test: mock OpenAI base URL SSRF validation
erichare 9a7c325
Merge remote-tracking branch 'origin/release-1.11.0' into security-ha…
erichare d60f7d1
Merge branch 'release-1.11.0' into security-hardening
erichare 642907b
Merge branch 'release-1.11.0' into security-hardening
erichare 192d180
chore: update default secuirty toggles
Adam-Aghili 93e1803
Chore: add bob to .gitignore
Adam-Aghili b321621
fix(security): scope chat-history retrieval to the owning user (#13922)
erichare 742bf4e
Merge remote-tracking branch 'origin/release-1.11.0' into security-ha…
erichare 62ac37d
Merge remote-tracking branch 'origin/release-1.11.0' into security-ha…
erichare b1b4fc8
[autofix.ci] apply automated fixes
autofix-ci[bot] c308f43
fix: merge release
erichare eabcc87
fix(migrations): merge chat-history-scope and span-enum alembic heads
erichare 4d485c9
test(wxo): align run-payload test with owner-pinned agent_id hardening
erichare 66cfe81
Merge branch 'release-1.11.0' into security-hardening
erichare df26211
Merge branch 'release-1.11.0' into security-hardening
Adam-Aghili 2e7bfba
fix: scrub nested nodes
Adam-Aghili c921024
chore: harden mcp command scrubing
Adam-Aghili 38acb03
Merge branch 'release-1.11.0' into security-hardening
erichare 06e7c85
Merge branch 'release-1.11.0' into security-hardening
erichare 5e552d6
fix(ci): repair security hardening checks
erichare 66c3280
fix(ci): align mcp security test expectations
erichare 628acbd
Merge branch 'release-1.11.0' into security-hardening
erichare a8b23ed
Merge branch 'release-1.11.0' into security-hardening
erichare 50c217d
fix: merge alembic heads 9d5e24d777bf and b7f91a2c4d6e
erichare ef86c48
fix(migrations): backfill legacy message ownership
erichare 690c780
Merge branch 'release-1.11.0' into security-hardening
erichare 139a3a1
[autofix.ci] apply automated fixes
autofix-ci[bot] 208dba6
Merge branch 'release-1.11.0' into security-hardening
erichare b72f5c2
Merge remote-tracking branch 'origin/release-1.11.0' into security-ha…
jordanrfrazier File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -301,3 +301,6 @@ tmp_toolguard/ | |
| #whitesource | ||
| whitesource/ | ||
| /.codex | ||
|
|
||
| #ai folders | ||
| .bob/ | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,23 @@ | ||
| """Shared dependencies for the agentic API. | ||
|
|
||
| Kept in a leaf module (only fastapi + lfx settings) so both the route definitions | ||
| (langflow.agentic.api.router) and the router-include site (langflow.api.router) can import it | ||
| without a circular import. | ||
| """ | ||
|
|
||
| from fastapi import HTTPException, status | ||
| from lfx.services.deps import get_settings_service | ||
|
|
||
|
|
||
| def require_agentic_experience() -> None: | ||
| """Backend gate for the agentic assistant's code-generating/executing endpoints. | ||
|
|
||
| SECURITY: the assistant generates and EXECUTES component code in-process | ||
| (langflow.agentic.helpers.validation.validate_component_runtime and the user-components | ||
| overlay). ``agentic_experience`` was only a frontend/UX + MCP-provisioning flag, so the codegen | ||
| endpoints were live by default. Gate them here (404 when off), matching the per-endpoint | ||
| precedent in api/v1/endpoints.py. The read-only ``/agentic/check-config`` probe is intentionally | ||
| NOT gated so non-agentic deployments can still query provider configuration. | ||
| """ | ||
| if not get_settings_service().settings.agentic_experience: | ||
| raise HTTPException(status_code=status.HTTP_404_NOT_FOUND, detail="This endpoint is not available") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
src/backend/base/langflow/agentic/flows/LangflowAssistant.json
Large diffs are not rendered by default.
Oops, something went wrong.
4 changes: 2 additions & 2 deletions
4
src/backend/base/langflow/agentic/flows/SystemMessageGen.json
Large diffs are not rendered by default.
Oops, something went wrong.
4 changes: 2 additions & 2 deletions
4
src/backend/base/langflow/agentic/flows/TemplateAssistant.json
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mendonk