🐛 Bug Report: Unable to remove or change OIDC Client Logo #105

Closed
opened 2025-07-08 08:39:57 -04:00 by AtHeartEngineer · 0 comments

Originally created by @mitchplze on 6/4/2025

Reproduction steps

Go to an OIDC Client application
Try to Change or Remove the Logo

Expected behavior

The logo should be removed or changed

Actual Behavior

On certain OIDC apps from time to time, the logo removal or change does not 'commit' when you save the page and the logo is effectively stuck/locked.

Even after browser refresh, the old logo is shown on the details and list page.

This doesn't happen all the time, and is often hard to reproduce. Sometimes if you remove the logo, wait a bit, and try to upload a new one it will work.

Image

Version and Environment

Docker. Pocket v.1.2.0

Log Output

When I remove the problematic logo (SVG if it matters), the following panic is logged:

pocket-id  | [GIN] 2025/06/04 - 18:05:07 | 200 |   13.261287ms |  172.71.150.151 | GET      "/api/user-groups?sort[column]=friendlyName&sort[direction]=asc"
pocket-id  | [GIN] 2025/06/04 - 18:05:07 | 200 |   13.325207ms |  172.71.150.151 | GET      "/api/user-groups?sort[column]=friendlyName&sort[direction]=asc"
pocket-id  | [GIN] 2025/06/04 - 18:05:11 | 500 |    1.141567ms |  172.71.150.151 | DELETE   "/api/oidc/clients/5648bf99-fc7a-4653-a306-3c6791412ee5/logo"
pocket-id  | 
pocket-id  | 
pocket-id  | 2025/06/04 18:05:11 [Recovery] 2025/06/04 - 18:05:11 panic recovered:
pocket-id  | runtime error: invalid memory address or nil pointer dereference
pocket-id  | runtime/panic.go:262 (0x8764f)
pocket-id  | runtime/signal_unix.go:925 (0x8761c)
pocket-id  | github.com/pocket-id/pocket-id/backend/internal/service/oidc_service.go:756 (0x6daa20)
pocket-id  | github.com/pocket-id/pocket-id/backend/internal/controller/oidc_controller.go:577 (0xd4aa5b)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd3f17f)
pocket-id  | github.com/pocket-id/pocket-id/backend/internal/middleware/rate_limit.go:44 (0xd3f130)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2097b)
pocket-id  | github.com/pocket-id/pocket-id/backend/internal/middleware/error_handler.go:24 (0xd5f3ef)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2097b)
pocket-id  | github.com/pocket-id/pocket-id/backend/internal/middleware/cors.go:24 (0xd5f3a3)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2c813)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/logger.go:249 (0xd2c7f4)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2d467)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/recovery.go:102 (0xd2d44c)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2c813)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/logger.go:249 (0xd2c7f4)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2bcb3)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/gin.go:633 (0xd2b83c)
pocket-id  | github.com/gin-gonic/gin@v1.10.0/gin.go:589 (0xd2b47f)
pocket-id  | net/http/server.go:3301 (0x31115b)
pocket-id  | net/http/server.go:2102 (0x2f104b)
pocket-id  | runtime/asm_arm64.s:1223 (0x8cc63)
pocket-id  | 
pocket-id  | [GIN] 2025/06/04 - 18:05:11 | 200 |    2.164934ms |  172.71.150.151 | PUT      "/api/oidc/clients/5648bf99-fc7a-4653-a306-3c6791412ee5"
pocket-id  | [GIN] 2025/06/04 - 18:05:11 | 200 |    2.199055ms |  172.71.150.151 | PUT      "/api/oidc/clients/5648bf99-fc7a-4653-a306-3c6791412ee5"
*Originally created by @mitchplze on 6/4/2025* ### Reproduction steps Go to an OIDC Client application Try to Change or Remove the Logo ### Expected behavior The logo should be removed or changed ### Actual Behavior On certain OIDC apps from time to time, the logo removal or change does not 'commit' when you save the page and the logo is effectively stuck/locked. Even after browser refresh, the old logo is shown on the details and list page. This doesn't happen all the time, and is often hard to reproduce. Sometimes if you remove the logo, wait a bit, and try to upload a new one it will work. ![Image](https://github.com/user-attachments/assets/fa70bb6a-36da-4e9e-89af-bb8fe0268414) ### Version and Environment Docker. Pocket `v.1.2.0` ### Log Output When I *remove* the problematic logo (SVG if it matters), the following panic is logged: ``` pocket-id | [GIN] 2025/06/04 - 18:05:07 | 200 | 13.261287ms | 172.71.150.151 | GET "/api/user-groups?sort[column]=friendlyName&sort[direction]=asc" pocket-id | [GIN] 2025/06/04 - 18:05:07 | 200 | 13.325207ms | 172.71.150.151 | GET "/api/user-groups?sort[column]=friendlyName&sort[direction]=asc" pocket-id | [GIN] 2025/06/04 - 18:05:11 | 500 | 1.141567ms | 172.71.150.151 | DELETE "/api/oidc/clients/5648bf99-fc7a-4653-a306-3c6791412ee5/logo" pocket-id | pocket-id | pocket-id | 2025/06/04 18:05:11 [Recovery] 2025/06/04 - 18:05:11 panic recovered: pocket-id | runtime error: invalid memory address or nil pointer dereference pocket-id | runtime/panic.go:262 (0x8764f) pocket-id | runtime/signal_unix.go:925 (0x8761c) pocket-id | github.com/pocket-id/pocket-id/backend/internal/service/oidc_service.go:756 (0x6daa20) pocket-id | github.com/pocket-id/pocket-id/backend/internal/controller/oidc_controller.go:577 (0xd4aa5b) pocket-id | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd3f17f) pocket-id | github.com/pocket-id/pocket-id/backend/internal/middleware/rate_limit.go:44 (0xd3f130) pocket-id | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2097b) pocket-id | github.com/pocket-id/pocket-id/backend/internal/middleware/error_handler.go:24 (0xd5f3ef) pocket-id | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2097b) pocket-id | github.com/pocket-id/pocket-id/backend/internal/middleware/cors.go:24 (0xd5f3a3) pocket-id | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2c813) pocket-id | github.com/gin-gonic/gin@v1.10.0/logger.go:249 (0xd2c7f4) pocket-id | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2d467) pocket-id | github.com/gin-gonic/gin@v1.10.0/recovery.go:102 (0xd2d44c) pocket-id | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2c813) pocket-id | github.com/gin-gonic/gin@v1.10.0/logger.go:249 (0xd2c7f4) pocket-id | github.com/gin-gonic/gin@v1.10.0/context.go:185 (0xd2bcb3) pocket-id | github.com/gin-gonic/gin@v1.10.0/gin.go:633 (0xd2b83c) pocket-id | github.com/gin-gonic/gin@v1.10.0/gin.go:589 (0xd2b47f) pocket-id | net/http/server.go:3301 (0x31115b) pocket-id | net/http/server.go:2102 (0x2f104b) pocket-id | runtime/asm_arm64.s:1223 (0x8cc63) pocket-id | pocket-id | [GIN] 2025/06/04 - 18:05:11 | 200 | 2.164934ms | 172.71.150.151 | PUT "/api/oidc/clients/5648bf99-fc7a-4653-a306-3c6791412ee5" pocket-id | [GIN] 2025/06/04 - 18:05:11 | 200 | 2.199055ms | 172.71.150.151 | PUT "/api/oidc/clients/5648bf99-fc7a-4653-a306-3c6791412ee5" ```
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/pocket-id#105