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
Reveal first two and last two letters of the Nextcloud client secret
Wieland Lindenthalc6dd6e6338b2
diff --git a/app/helpers/oauth_helper.rb b/app/helpers/oauth_helper.rbindex 90c635dfac0..032e278624d 100644--- a/app/helpers/oauth_helper.rb+++ b/app/helpers/oauth_helper.rb@@ -44,7 +44,7 @@ module OAuthHelperdef short_secret(secret)result = ""if secret.is_a?(String) && secret.present?- result = "#{secret[...2]}****#{secret[-2...]}"+ result = "#{secret[...2]}●●●●#{secret[-2...]}"endresultdiff --git a/modules/storages/app/views/storages/admin/storages/edit.html.erb b/modules/storages/app/views/storages/admin/storages/edit.html.erbindex 87708528d87..67b0b149bde 100644--- a/modules/storages/app/views/storages/admin/storages/edit.html.erb+++ b/modules/storages/app/views/storages/admin/storages/edit.html.erb@@ -56,7 +56,7 @@<div class="attributes-key-value--key"><%= t("storages.provider_types.#{@object.provider_type}") %> <%= t(:'storages.label_oauth_client_secret') %></div><div class="attributes-key-value--value-container"><div class="attributes-key-value--value -text">- <span>●●●●●●●●●●●●●●●●</span>+ <span><%= short_secret(@object.oauth_client.client_secret) %></span></div></div></div>diff --git a/modules/storages/app/views/storages/admin/storages/show.html.erb b/modules/storages/app/views/storages/admin/storages/show.html.erbindex a5534245e2f..7f9f2f9bd91 100644--- a/modules/storages/app/views/storages/admin/storages/show.html.erb+++ b/modules/storages/app/views/storages/admin/storages/show.html.erb@@ -134,7 +134,7 @@ See COPYRIGHT and LICENSE files for more details.<div class="attributes-key-value--key"><%= t("storages.provider_types.#{@object.provider_type}") %> <%= t(:'storages.label_oauth_client_secret') %></div><div class="attributes-key-value--value-container"><div class="attributes-key-value--value -text">- <span>●●●●●●●●●●●●●●●●</span>+ <span><%= short_secret(@object.oauth_client.client_secret) %></span></div></div></div>