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

PAS-554 | Fix Access Denied creating application in different session #672

Conversation

jonashendrickx
Copy link
Member

@jonashendrickx jonashendrickx commented Aug 15, 2024

Ticket

Description

When an admin signs in, all the applications belonging to the organization are added to the claims/token. When an application is added in a different session, you will get an access denied message in your old session, because it doesn't know the application was created for your organization.

Under very particular circumstances, where all the stars would have to align (never happens), you could theoretically access an application of a different organization. Although the impact would be fairly small as that application would have to be newly created by the new organization, and deleted by the old one in quick succession.

Shape

Screenshots

Checklist

I did the following to ensure that my changes were tested thoroughly:

  • __

I did the following to ensure that my changes do not introduce security vulnerabilities:

  • __

@jonashendrickx jonashendrickx requested a review from a team as a code owner August 15, 2024 14:01
Copy link

codecov bot commented Aug 15, 2024

Codecov Report

Attention: Patch coverage is 0% with 11 lines in your changes missing coverage. Please review.

Project coverage is 34.85%. Comparing base (4d4b6cb) to head (5d1c104).
Report is 2 commits behind head on main.

Files Patch % Lines
src/AdminConsole/Authorization/HasAppHandler.cs 0.00% 10 Missing ⚠️
...nsole/Services/CustomUserClaimsPrincipalFactory.cs 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #672      +/-   ##
==========================================
- Coverage   34.85%   34.85%   -0.01%     
==========================================
  Files         565      565              
  Lines       30944    30945       +1     
  Branches      924      923       -1     
==========================================
  Hits        10785    10785              
- Misses      20017    20018       +1     
  Partials      142      142              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@jonashendrickx jonashendrickx merged commit 4d08754 into main Aug 15, 2024
16 checks passed
@jonashendrickx jonashendrickx deleted the PAS-554-Having-an-open-session-in-multiple-windows-can-sometimes-lead-to-Access-Denied-errors-under-certain-conditions branch August 15, 2024 16:47
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