[英]Google+ login in android and then maintain offline session
Scope 范围
I want to have google login in my app. 我想在我的应用中使用google登录。 For this I referred to https://developers.google.com/+/mobile/android/sign-in and was able to create a basic login.
为此,我提到了https://developers.google.com/+/mobile/android/sign-in并能够创建基本登录名。
Problem 问题
Now, the problem is quite interesting. 现在,这个问题很有趣。 The login process works like a charm, but only when internet is connected.
登录过程就像一个超级按钮一样工作,但仅在连接互联网时才起作用。 Lets get to a specific use case:
让我们进入一个特定的用例:
So, I want to keep this login even if the internet is switched off, what can I do? 因此,即使互联网已关闭,我也要保留此登录名,该怎么办? A couple of other apps do this stuff.
其他几个应用程序也可以做到这一点。
Self Digging 自挖
Logs in Other apps: 登录其他应用程序:
02-16 00:51:13.493: W/GLSUser(26959): [GLSUser] [GLSUser] Permission for *packagename* to access oauth2:https://www.googleapis.com/auth/userinfo.email will be managed locally.
Logs in My apps: 登录我的应用程序:
02-16 00:50:16.203: W/GLSUser(26959): [GLSUser] [GLSUser] Permission for *packagename* to access oauth2:https://www.googleapis.com/auth/plus.me will be managed remotely.
I found that this weird thing happens only when I am using scope = 我发现只有在我使用scope =时才会发生这种奇怪的事情
Plus.SCOPE_PLUS_PROFILE
However, when I use scope = 'email' or 'profile' or Plus.SCOPE_PLUS_LOGIN. 但是,当我使用scope ='email'或'profile'或Plus.SCOPE_PLUS_LOGIN时。 It works fine in offline mode.
在离线模式下可以正常工作。
Can anybody help me ?? 有谁能够帮助我 ??
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.