2

I am new to java also at Google Apps, I am using Eclipse.

I want to create a simple app that perform SSO in java with google.

i have done the demo app that will host over google app engine, it is working fine using google plugin how can i do it with my app running on my server.

thanks

1 Answer 1

3

Look at GAE: Configuring Your App's Authentication article. After configuring it you can check user using The Users Java API invoking:

UserService userService = UserServiceFactory.getUserService(); User user = userService.getCurrentUser(); 

This is the simplest way. There are many other. Like using OpenID described here: http://code.google.com/p/gwt-gae-book/wiki/Authentication

You can also create your own auth servlet filter wchich redirects users to userService.createLoginURL URL if needed.

Sign up to request clarification or add additional context in comments.

5 Comments

I have implemented it, app is running on my localhost:18359, but on deploying it over google market places, when i run it, instead of asking gmail credentials, it just give a fake login form and login me.
Did you configured your app as described here code.google.com/appengine/articles/auth.html ? You can also add you own filter and redirect user to userService.createLoginURL. AFAIK GAE production has no fake login form - It may be generated by your framework.
You are right, GAE has no fake login, as i said, I didn't deployed app over GAE, I have my app running on my server localhost:18359, I have just given this url in Application Manifest, <Extension id="navLink" type="link"> <Name>SSO custom app</Name> <Url>localhost:18359/</Url> </Extension> so I don't need to configure all stuff in code.google.com/appengine/articles/auth.html
I have check when I am running my app on my server in sign in url claimid=www.google.com/accounts/o8/id is missing, some body know how i add it with sign in url that is auto generated by userService.createLoginURL
GAE dev enviroment shows fake auth dialog and userService.createLoginURL creates url to this dialog. If you deploy the same app on production (and configure the prod env auth) you will get login dialog to google account. Sou you still want to implement SSO on dev server?

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.