feat: openwebui_oauth_picture_links (Pocket ID pictures); release 0.1.0-dev.6 #7
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/oauth-picture-links"
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?
Draft. Fix for Pocket ID profile pictures never reaching Open WebUI. Needs your review before merge (it bumps VERSION, so merging signs and publishes 0.1.0-dev.6).
Why pictures don't sync
Open WebUI is configured correctly (
OAUTH_UPDATE_PICTURE_ON_LOGIN=true, claimpicture), and Pocket ID sendspicture = https://auth.yawn.dev/api/users/<sub>/profile-picture.png. The link works: both Pocket ID users get HTTP 200, PNG.At sign-in Open WebUI downloads that URL to store a copy, but first runs it through its web-fetch guard (
validate_url). WithENABLE_LOCAL_WEB_FETCHoff it refuses any host that resolves to a non-global address. On the LAN, Technitium answers every*.yawn.devname with Caddy's192.168.1.172, so the fetch is refused,_process_picture_urlreturns/user.png, and Open WebUI stores the default picture at every sign-in. Live state matches: both OIDC users have/user.png; the five local users have their own uploaded pictures.Fix
New
openwebui_oauth_picture_links:profile_image_urlto the Pocket ID link (url_templatewith{sub}), andOAUTH_UPDATE_PICTURE_ON_LOGIN, which would otherwise reset it at the next sign-in.Open WebUI serves a link picture by redirect (
ENABLE_PROFILE_IMAGE_URL_FORWARDING, default on), so the browser loads it from Pocket ID and changes in Pocket ID show up at once; Open WebUI fetches nothing. Only OAuth users' picture and that one setting are written; name/email/role are checked unchanged; local users are untouched; a primary-admin 403 is reported.Read-only plan against live Open WebUI:
1 to import, 1 to change,users_out_of_sync 3 -> 0(2 users + copy-on-login).Alternatives not taken
ENABLE_LOCAL_WEB_FETCH=trueon CT105: one line, but opens every Open WebUI URL fetch (RAG, images, tools) to the LAN, and/root/.envisn't managed in Git.auth.yawn.devwith the WAN address for CT105 only: not supported by the pinned provider (no APP records), and it adds a hairpin dependency to sign-in.Consumer: john/ai draft PR (adds the resource to
openwebui.tf).Open WebUI copies the OIDC picture claim at sign-in only after validating the URL with its web-fetch guard. When the identity provider resolves to a private address from Open WebUI (LAN split-horizon DNS), the copy is refused and /user.png is stored at every sign-in, overwriting any picture. The resource stores each OAuth user's picture as a link (url_template with {sub}) and turns off OAUTH_UPDATE_PICTURE_ON_LOGIN; the browser loads the picture by redirect, so it stays current with nothing fetched server-side. Writes only OAuth users' profile_image_url and that one setting, verifies nothing else moved, reports a primary-admin 403.WIP: feat: openwebui_oauth_picture_links (Pocket ID pictures); release 0.1.0-dev.6to feat: openwebui_oauth_picture_links (Pocket ID pictures); release 0.1.0-dev.6