Tag Archives: web

Instant Noodle aka Instant Google!

As most of us have come to peace with the latest ripple(sorry wave ain’t news anymore) on the world wide web caused by no other than google, it is time to analyse the new offering!

What is it?
An approach that takes away the mice and directly displays search results as alphabets are typed.

Any similar things exists before?
Absolutely Yes. Any regular KDE user knows what happens when Alt-F2 is pressed.

Is it any worth?
Yup! It was fun using it for two days. But don’t know how long it lasts.The good thing is that the mice has been pushed away one step more.

Any Gotcha’s?
As with any ajax application, browser button behaviour is unpredictable.You might not see actually things on the screen, but your request has everything.
Also earlier, for a search text only a single hit was required to the google servers, now every alphabet invokes a new hit.Get ready to leak unnecessary bandwith data.
Google really has some strong servers to take the toll of every search query to around 5-7 times!

The official post is here.

Decoding the SSO

I found this a year ago but i am sharing it now!
When i was developing multiple RoR apps about a year ago, there was one basic requirement, that of a SSO solution.

Err…. i hope you guys know what SSO is?
Well for those of you who are clueless, SSO stands for Single Sign-On.

Yes, SSO is one of the most important requirements of modern web apps. SSO enables a user to use multiple apps with a single username/password and the user needs to authenticate only once to use all the connected apps.

Take the example of Google! Have you ever wondered how you can directly access (without requiring to re-enter your credentials) your orkut/picassa account, when a moment back you were using gmail. Yes Google uses SSO!

Now for the decoding part, this is how Google does it:

Have you ever observed closely, what happens whenever you try to access any of the Google services for the first time?
The first request is always redirect to google’s main domain (i.e google.com) along with a set of parameters:
1. service -> which tells the service being requested
2. continue -> which tells the web location where the request should be forwarded after it is authenticated on the main domain

There are a few more parameters, but the above two are the most important.

Once you authenticate yourself on any google service, a cookie is created on the main domain. This cookie is checked whenever you try to access some other google service for the first time.
Once your identification is established on the main domain, another cookie with similar info is set on the service/webapp you are accessing (e.g. mail.google.com / orkut.com / blogger.com)
So, the subsequent requests to the same webapp, need not be redirected to the main domain for authentication!

The reverse happens, when you logout of a google service. The cookie on the current app is removed and then the request is forwarded to main domain to remove the cookie over there as well.
This makes sure that you logout of all the google services at one go!

For more info, on how you can implement SSO in your webapps, refer to these links:

http://www.jasig.org/cas
http://code.google.com/p/rubycas-server/
http://code.google.com/p/rubycas-client/