[GH-ISSUE #634] OPEN_ID Login impossible #497

Open
opened 2026-02-25 21:32:03 +03:00 by kerem · 9 comments
Owner

Originally created by @piepmax on GitHub (Nov 10, 2024).
Original GitHub issue: https://github.com/ciur/papermerge/issues/634

Originally assigned to: @ciur on GitHub.

Hi,
open-id login is impossible. The application doesn't work as soon as i enter the oidc environment variables.
The following error occurs:
Field required [type=missing, input_value={'papermerge__auth__oidc_...eth.name/oidc/callback'}, input_type=dict]
2024-11-10T08:17:43.121684274Z For further information visit https://errors.pydantic.dev/2.7/v/missing

Info:

  • Papermerge Version 3.2 and 3.3
Originally created by @piepmax on GitHub (Nov 10, 2024). Original GitHub issue: https://github.com/ciur/papermerge/issues/634 Originally assigned to: @ciur on GitHub. Hi, open-id login is impossible. The application doesn't work as soon as i enter the oidc environment variables. The following error occurs: Field required [type=missing, input_value={'papermerge__auth__oidc_...eth.name/oidc/callback'}, input_type=dict] 2024-11-10T08:17:43.121684274Z For further information visit https://errors.pydantic.dev/2.7/v/missing **Info:** - Papermerge Version 3.2 and 3.3
Author
Owner

@ciur commented on GitHub (Nov 10, 2024):

What OpenID provider do you use ?
What's your setup ?

<!-- gh-comment-id:2466651094 --> @ciur commented on GitHub (Nov 10, 2024): What OpenID provider do you use ? What's your setup ?
Author
Owner

@piepmax commented on GitHub (Nov 10, 2024):

I've tried it with azure ad and afterwards with keycloak.
Both didn't work :/
This is my configuration:
msedge_2024-11-10_11-43-37

<!-- gh-comment-id:2466682975 --> @piepmax commented on GitHub (Nov 10, 2024): I've tried it with azure ad and afterwards with keycloak. Both didn't work :/ This is my configuration: ![msedge_2024-11-10_11-43-37](https://github.com/user-attachments/assets/2eb466ac-3132-4b49-bf3d-391a9753c428)
Author
Owner

@ciur commented on GitHub (Nov 11, 2024):

Is there an error on auth server side (keycloak) ?
Could you pls paste here (last, which maybe contain error, warning, or some evidence that it is being accessed by client) logs from keycloak ?
What is the configuration of the client on keycloak side ?
What are the errors on Papermerge side ?

<!-- gh-comment-id:2467282398 --> @ciur commented on GitHub (Nov 11, 2024): Is there an error on auth server side (keycloak) ? Could you pls paste here (last, which maybe contain error, warning, or some evidence that it is being accessed by client) logs from keycloak ? What is the configuration of the client on keycloak side ? What are the errors on Papermerge side ?
Author
Owner

@piepmax commented on GitHub (Nov 11, 2024):

No, there are no errors on keycloak.
This is the docker output:

2.168.178.229 - - [11/Nov/2024:06:43:09 +0000] "GET /favicon.ico HTTP/1.1" 500 579 "http://192.168.178.50/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36 Edg/130.0.0.0"
2024/11/11 06:43:09 [error] 58#58: *12 no live upstreams while connecting to upstream, client: 192.168.178.229, server: _, request: "GET /favicon.ico HTTP/1.1", subrequest: "/verify", upstream: "http://localhost/verify", host: "192.168.178.50", referrer: "http://192.168.178.50/"
2024/11/11 06:43:09 [error] 58#58: *12 auth request unexpected status: 502 while sending to client, client: 192.168.178.229, server: _, request: "GET /favicon.ico HTTP/1.1", host: "192.168.178.50", referrer: "http://192.168.178.50/"

192.168.178.50 is the papermerge host
192.1678.178.229 is the client

<!-- gh-comment-id:2467362562 --> @piepmax commented on GitHub (Nov 11, 2024): No, there are no errors on keycloak. This is the docker output: ``` 2.168.178.229 - - [11/Nov/2024:06:43:09 +0000] "GET /favicon.ico HTTP/1.1" 500 579 "http://192.168.178.50/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36 Edg/130.0.0.0" 2024/11/11 06:43:09 [error] 58#58: *12 no live upstreams while connecting to upstream, client: 192.168.178.229, server: _, request: "GET /favicon.ico HTTP/1.1", subrequest: "/verify", upstream: "http://localhost/verify", host: "192.168.178.50", referrer: "http://192.168.178.50/" 2024/11/11 06:43:09 [error] 58#58: *12 auth request unexpected status: 502 while sending to client, client: 192.168.178.229, server: _, request: "GET /favicon.ico HTTP/1.1", host: "192.168.178.50", referrer: "http://192.168.178.50/" ``` 192.168.178.50 is the papermerge host 192.1678.178.229 is the client
Author
Owner

@ciur commented on GitHub (Nov 11, 2024):

In first message you pasted following error:

Field required [type=missing, input_value={'papermerge__auth__oidc_...eth.name/oidc/callback'}, input_type=dict]

It means you are missing "papermerge__auth__oidc_..." variable. This translates to missing PAPERMERGE__AUTH__OIDC_... environment variable.

Can you figure out from logs complete variable name and provide it here?
Could you please paste here full trace of

Field required [type=missing, input_value={'papermerge__auth__oidc_...eth.name/oidc/callback'}, input_type=dict]
2024-11-10T08:17:43.121684274Z For further information visit https://errors.pydantic.dev/2.7/v/missing

of above error ?

<!-- gh-comment-id:2467424120 --> @ciur commented on GitHub (Nov 11, 2024): In first message you pasted following error: ``` Field required [type=missing, input_value={'papermerge__auth__oidc_...eth.name/oidc/callback'}, input_type=dict] ``` It means you are missing "papermerge__auth__oidc_..." variable. This translates to missing `PAPERMERGE__AUTH__OIDC_...` environment variable. Can you figure out from logs complete variable name and provide it here? Could you please paste here full trace of ``` Field required [type=missing, input_value={'papermerge__auth__oidc_...eth.name/oidc/callback'}, input_type=dict] 2024-11-10T08:17:43.121684274Z For further information visit https://errors.pydantic.dev/2.7/v/missing ``` of above error ?
Author
Owner

@piepmax commented on GitHub (Nov 11, 2024):

@ciur those are the variables:
msedge_muI8mgzdfP

<!-- gh-comment-id:2467444717 --> @piepmax commented on GitHub (Nov 11, 2024): @ciur those are the variables: ![msedge_muI8mgzdfP](https://github.com/user-attachments/assets/d64fd58e-78b9-4a93-ae2f-5726031ada16)
Author
Owner

@ciur commented on GitHub (Nov 11, 2024):

Still, my question was about the missing information: "...":

Field required [type=missing, input_value={'papermerge__auth__oidc_...eth.name/oidc/callback'}, input_type=dict]
2024-11-10T08:17:43.121684274Z For further information visit https://errors.pydantic.dev/2.7/v/missing

Could you provide full error (without "...")?

<!-- gh-comment-id:2468981763 --> @ciur commented on GitHub (Nov 11, 2024): Still, my question was about the missing information: "...": ``` Field required [type=missing, input_value={'papermerge__auth__oidc_...eth.name/oidc/callback'}, input_type=dict] 2024-11-10T08:17:43.121684274Z For further information visit https://errors.pydantic.dev/2.7/v/missing ``` Could you provide full error (without "...")?
Author
Owner

@piepmax commented on GitHub (Nov 11, 2024):

I‘d like to but the Logs are shortened by default :/

<!-- gh-comment-id:2468987814 --> @piepmax commented on GitHub (Nov 11, 2024): I‘d like to but the Logs are shortened by default :/
Author
Owner

@piepmax commented on GitHub (Nov 26, 2024):

@ciur could the problem be caused by the https?
image

<!-- gh-comment-id:2500253209 --> @piepmax commented on GitHub (Nov 26, 2024): @ciur could the problem be caused by the https? ![image](https://github.com/user-attachments/assets/88dab279-c6f5-4659-ac50-269a6890dbd1)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/papermerge#497
No description provided.