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: adfs login when iframe doesn't work by storing tokens #864

Merged
merged 2 commits into from
Aug 31, 2022

Conversation

BugGambit
Copy link
Contributor

Aramco login to Fusion today. They are using ADFS2016 as their IdP. The problem is that iFrames are blocked. Therefore silent login doesn't work (and is currently used to retrieve tokens in Fusion when we don't persist them). This PR persists tokens to sessionStorage to avoid relying on silent logins.

@BugGambit BugGambit requested a review from a team August 31, 2022 13:20
@codecov
Copy link

codecov bot commented Aug 31, 2022

Codecov Report

Merging #864 (0d4c25c) into master (de3557f) will decrease coverage by 4.95%.
The diff coverage is 68.15%.

@@            Coverage Diff             @@
##           master     #864      +/-   ##
==========================================
- Coverage   84.06%   79.11%   -4.96%     
==========================================
  Files          70      105      +35     
  Lines        1952     3332    +1380     
  Branches      249      488     +239     
==========================================
+ Hits         1641     2636     +995     
- Misses        301      673     +372     
- Partials       10       23      +13     
Impacted Files Coverage Δ
packages/beta/src/cogniteClient.ts 100.00% <ø> (ø)
packages/core/src/httpClient/httpError.ts 90.00% <ø> (ø)
packages/core/src/testUtils.ts 35.59% <0.00%> (-19.58%) ⬇️
packages/stable/src/__tests__/testUtils.ts 96.42% <ø> (-3.58%) ⬇️
packages/stable/src/api/3d/assetMappings3DApi.ts 79.16% <ø> (-20.84%) ⬇️
packages/stable/src/api/3d/nodes3DApi.ts 81.81% <ø> (-18.19%) ⬇️
packages/stable/src/api/3d/revealNodes3DApi.ts 100.00% <ø> (ø)
packages/stable/src/api/3d/revealSectors3DApi.ts 100.00% <ø> (ø)
packages/stable/src/api/3d/revisions3DApi.ts 95.65% <ø> (-4.35%) ⬇️
...kages/stable/src/api/annotations/annotationsApi.ts 100.00% <ø> (ø)
... and 124 more

@BugGambit BugGambit merged commit c9e1860 into master Aug 31, 2022
@BugGambit BugGambit deleted the f1/fix_adfs_silent_login branch August 31, 2022 18:59
cognite-ornellas pushed a commit that referenced this pull request Sep 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants