feat: Add support for requesting additional scopes

This commit is contained in:
Ginger committed 2026-07-02 16:34:38 -04:00
1 parent 52a4b9d586
commit 28263982cd
3 files changed
+18 -2

No files matched your search

+9 -1
View File
@@ -17,7 +17,7 @@ use either::{
use figment::providers::{Env, Format, Toml};
pub use figment::{Figment, value::Value as FigmentValue};
use lettre::message::Mailbox;
use openidconnect::{ClientId, ClientSecret};
use openidconnect::{ClientId, ClientSecret, Scope};
use regex::RegexSet;
use ruma::{
OwnedRoomId, OwnedRoomOrAliasId, OwnedServerName, OwnedUserId, RoomVersionId,
@@ -2486,6 +2486,14 @@ pub struct OidcConfig {
/// the identity provider.
pub client_secret: ClientSecret,
/// Additional scopes Continuwuity should request from the IDP. This may be
/// necessary to access certain claims. Continuwuity always requests the
/// `openid` scope.
///
/// default: []
#[serde(default)]
pub additional_scopes: Vec<Scope>,
/// Whether the user should be prompted to choose a localpart
/// when signing in for the first time. If this is `false`, Continuwuity
/// will attempt to use the value of the `preferred_username_claim`