Commit graph

49 commits

Author SHA1 Message Date
Michael Mayer
762901346e API: Regenerate swagger.json
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-11-23 14:18:25 +01:00
Michael Mayer
5e4e6d988c Pkg: Apply "golangci-lint" recommendations to authn & dsn packages #5330
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-11-21 15:33:23 +01:00
Michael Mayer
42edf100ee Vision: Allow use of configured service key for API authentication #5299
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-10-30 10:02:16 +01:00
Michael Mayer
cd7fa6adca Logs: Add package pkg/log/status to provide generic outcome constants
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-10-21 14:42:05 +02:00
Michael Mayer
b00dd133db Test: Use PascalCase names for all Go subtests in /pkg
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-10-02 15:03:47 +02:00
Michael Mayer
bae8ceb3a7 Auth: Support asymmetric JSON Web Tokens (JWT) and Key Sets (JWKS) #5230
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-09-25 17:52:44 +02:00
Michael Mayer
61ced7119c Auth: Refactor cluster configuration and provisioning API endpoints #98
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-09-24 08:28:38 +02:00
Michael Mayer
7f0717e9a0 Auth: Prevent login if additional accounts may not be created #4266
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-03-12 01:08:16 +01:00
Michael Mayer
01f15fa406 Backend: Update copyright notices
Signed-off-by: Michael Mayer <michael@photoprism.app>
2025-01-09 10:28:17 +01:00
graciousgrey
1140ceea40 Tests: Add unit tests 2024-07-17 16:38:34 +02:00
graciousgrey
5e94686a0d Tests: Add unit tests 2024-07-16 17:29:26 +02:00
Michael Mayer
9969590472 Account: Allow OIDC and LDAP users with password to use 2FA #782 #808
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-10 17:24:02 +02:00
Michael Mayer
fe9caaa83b OIDC: Improve CLI commands and add AuthIssuer to users and sessions #782
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-09 11:01:59 +02:00
Michael Mayer
e87f32fa5c OIDC: Add "address" to the default userinfo request scopes #782
see https://openid.net/specs/openid-connect-core-1_0.html#ScopeClaims

Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-09 06:55:06 +02:00
Michael Mayer
8b38d9ba68 OIDC: Allow local authentication if an (app) password has been set #782
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-06 11:53:55 +02:00
Michael Mayer
c970511c82 OIDC: Upgrade "zitadel/oidc" from v1 to v2 #782
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-06 11:15:23 +02:00
Michael Mayer
be68b4a01b OIDC: Append random 6-digit number if a username already exists #782
This also allows admins to set a login password for accounts registered
via OIDC.

Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-05 14:17:09 +02:00
Michael Mayer
ecbe422893 OIDC: Allow to use name claim as username #782
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-05 13:13:45 +02:00
Michael Mayer
fbb0284efa OIDC: Allow to use nickname as username #782
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-05 10:47:09 +02:00
Michael Mayer
3ecee16848 OIDC: Improve auth api logs and user verification #782
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-04 10:24:10 +02:00
Michael Mayer
a97f8d0795 API: Implement OIDC redirect endpoint #782
Requires further testing and refinement before it can be released.

Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-07-01 16:50:53 +02:00
Michael Mayer
b08b06c2fe WebDAV: Log successful authentication attempts via auth token #808 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-04-17 07:29:44 +02:00
Michael Mayer
c9213da4e6 Account: Generate app password from the UI #808 #4114
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-04-08 10:44:43 +02:00
Michael Mayer
33fac8f404 API: Implement creation and revocation of app passwords #808 #4114
Note that these changes are not production ready yet and must be tested
well before releasing them.

Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-04-07 16:44:30 +02:00
Michael Mayer
b11491c9d6 Auth: Refactor grant, method, and provider types in pkg/authn #808 #4114
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-04-06 15:13:15 +02:00
Michael Mayer
fdc2062d33 Account: Refactor access token API and request forms #808 #4114
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-04-05 14:46:11 +02:00
Michael Mayer
851a7393ef WebDAV: Refactor audit log messages
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-04-04 11:23:09 +02:00
Michael Mayer
31d1f06ffa Security: Refactor rate limits for failed authentication request #808
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-03-31 14:45:17 +02:00
Michael Mayer
37c3c9d624 Account: Add auth-related error messages to pkg/authn #808 #4114
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-03-29 12:16:26 +01:00
graciousgrey
afe6337bb5 Tests: Add unit tests #808 #3943 2024-03-27 17:01:17 +01:00
Michael Mayer
4425becb3d Auth: Implement 2FA setup and login in the web user interface #808 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-03-21 14:32:51 +01:00
graciousgrey
54c3ac9b6a Tests: Add unit tests 2024-01-31 14:34:56 +01:00
Michael Mayer
fc996ba65a Settings: Add buttons for configuring 2FA and App Passwords #782 #808
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-30 00:05:55 +01:00
Michael Mayer
d0ad3c23fb OAuth2: Remove client soft delete and fix client add command #213 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-29 21:08:01 +01:00
Michael Mayer
305e7bac68 OAuth2: Refactor "client add" and "client mod" CLI commands #808 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-29 13:54:50 +01:00
Michael Mayer
a4e2bb33b9 2FA: Rename "Auth Secret" to "App Password" for more clarity #782 #808
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-19 18:10:01 +01:00
Michael Mayer
06a18f5818 Auth: Add "access_token" authentication provider type #782 #808 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-19 14:41:08 +01:00
Michael Mayer
4ba32a7220 2FA: Add two-factor authentication key model and tests #782 #808 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-19 13:45:30 +01:00
graciousgrey
f08ef59245 Tests: Add unit tests 2024-01-17 14:56:08 +01:00
Michael Mayer
fed1d8ad95 Auth: Accept access token as passwd with fail rate limit #782 #808 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-14 18:28:17 +01:00
Michael Mayer
e21e462f00 Auth: Improve "auth add" and "client add" CLI commands #808 #3943
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-13 16:27:05 +01:00
Michael Mayer
0ca37b2c92 Docs: Update year in backend and frontend package file headers
Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-05 16:38:36 +01:00
Michael Mayer
713593da4e Auth: Add CLI command to create access tokens for apps #782 #808 #3943
You can now run "photoprism auth add" to create new client access tokens
that allow external applications to use the built-in REST API.

