|
44 | 44 | - `internal/config` provides OIDC options/flags (issuer, client ID/secret, scopes, insecure). |
45 | 45 | - `internal/event` supplies the logger used for audit and error reporting. |
46 | 46 |
|
47 | | -### Operational Tips |
48 | | - |
49 | | -- Always call `RedirectURL(siteUrl)` to build callbacks that respect reverse proxies and base URIs. |
50 | | -- Reuse `HttpClient(insecure)` so timeouts and TLS settings stay consistent. |
51 | | -- When adding claims processing, keep parsing isolated (e.g., new helper) and ensure failures do not block sign‑in unless required. |
52 | | - |
53 | 47 | ### Configuration & Safety |
54 | 48 |
|
55 | 49 | - Enforce `https` for issuers unless `insecure` is explicitly set (intended for dev/test). |
|
67 | 61 | - [ ] Add integration doc/tests for Entra app registration requirements (`groupMembershipClaims=SecurityGroup|All|ApplicationGroup`) and token size limits (~200 groups). |
68 | 62 | - [ ] Update Pro parity notes so LDAP and OIDC group mappings share helpers and behavior. |
69 | 63 |
|
70 | | -#### Related Resources & Specs |
| 64 | +> **Note:** Entra ID security groups are only supported in PhotoPrism® Pro. |
| 65 | +
|
| 66 | +### Documentation & References |
71 | 67 |
|
72 | 68 | - Microsoft Entra group claims: https://learn.microsoft.com/en-us/entra/identity-platform/access-token-claims-reference#groups-claim |
73 | 69 | - Group overage handling: https://learn.microsoft.com/en-us/entra/identity-platform/howto-add-app-roles-in-azure-ad-apps#group-overage-and-_claim_names |
74 | 70 | - Token customization guidance: https://learn.microsoft.com/en-us/entra/architecture/customize-tokens |
75 | 71 |
|
76 | | -> **Note:** Entra ID security groups are only supported in PhotoPrism® Pro. |
| 72 | +### Operational Tips |
| 73 | + |
| 74 | +- Always call `RedirectURL(siteUrl)` to build callbacks that respect reverse proxies and base URIs. |
| 75 | +- Reuse `HttpClient(insecure)` so timeouts and TLS settings stay consistent. |
| 76 | +- When adding claims processing, keep parsing isolated (e.g., new helper) and ensure failures do not block sign‑in unless required. |
77 | 77 |
|
78 | | -### Testing |
| 78 | +### Test Guidelines |
79 | 79 |
|
80 | 80 | - Unit tests: `go test ./internal/auth/oidc -count=1` |
81 | 81 | - Tests cover discovery failures, PKCE detection, redirect URL construction, username extraction, and code‑exchange error handling. |
|
0 commit comments