Search code examples
perlgoogle-authenticationcgi-application

Google authentication using perl cgi-application


I have built a CGI::Application currently running on local host and have used 2 authentication methods -
1. descried in http://www.perlmonks.org/?node_id=622071 by storing user password in database and
2. using LDAP credentials.

I was looking for a simple way to do google authentication but haven't found an easy way yet. Can someone point me in the right direction.

I looked at
1. Authen-GoogleAccount and
2. net-Google-FederatedLogin

but not enough documentation for either of these. Where do i start? Please let me know even if you have some pointer to doing this outside of cgi::application


Solution

  • This is the closest solution I could find. I am not a security expert, but I don't think websites serious about it would use this method. It uses WWW::Mechanize to authenticate using google email/password and then pull secure content out.

    http://gregjessup.com/login-to-google-using-perl/

    if $mech->get($url); returns error, authentication failed.