I want to validate google apps user's username and password for custom login page(SSO Login) using SAML Protocol.
Options I tried:
1) Google ClientLogin library which is working till April 20, 2015 but after that it was deprecated.
2) Android play services authentication using this url: https://android.clients.google.com/auth. More detailed article
3) Connect using SMTP. Code snippet extracted from the post:
username = 'emailsmtplibtest@gmail.com'
password = 'passtest'
from_addr = 'emailsmtplibtest@gmail.com'
server = smtplib.SMTP('smtp.gmail.com', 587)
server.ehlo()
server.starttls()
server.login(username,password)
But its not promising as user can disable "Access for less secure apps" which will fail when we use SMTP.
Is there any other way or API to validate google apps user's username and password ?