mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-05 18:38:17 -05:00
[GH-ISSUE #20852] feat: Support Password Masking in UserValves #34842
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?
Originally created by @EliasBA on GitHub (Jan 21, 2026).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/20852
Check Existing Issues
Verify Feature Scope
Problem Description
When creating Tools or Functions with
UserValvesthat contain sensitive fields like passwords, the password is displayed as plain text in the OpenWebUI settings UI.This is a security concern because:
Current Behavior:
The standard JSON Schema
format: "password"attribute is not recognized by theValves.sveltecomponent.Desired Solution you'd like
Support the standard JSON Schema
format: "password"attribute inValves.svelteto render sensitive fields as password inputs (masked with dots).OpenWebUI already has a
SensitiveInput.sveltecomponent. I propose modifyingsrc/lib/components/common/Valves.svelteto use this existing component when the format is detected.Implementation Logic:
Inside the valves rendering loop:
valvesSpec.properties[property]?.format === 'password'<SensitiveInput ... />instead of the default<input type="text">or<textarea>.Alternatives Considered
api_keyto hope for auto-detection, but this is semantically incorrect for actual user passwords (e.g., database or service passwords).Additional Context
Implementation Suggestion:
In
src/lib/components/common/Valves.svelte, add this condition to the main rendering loop:Benefits:
format: "password".For Tool Developers:
They can simply add
json_schema_extra={"format": "password"}to their Pydantic models.@tjbck commented on GitHub (Jan 21, 2026):
Addressed with
8c70453b2ein dev!