Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix SAML login with OpenAM #17785

Merged
merged 1 commit into from
Sep 8, 2021
Merged

Fix SAML login with OpenAM #17785

merged 1 commit into from
Sep 8, 2021

Conversation

pawit-metabase
Copy link
Contributor

@pawit-metabase pawit-metabase commented Sep 7, 2021

OpenAM SAMLResponse contains "\r\n" every 76 characters leading our SAML code to think it's not base64-encoded.

Fix by relaxing our valid base64 check to ignore all spaces.

Fixes #15567

OpenAM SAMLResponse contains "\r\n" every 76 characters
leading our SAML code to think it's not base64-encoded.

Fix by relaxing our valid base64 check to ignore all spaces.

Fixes #15567
@codecov
Copy link

codecov bot commented Sep 7, 2021

Codecov Report

Merging #17785 (dcb7641) into master (9a9a987) will increase coverage by 0.01%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master   #17785      +/-   ##
==========================================
+ Coverage   62.90%   62.91%   +0.01%     
==========================================
  Files        1630     1631       +1     
  Lines       66581    66591      +10     
  Branches     7304     7307       +3     
==========================================
+ Hits        41882    41897      +15     
+ Misses      21510    21504       -6     
- Partials     3189     3190       +1     
Flag Coverage Δ
back-end 85.23% <100.00%> (-0.01%) ⬇️
front-end 38.91% <ø> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/metabase/util.clj 89.01% <100.00%> (+0.06%) ⬆️
src/metabase/api/pulse.clj 83.08% <0.00%> (-0.72%) ⬇️
...ontend/src/metabase/components/CollapseSection.jsx
...nd/src/metabase/components/CollapseSection.info.js
...ase/components/CollapseSection/CollapseSection.jsx 75.00% <0.00%> (ø)
...mponents/CollapseSection/CollapseSection.styled.js 100.00% <0.00%> (ø)
...components/CollapseSection/CollapseSection.info.js 0.00% <0.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9a9a987...dcb7641. Read the comment docs.

@rlotun rlotun added the backport Automatically create PR on current release branch on merge label Sep 7, 2021
@pawit-metabase pawit-metabase merged commit e10adcd into master Sep 8, 2021
@pawit-metabase pawit-metabase deleted the fix-openam-saml-login branch September 8, 2021 03:33
github-actions bot pushed a commit that referenced this pull request Sep 8, 2021
OpenAM SAMLResponse contains "\r\n" every 76 characters
leading our SAML code to think it's not base64-encoded.

Fix by relaxing our valid base64 check to ignore all spaces.

Fixes #15567
pawit-metabase added a commit that referenced this pull request Sep 8, 2021
OpenAM SAMLResponse contains "\r\n" every 76 characters
leading our SAML code to think it's not base64-encoded.

Fix by relaxing our valid base64 check to ignore all spaces.

Fixes #15567

Co-authored-by: pawit-metabase <pawit@metabase.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport Automatically create PR on current release branch on merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot login with SAML when IdP is OneLogin or OpenAM since 1.38.3
3 participants