close
The Wayback Machine - https://web.archive.org/web/20201207221822/https://github.com/dotnet-architecture/eShopOnContainers/issues/1376
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

logoutId is null #1376

Closed
dereklew opened this issue Jul 27, 2020 · 4 comments
Closed

logoutId is null #1376

dereklew opened this issue Jul 27, 2020 · 4 comments

Comments

@dereklew
Copy link

@dereklew dereklew commented Jul 27, 2020

Hi all,

I am getting null in logoutId in the following function while using the demo user ID, Any reason why?

    public async Task<IActionResult> Logout(string logoutId)
    {
        if (User.Identity.IsAuthenticated == false)
        {
            // if the user is not authenticated, then just show logged out page
            return await Logout(new LogoutViewModel { LogoutId = logoutId });
        }

        //Test for Xamarin. 
        var context = await _interaction.GetLogoutContextAsync(logoutId);
        if (context?.ShowSignoutPrompt == false)
        {
            //it's safe to automatically sign-out
            return await Logout(new LogoutViewModel { LogoutId = logoutId });
        }

        // show the logout prompt. this prevents attacks where the user
        // is automatically signed out by another malicious web page.
        var vm = new LogoutViewModel
        {
            LogoutId = logoutId
        };
        return View(vm);
    }
@sughosneo sughosneo added the xamarin label Jul 28, 2020
@dereklew
Copy link
Author

@dereklew dereklew commented Jul 28, 2020

This happens in both MVC and SPA.

@dereklew
Copy link
Author

@dereklew dereklew commented Jul 28, 2020

Resolved my own issue, Need to check the PostLogoutRedirectUri in ClientPostLogoutRedirectUris

@sughosneo sughosneo added docker-compose and removed xamarin labels Jul 31, 2020
@sughosneo
Copy link
Contributor

@sughosneo sughosneo commented Jul 31, 2020

Hi @dereklew, sorry for the delay in reaching out and glad to hear that it has been resolved. You may want to share the some further details for everyone's reference.

Thanks.

@sughosneo
Copy link
Contributor

@sughosneo sughosneo commented Aug 5, 2020

Hi @dereklew, as this original issue is resolved. I am marking this issue as closed.

@sughosneo sughosneo closed this Aug 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.