在AppAuth-Android中注销 [英] Logout in AppAuth-Android

查看:98
本文介绍了在AppAuth-Android中注销的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个用JAVA开发的Android应用.对于此应用程序,我正在使用 IdentityServer4 作为我的STS,并且一切正常.但是我在 AppAuth库中找不到要注销的任何实现.谁可以帮我这个事?我确实在我的应用程序中需要注销选项,因此用户可以在需要时从该应用程序注销并再次登录.任何想法,样品将不胜感激.

I have an Android app developed in JAVA. For this app I am using the IdentityServer4 as my STS and everything is working fine. But i couldn't find any implementation to logout in AppAuth library. Can anyone help me on this? I really need the logout option in my app, so the users can logout from the app when ever they want and log back in again. Any ideas, samples would be greatly appreciated.

推荐答案

我是AppAuth的首席维护者.

I am the lead maintainer of AppAuth.

注销通常就像丢弃 AuthState 对象一样简单,以忘记获取的令牌.如果您指的是也在全球范围内使用OpenID身份对用户进行签名,则可以使用以下标准草案:

Logout is usually as simple as discarding the AuthState object, in order to forget the acquired tokens. If you are referring to also signing the user out of the OpenID identity globally, there is a draft standard for this:

http://openid.net/specs/openid-connect-frontchannel-1_0.html

AppAuth不支持此功能,因为我们不希望在核心库中包含正在进行的标准化工作.编写扩展库来实现此特定目的相对简单.

AppAuth does not support this, as we do not wish to include in-progress standardization work in the core library. It would be relatively simple to write an extension library to fulfill this particular purpose.

登出为空的IdentityServer4的文档为空,所以我不这样做他们不知道他们提供什么注销机制,以及是否遵循任何特定标准(草稿或其他).建议您与IdentityServer4的开发人员联系以获取更多信息.

The documentation for IdentityServer4 on logout is empty, so I don't know what mechanism they provide for logout and whether it follows any particular standard (draft or otherwise). I suggest you contact the developers of IdentityServer4 for more information.

这篇关于在AppAuth-Android中注销的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