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

Dedicated HTTP server/client crate

Also have better names for the HTTP routes
This commit is contained in:
Quentin Gliech
2022-02-09 13:55:13 +01:00
parent 459ae34ebb
commit 2df40762a2
27 changed files with 335 additions and 126 deletions

View File

@@ -37,7 +37,7 @@ use mas_storage::{
};
use mas_warp_utils::{
errors::WrapError,
filters::{client::client_authentication, database::connection, url_builder::UrlBuilder},
filters::{self, client::client_authentication, database::connection, url_builder::UrlBuilder},
reply::with_typed_header,
};
use oauth2_types::{
@@ -108,6 +108,7 @@ pub fn filter(
let issuer = builder.oidc_issuer();
warp::path!("oauth2" / "token")
.and(filters::trace::name("POST /oauth2/token"))
.and(
warp::post()
.and(client_authentication(clients_config, audience))