The logout functionality you’ve mentioned here is the default behavior of a module. It’s logging you out of Drupal but not from Azure AD B2C.
To allow the module to logout from Azure B2C’s account (what you are looking for), you need to make the below configurations:
- Follow the below steps:
- Go to the Client Settings tab.
- Scroll down to the Logout Settings section.
- Check the box Enable Single Logout.
- In the IdP Session Logout Endpoint URL, enter: https://{tenant}.b2clogin.com/{tenant}.onmicrosoft.com/{policy-name}/oauth2/v2.0/logout
- In the Redirect URI Param Name of Identity Provider field, enter the parameter name expected by Azure AD B2C (by default it is
post_logout_redirect_uri
)
- In the Azure AD portal, navigate to the application you created. From the left-hand menu, click on Authentication. In the Front-channel logout URL field, enter the base URL of your Drupal site.