Skip to content

Commit

Permalink
allow_other_host for discourse plugin redirects
Browse files Browse the repository at this point in the history
  • Loading branch information
mortbauer committed Feb 16, 2024
1 parent f4a4528 commit 1d41a3a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion plugins/discourse/app/controllers/discourse_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ def redirect_to_with_payload(url, payload)
base64_payload = Base64.strict_encode64 payload.to_query
sso = CGI.escape base64_payload
sig = get_hmac_hex_string base64_payload
redirect_to "#{url}#{url.include?('?') ? '&' : '?'}sso=#{sso}&sig=#{sig}"


Check failure on line 17 in plugins/discourse/app/controllers/discourse_controller.rb

View workflow job for this annotation

GitHub Actions / test

Layout/TrailingWhitespace: Trailing whitespace detected.
redirect_to "#{url}#{url.include?('?') ? '&' : '?'}sso=#{sso}&sig=#{sig}", allow_other_host: true
end

def parse_payload
Expand Down

0 comments on commit 1d41a3a

Please sign in to comment.