mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-07 11:28:35 -05:00
[PR #19201] [CLOSED] feat/security: Add SSRF protection with configurable blocklist #25128
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/19201
Author: @Classic298
Created: 11/15/2025
Status: ❌ Closed
Base:
dev← Head:sec-enhance-web-fetch📝 Commits (6)
6269482fix: Add SSRF protection for web fetch endpoints (#37)475b0f8Update config.pyd915a3bUpdate utils.py2d61d11feat: implement unified web fetch filter list with allow/block support (#53)bf3026bMerge branch 'dev' into sec-enhance-web-fetch7943ed6refactor: unify URL filtering logic with DNS resolution security (#57)📊 Changes
3 files changed (+79 additions, -5 deletions)
View changed files
📝
backend/open_webui/config.py(+17 -0)📝
backend/open_webui/retrieval/web/main.py(+39 -4)📝
backend/open_webui/retrieval/web/utils.py(+23 -1)📄 Description
devbranch. Not targeting thedevbranch will lead to immediate closure of the PR.Changelog Entry
Description
Adds a hardcoded list of common cloud metadata endpoints that will be blocked when attempting to fetch them using the web fetch feature.
Adds a configurable env var to allow admins to define additional blocklisted hostnames and IPs
Screenshots or Videos
Contributor License Agreement
By submitting this pull request, I confirm that I have read and fully agree to the Contributor License Agreement (CLA), and I am providing my contributions under its terms.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.