Azure AD External User - Session revocation not working

Martin Kallukalam 440 Reputation points
2024-01-07T00:33:17.9466667+00:00

I think I am running into a bug with AAD external user.
Here is my scenario:
I have AAD member type user account. I have an app registration setup for authorization code flow.
I am able to checkout an access token, refresh token. If I revoke the session from going into AAD --> User--> Revoke session, then further access token request with the refresh token fails. This works perfectly as expected.
However I have an external guest user . I perform same scenario. However revoking session doesnt invalidate refresh token. I am able to use refresh token and get a new access token. In other words revoke session is not working for external guest user. Pls see screen short. I am performing the api calls with postman.
User's image

User's image

User's image

Microsoft Security Microsoft Entra Microsoft Entra External ID
Microsoft Security Microsoft Entra Microsoft Entra ID
{count} votes

3 answers

Sort by: Most helpful
  1. Vasil Michev 119.5K Reputation points MVP Volunteer Moderator
    2024-01-07T15:54:24.91+00:00

    I'd say that's by design. External users do not authenticate against your tenant, but against their "home" tenant. Thus any "revoke" action you perform will have no effect. If you want to prevent further access, you can block the user.


  2. Martin Kallukalam 440 Reputation points
    2024-01-07T18:59:37.1466667+00:00
    0 comments No comments

  3. Shweta Mathur 30,296 Reputation points Microsoft Employee Moderator
    2024-01-08T10:33:34.79+00:00

    Hi @Martin Kallukalam ,

    Thanks for reaching out.

    Vasil Michev answered to your query accurately. This behavior is expected by design.

    I can understand your concern regarding security and token thefts.

    Unfortunately, there is no way to invalidate a refresh token once it has been issued for guest users.

    As suggested you can block the user by disabling the account or block access using cross tenant access.

    Reference - Cross-tenant access overview - Azure AD - Microsoft Entra | Microsoft Docs

    When Cross Tenant Access Policy is set to block access for all apps by an admin for a particular Guest User, operation start failing intermittently almost immediately with error messages, and you can collaborate with guest user to update the credentials.

    As our team is working from security perspective in Microsoft Entra, you are welcome to leave your feedback in the feedback portal. https://feedback.azure.com/

    Hope this will help.

    Thanks,

    Shweta


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.