0

암시 적 플로우가 작동하도록이 예제를 따라했습니다.Thinktecture 암시 적 플로우 : 사용자 서명/로그 아웃

http://weblogs.thinktecture.com/cweyer/2012/11/oauth2-in-thinktecture-identityserver-v2-implicit-grant-flow-with-javascript.html

내 질문은 내가 사용자를 signout 얼마나, 무엇입니까? 나는 어떤 예를 찾을 수 없었기 때문에 거기 밖으로 누군가가 있기를 바라고 있습니다. 지금은 권한 부여 창을 트리거하고 올바르게 처리하고 요청에 대한 액세스 토큰을 사용할 수 있지만 사용자 전환이 가능하도록 권한 부여 방법을 알지 못합니다.

답변

0

로그 아웃하려면 로그 아웃 방법으로 맞춤 컨트롤러를 만들어야합니다. https://github.com/brockallen/BrockAllen.MembershipReboot/blob/master/src/BrockAllen.MembershipReboot/Authentication/SamAuthenticationService.cs

: 여기
public void Logout() 
{ 
    // You should be able to revoke thinktecture token like this. (haven't tested this out) 
    var sam = FederatedAuthentication.SessionAuthenticationModule; 
    sam.SignOut(); 

    // Or you should be able to logoff like this when using a membership provider. (this way works for me) 
    //_yourMembership.Logout(); 
    Thread.CurrentPrincipal = null; 
    HttpContext.Current.User = null; 
} 

토큰 해지 샘플이고