问题描述
|
我一直想知道是否有可能在Google AppEngine(GAE)中进行构建和应用,并不仅通过Google帐户向用户提供登录。我还想提供自己的身份验证。类似于http://www.appdemostore.com/signin。此应用程序基于GAE构建,不仅提供Google帐户方法来验证其用户身份。它具有表单身份验证和用于创建由其自己托管的帐户的表单。所以,我的意思是:我如何实现类似的东西。是否可以通过我自己的表单和用户帐户(而不是仅Google帐户)进行身份验证?
解决方法
是的,您还应该管理会话,并自行将用户实体存储在datestore上。
如果您使用的是python。您应该看看gaesessions。您的模型看起来像
class Profile(db.Model):
name=db.TextProperty()
email=db.EmailProperty()
contact=db.StringProperty()
address = db.StringProperty()
image=db.BlobProperty()
passcode=db.StringProperty()#hash value