Signed-off-by: Michael Mayer <michael@photoprism.app>
2024-01-05 16:31:07 +01:00
Michael Mayer
467f7b1585 OAuth2: Add Client Credentials Authentication #213 #782 #808 #3730 #3943
This adds standard OAuth2 client credentials and bearer token support as
well as scope-based authorization checks for REST API clients. Note that
this initial implementation should not be used in production and that
the access token limit has not been implemented yet.

Signed-off-by: Michael Mayer <michael@photoprism.app>
2023-12-12 18:42:50 +01:00
graciousgrey
43e98cc687 Tests: Add unit tests for pkg/authn 2023-06-26 15:54:23 +02:00
Michael Mayer
5b73101442 Auth: Refactor user roles and auth providers in entity model #98
Signed-off-by: Michael Mayer <michael@photoprism.app>
2023-03-13 16:04:37 +01:00
Michael Mayer
50913e301c Auth: Prevent duplicate super admin accounts from being created #98
Signed-off-by: Michael Mayer <michael@photoprism.app>
2023-03-09 15:59:08 +01:00
Michael Mayer
d8ab9616a5 Auth: Refactor user management API and CLI commands #98
Signed-off-by: Michael Mayer <michael@photoprism.app>
2023-03-09 15:12:10 +01:00
Michael Mayer
60162b3fc5 Auth: Refactor user management API and CLI commands #98
Signed-off-by: Michael Mayer <michael@photoprism.app>
2023-03-08 23:30:39 +01:00