Non-interactive user authentication on GAE
I'm planning to start my first project using GAE (Google App Engine).
I would like to create a software that is web-service oriented and works with the google authentication mecanisms.
However, as I understand it, the code sample provided in the linked page redirects the user to a login page.
I would like 开发者_运维技巧to authenticate a user without any web-based user interaction.
- The user launches a local executable. Something like:
authenticate.exe mylogin mypassword
authenticate.exe
communicates the login and password to the GAE application using a web-service based communication.- The GAE application tries to authenticate the user and returns the result to
authenticate.exe
Is there any official documentation on how to achieve that reliably ? Preferably in Java.
Thank you.
Try using ClientLogin: http://code.google.com/apis/accounts/docs/AuthForInstalledApps.html
The docs are for Google APIs but should work also with AppEngine URLs.
Here is an example of using ClientLogin with AppEngine. Code is Python but you should understand the flow: http://dalelane.co.uk/blog/?p=303
精彩评论