diff --git a/packages/providers/shield-oidc/src/subprovider.rs b/packages/providers/shield-oidc/src/subprovider.rs index 39754e6..19f52be 100644 --- a/packages/providers/shield-oidc/src/subprovider.rs +++ b/packages/providers/shield-oidc/src/subprovider.rs @@ -12,8 +12,8 @@ use crate::provider::OIDC_PROVIDER_ID; #[derive(Clone, Copy, Debug, Eq, PartialEq)] pub enum OidcProviderVisibility { - Private, Public, + Unlisted, } #[derive(Clone, Copy, Debug, Eq, PartialEq)] diff --git a/packages/storage/shield-sea-orm/src/entities/oauth_provider.rs b/packages/storage/shield-sea-orm/src/entities/oauth_provider.rs index b7ce977..c74226c 100644 --- a/packages/storage/shield-sea-orm/src/entities/oauth_provider.rs +++ b/packages/storage/shield-sea-orm/src/entities/oauth_provider.rs @@ -36,10 +36,10 @@ pub enum OauthProviderType { enum_name = "oauth_provider_visibility" )] pub enum OauthProviderVisibility { - #[sea_orm(string_value = "private")] - Private, #[sea_orm(string_value = "public")] Public, + #[sea_orm(string_value = "unlisted")] + Unlisted, } #[derive(Clone, Debug, PartialEq, DeriveEntityModel, Eq, Serialize, Deserialize)] diff --git a/packages/storage/shield-sea-orm/src/entities/oidc_provider.rs b/packages/storage/shield-sea-orm/src/entities/oidc_provider.rs index 8933aba..413d61b 100644 --- a/packages/storage/shield-sea-orm/src/entities/oidc_provider.rs +++ b/packages/storage/shield-sea-orm/src/entities/oidc_provider.rs @@ -32,10 +32,10 @@ pub enum OidcProviderType { enum_name = "oidc_provider_visibility" )] pub enum OidcProviderVisibility { - #[sea_orm(string_value = "private")] - Private, #[sea_orm(string_value = "public")] Public, + #[sea_orm(string_value = "unlisted")] + Unlisted, } #[derive(Clone, Debug, PartialEq, DeriveEntityModel, Eq, Serialize, Deserialize)] @@ -58,6 +58,8 @@ pub struct Model { #[sea_orm(column_type = "Text", nullable)] pub redirect_url: Option, #[sea_orm(column_type = "Text", nullable)] + pub discovery_url: Option, + #[sea_orm(column_type = "Text", nullable)] pub issuer_url: Option, #[sea_orm(column_type = "Text", nullable)] pub authorization_url: Option, diff --git a/packages/storage/shield-sea-orm/src/migrations/providers/oauth/m20241211_095111_create_provider_oauth.rs b/packages/storage/shield-sea-orm/src/migrations/providers/oauth/m20241211_095111_create_provider_oauth.rs index edd776a..31846d4 100644 --- a/packages/storage/shield-sea-orm/src/migrations/providers/oauth/m20241211_095111_create_provider_oauth.rs +++ b/packages/storage/shield-sea-orm/src/migrations/providers/oauth/m20241211_095111_create_provider_oauth.rs @@ -245,12 +245,12 @@ enum OauthProviderVisibility { Table, Public, - Private, + Unlisted, } impl OauthProviderVisibility { fn variants() -> Vec { - vec![Self::Public, Self::Private] + vec![Self::Public, Self::Unlisted] } } diff --git a/packages/storage/shield-sea-orm/src/migrations/providers/oidc/m20241211_184751_create_provider_oidc.rs b/packages/storage/shield-sea-orm/src/migrations/providers/oidc/m20241211_184751_create_provider_oidc.rs index dd49332..20a0203 100644 --- a/packages/storage/shield-sea-orm/src/migrations/providers/oidc/m20241211_184751_create_provider_oidc.rs +++ b/packages/storage/shield-sea-orm/src/migrations/providers/oidc/m20241211_184751_create_provider_oidc.rs @@ -86,6 +86,7 @@ impl MigrationTrait for Migration { .col(ColumnDef::new(OidcProvider::ClientSecret).text()) .col(ColumnDef::new(OidcProvider::Scopes).text()) .col(ColumnDef::new(OidcProvider::RedirectUrl).text()) + .col(ColumnDef::new(OidcProvider::DiscoveryUrl).text()) .col(ColumnDef::new(OidcProvider::IssuerUrl).text()) .col(ColumnDef::new(OidcProvider::AuthorizationUrl).text()) .col(ColumnDef::new(OidcProvider::AuthorizationUrlParams).text()) @@ -243,12 +244,12 @@ enum OidcProviderVisibility { Table, Public, - Private, + Unlisted, } impl OidcProviderVisibility { fn variants() -> Vec { - vec![Self::Public, Self::Private] + vec![Self::Public, Self::Unlisted] } } @@ -279,6 +280,7 @@ enum OidcProvider { ClientSecret, Scopes, RedirectUrl, + DiscoveryUrl, IssuerUrl, AuthorizationUrl, AuthorizationUrlParams,