1
0
mirror of https://github.com/matrix-org/matrix-authentication-service.git synced 2025-11-20 12:02:22 +03:00
Commit Graph

36 Commits

Author SHA1 Message Date
Quentin Gliech
92d6f5b087 data-model: simplify the oauth2 clients 2022-12-08 15:29:15 +01:00
Quentin Gliech
4227fa7a83 Add a global HTTP client factory 2022-12-05 19:39:51 +01:00
Quentin Gliech
0ca4366f75 Use associated error type in claims validator instead of anyhow. 2022-12-01 14:34:19 +01:00
Quentin Gliech
78778648ca Allow fetching more nodes by their IDs 2022-11-18 13:43:01 +01:00
Quentin Gliech
559181c2c3 Pass the rng and clock around 2022-11-02 18:59:00 +01:00
Quentin Gliech
e2142f9cd4 Database refactoring 2022-11-02 18:59:00 +01:00
Kévin Commaille
80d317f23c Add variants for unknown values on mas-iana types
Remove the Copy derive and mark enums as non-exhaustive.
2022-09-28 13:43:39 +02:00
Kévin Commaille
0452ac10e6 Move claim hash token function to mas-jose crate
Change the hash function according to the signature algorithm,
according to the OpendID Connect spec.
2022-09-06 14:15:05 +02:00
Quentin Gliech
fa47f6e150 Upgrade axum to 0.6.0-rc.1 2022-09-06 13:11:54 +02:00
Quentin Gliech
b9e46dfc55 Some cleanups 2022-09-02 15:37:46 +02:00
Quentin Gliech
8c25dc03ce Move the Encrypter from the config to the keystore 2022-09-02 15:37:46 +02:00
Quentin Gliech
e1d50b818e Add a dedicated keystore crate 2022-09-02 15:37:46 +02:00
Quentin Gliech
ca125a14c5 WIP: better JOSE 2022-09-02 15:37:46 +02:00
Kévin Commaille
ee47c821e3 Use an enum for client error codes
Replace the ClientError constants with From<ClientErrorCode>.
2022-09-01 17:59:37 +02:00
Quentin Gliech
649e5cd645 Move the PKCE validation logic to oauth2-types 2022-08-03 13:57:31 +02:00
Quentin Gliech
372b32a780 Make PKCE implementation compliant with RFC7636
This checks for the PKCE code_verifier length as well as the characters
used. It also give better errors when the PKCE verifier is invalid.

Fixes #316
2022-08-03 13:57:31 +02:00
Jonas Platte
0e1b2ea6b1 Remove implied StatusCode::OK 2022-05-10 11:01:24 +02:00
Quentin Gliech
f4353b660e Have a unified URL builder/router 2022-05-10 09:52:48 +02:00
Quentin Gliech
25193ebaa5 Support signed userinfo responses 2022-04-21 11:49:49 +02:00
Quentin Gliech
5c14611b96 Simple dynamic client registration 2022-04-19 12:23:19 +02:00
Quentin Gliech
9a76139bb4 Return proper errors on the OAuth token endpoint 2022-04-06 17:35:29 +02:00
Quentin Gliech
35310849c7 Axum migration: /oauth2/token 2022-04-06 17:35:29 +02:00
Quentin Gliech
62f633a716 Move clients to the database 2022-03-08 19:07:46 +01:00
Quentin Gliech
beef393bc8 Support the email scope 2022-02-25 16:19:38 +01:00
Quentin Gliech
cad6d54ddb Reply with proper errors on the OAuth token endpoint 2022-02-25 11:28:23 +01:00
Quentin Gliech
2df40762a2 Dedicated HTTP server/client crate
Also have better names for the HTTP routes
2022-02-10 16:38:16 +01:00
Quentin Gliech
7e24cd0948 Move secrets and oauth2 clients config 2022-02-01 09:34:55 +01:00
Quentin Gliech
c0e5b66ea4 Move public base URL from oauth2 config to http config 2022-02-01 09:34:55 +01:00
Quentin Gliech
571f484894 Revoke OAuth session on code reuse 2022-01-14 13:20:14 +01:00
Quentin Gliech
5b9c35a079 Use iana generated types in more places 2022-01-12 12:22:54 +01:00
Quentin Gliech
2844706bb1 Multiple IANA codegen enhancement
- JWS/JWE algorithms are properly splitted
 - Enums now have a proper description
 - They implement FromStr and Display
 - mas-jose does not reexport mas-iana anymore
2022-01-12 10:58:27 +01:00
Quentin Gliech
a30d4b58f0 Add exp claim in id_tokens 2022-01-10 17:59:57 +01:00
Quentin Gliech
5631300dc3 Claims handling in JOSE library 2022-01-10 17:41:48 +01:00
Quentin Gliech
f933ace007 New JWT/JOSE crate
Still WIP, needs to handle time related claims
2022-01-04 22:28:00 +01:00
Quentin Gliech
a55e8af2c8 Cut down a lot on compilation time 2021-12-17 19:55:22 +01:00
Quentin Gliech
2f97ca685d Split the core crate 2021-12-17 18:04:30 +01:00