Sign in to Gmail Inbox with Curl?
I am making a project where the user will first save their gmail id and password and after confirmation I will provide a link to directly login to gmail next time without entering his gmail id and password. the saved password will be passed as userid and passwd parameters using CURL
I am doing this with php .. I have heard of curl to do this. I tried a lot of code but didn't get any working code. Can anyone tell me ... how can I login to gmail inbox? .. using CURL in PHP ??
If you're just interested in reading emails in your Gmail inboxes, you should opt out of the cURL pseudo-browser; instead enable POP or IMAP in your Gmail account and use PHP's excellent IMAP / POP3 functions to access your Gmail inboxes.
If, on the other hand, you are trying to create some sort of SSO service, you are simply out of luck. Why is this? Well, even if your server manages to authenticate and store cookies from Gmail, you have no way to store those Gmail cookies in the client browser. Only requests sent from mail.google.com can set Gmail cookies. This is called the Same Origin Rule .
a source to share