OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
[#67055] Do not use unspecified ServiceProviderConfig.AuthenticationSchemes.type
Pavel Balashou5add4fbbe830
diff --git a/config/static_links.yml b/config/static_links.ymlindex c310cc35772..6d977946df6 100644--- a/config/static_links.yml+++ b/config/static_links.yml@@ -182,10 +182,8 @@ sysadmin_docs:href: https://www.openproject.org/docs/system-admin-guide/authentication/saml/scim:href: https://www.openproject.org/docs/system-admin-guide/authentication/scim/- scim_static_access_token_authentication_method:- href: https://www.openproject.org/docs/system-admin-guide/authentication/scim/#a-static-access-token- scim_oauth2_client_credentials_authentication_method:- href: https://www.openproject.org/docs/system-admin-guide/authentication/scim/#b-oauth-20-client-credentials+ scim_authentication:+ href: https://www.openproject.org/docs/system-admin-guide/authentication/scim/#step-3-choose-an-authentication-methodscim_jwt_authetication_method:href: https://www.openproject.org/docs/system-admin-guide/authentication/scim/#c-jwt-from-identity-providertext_formatting:diff --git a/lib/open_project_scimitar.rb b/lib/open_project_scimitar.rbindex c233efb1bb0..ebcfbb435d6 100644--- a/lib/open_project_scimitar.rb+++ b/lib/open_project_scimitar.rb@@ -30,23 +30,11 @@module OpenProjectScimitarAUTHENTICATION_SCHEMES = [- Scimitar::AuthenticationScheme.new(- type: "oauth2",- name: "OAuth2",- description: OpenProject::Static::Links.url_for(:sysadmin_docs, :scim_static_access_token_authentication_method,- localize_url: false)- ),Scimitar::AuthenticationScheme.new(type: "oauthbearertoken",name: "OAuth Bearer Token",- description: OpenProject::Static::Links.url_for(:sysadmin_docs, :scim_oauth2_client_credentials_authentication_method,- localize_url: false)- ),- Scimitar::AuthenticationScheme.new(- type: "oidcjwt",- name: "OpenID Provider JWT",- description: OpenProject::Static::Links.url_for(:sysadmin_docs, :scim_jwt_authetication_method,- localize_url: false)+ description: "Bearer Token can be obtained in 3 different ways" \+ "(#{OpenProject::Static::Links.url_for(:sysadmin_docs, :scim_authentication, localize_url: false)})")].freezeenddiff --git a/spec/requests/scim_v2/service_provider_config_spec.rb b/spec/requests/scim_v2/service_provider_config_spec.rbindex de80e59efc8..a7de242cf00 100644--- a/spec/requests/scim_v2/service_provider_config_spec.rb+++ b/spec/requests/scim_v2/service_provider_config_spec.rb@@ -47,15 +47,10 @@ RSpec.describe "SCIM API ServiceProviderConfig" doget "/scim_v2/ServiceProviderConfig", {}, headersresponse_body = JSON.parse(last_response.body)- expect(response_body).to include("authenticationSchemes" => [{ "description" => "https://www.openproject.org/docs/system-admin-guide/authentication/scim/#a-static-access-token",- "name" => "OAuth2",- "type" => "oauth2" },- { "description" => "https://www.openproject.org/docs/system-admin-guide/authentication/scim/#b-oauth-20-client-credentials",+ expect(response_body).to include("authenticationSchemes" => [{ "description" => "Bearer Token can be obtained in 3 different ways(https://www.openproject.org/docs/system-admin-guide/authentication/scim/#step-3-choose-an-authentication-method)",+"name" => "OAuth Bearer Token",- "type" => "oauthbearertoken" },- { "description" => "https://www.openproject.org/docs/system-admin-guide/authentication/scim/#c-jwt-from-identity-provider",- "name" => "OpenID Provider JWT",- "type" => "oidcjwt" }],+ "type" => "oauthbearertoken" }],"bulk" => { "supported" => false },"changePassword" => { "supported" => false },"etag" => { "supported" => false },@@ -86,15 +81,9 @@ RSpec.describe "SCIM API ServiceProviderConfig" doexpect(last_response).to have_http_status(200)response_body = JSON.parse(last_response.body)expect(response_body.keys).to eq(["meta", "schemas", "authenticationSchemes"])- expect(response_body).to include("authenticationSchemes" => [{ "description" => "https://www.openproject.org/docs/system-admin-guide/authentication/scim/#a-static-access-token",- "name" => "OAuth2",- "type" => "oauth2" },- { "description" => "https://www.openproject.org/docs/system-admin-guide/authentication/scim/#b-oauth-20-client-credentials",+ expect(response_body).to include("authenticationSchemes" => [{ "description" => "Bearer Token can be obtained in 3 different ways(https://www.openproject.org/docs/system-admin-guide/authentication/scim/#step-3-choose-an-authentication-method)","name" => "OAuth Bearer Token",- "type" => "oauthbearertoken" },- { "description" => "https://www.openproject.org/docs/system-admin-guide/authentication/scim/#c-jwt-from-identity-provider",- "name" => "OpenID Provider JWT",- "type" => "oidcjwt" }],+ "type" => "oauthbearertoken" }],"schemas" => ["urn:ietf:params:scim:schemas:core:2.0:ServiceProviderConfig"])endend