Error with OAuth2 Services authentication

0

I have successfully used the following code for an application that I have been using for 2 years but, in the last few weeks I have encountered the error "There was a problem communicating with Google servers" The code has not changed because I suspect that Google has made some change in the authorization form of the tokens. This error occurs on devices with Android 4.1, but the same code continues to work correctly with version 4.4. I have already tried to clear the cache of the app, and change the hosts file but it did not work

This is the code used:

am.getAuthToken(me, "oauth2:https://mail.google.com/", null, getActivity(), new MainActivity.OnTokenAcquired(), null);

The logcat shows the following message

07-22 11:10:49.858 778-790/com.google.android.gsf.login I/GLSUser: GLS error: ServiceDisabled
07-22 11:10:49.868 778-790/com.google.android.gsf.login V/GoogleLoginService: Returning error intent with: ComponentInfo{com.google.android.gsf.login/com.google.android.gsf.login.LoginActivity}
07-22 11:10:49.868 296-544/system_process I/ActivityManager: START {flg=0x10000000 cmp=com.google.android.gsf.login/.LoginActivity (has extras) u=0} from pid 427
07-22 11:10:49.908 296-543/system_process I/WindowManager: roated = false,realdw = 800,realdh = 480
07-22 11:10:49.948 296-469/system_process I/ActivityManager: START {cmp=com.google.android.gsf.login/.ShowErrorActivity (has extras) u=0} from pid 778
07-22 11:10:49.958 296-307/system_process I/WindowManager: roated = false,realdw = 800,realdh = 480
07-22 11:10:50.018 778-778/com.google.android.gsf.login W/GLSActivity: GAIA ERROR WITH NO RESOURCE STRING ServiceDisabled
07-22 11:10:50.118 778-780/com.google.android.gsf.login D/dalvikvm: GC_CONCURRENT freed 421K, 25% free 4108K/5443K, paused 12ms+29ms, total 81ms
07-22 11:10:50.168 296-323/system_process I/ActivityManager: Displayed com.google.android.gsf.login/.ShowErrorActivity: +207ms (total +255ms)

android
oauth-2.0
token
asked on Stack Overflow Jul 22, 2019 by lzn202 • edited Jul 22, 2019 by lzn202

0 Answers

Nobody has answered this question yet.


User contributions licensed under CC BY-SA 3.0