问题
I've been reading up on Android's cloud 2 device messaging (C2DM) and all the documentation mention ClientLogin as the authentication method. However the ClienLogin info page specifically states its not compatible with 2-step verification and recomments using OAuth2. Can I use OAuth2 as a replacement for ClientLogin for C2DM? I want to make the application experience as seamless as possible even for users who have 2-step verification enabled.
回答1:
The account that gets authenticated with C2DM is the pole account that you provided when you signed up for C2DM. As long as that account does not use 2-step verification, everything is fine. It does not use the user's credentials.
Rather, it does not use the user's credentials to push messages. The user must be signed in to Google services on their Android device, but they set that up on their own time. Once it is set up, everything looks the same to you as a developer.
来源:https://stackoverflow.com/questions/6222850/is-android-cloud-2-device-messaging-c2dm-compatible-with-googles-2-step-verif