I can solve it like this:
1) When a user clicks on Google, Facebook, Twitter, etc., I open the link ( http://www.mywebsite.com/login/google ) in InAppBrowser (native PhoneGap function, the plugin is not required) if Google clicked
2) When the link is open, my server redirects to Google.com, and the user sees the Google login page.
3) The user authenticates using Google and Google, redirects the token to my server.
4) Now my server uses this token to create some accounts, logs, perform some operations and then redirect to the URL with the information required by my phone application.
eg. - It recycles http://mywebsite.com/login/google/successful?token= <> & query-string-parameters
5) InAppBrowser listens for URL changes, and when it finds the URL with the above pattern, it takes over, parses the URL, parses the information sent with the URL, and then closes InAppBrowser.
Anup
source share