Base solution for your next web application
Open Closed

Sign out User in application #5395


User avatar
0
joe704la created

In my Asp.net Core / Angular app I have a service that checks a few different things and if they meet a certain criteria I want to sign them out of the application as well as invalidate all access tokens. I saw in the SignInManager there is SignOutAsync. Does this sign them out entirely from the application as well as invalidate the tokens?

_signInManager.SignOutAsync();

Markdown is supported
Copy & paste or drag & drop images (max 30 MB per image)

5 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team

    Is your token JWT or IdentityServer?

    Markdown is supported
    Copy & paste or drag & drop images (max 30 MB per image)
  • User Avatar
    0
    joe704la created

    JWT

    Markdown is supported
    Copy & paste or drag & drop images (max 30 MB per image)
  • User Avatar
    0
    maliming created
    Support Team

    The JWT itself contains authentication information, and cannot be logged out unless it expires. Of course, you can set the blacklist to block the jwt token.

    Markdown is supported
    Copy & paste or drag & drop images (max 30 MB per image)
  • User Avatar
    0
    joe704la created

    Okay thank you. If I set the expiration date expired it should technically log them out correct?

    Markdown is supported
    Copy & paste or drag & drop images (max 30 MB per image)
  • User Avatar
    0
    maliming created
    Support Team

    yes!

    Markdown is supported
    Copy & paste or drag & drop images (max 30 MB per image)