[web2py] logging in a user from encrypted password

2016-01-25 Thread Lou C
I have a user I have fetched from the db(), I want to return this user's JWT token, but to do so I must log them in first. Can I log in a user with auth.password property? valid_user = auth.login_bare(user.username, user.password) if valid_user: payload =

[web2py] Manually uploading a file from FieldStorage

2016-01-14 Thread Lou C
Hey, I am trying to manually upload a file from a request without using SQLFORMS, as this is is done through a REST client. This is is what I have so far: id = db.image.insert(file = db.image.file.store(request.vars.profile_pic.file,request.vars.profile_pic.filename)) This works, but fails

[web2py] Anyone know how to add a web2py URL in Google App Engine in app.yaml

2016-01-01 Thread Lou C
I want to add authorization to the following url, is this the right path for a web2py controller url ? - url: /applications/test/default/do_something/ script: none login: admin auth_fail_action: unauthorized -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) -

[web2py] Re: web2py 2.13.3 is OUT

2015-12-26 Thread Lou C
I am running version 2.13.4 on GAE which runs on python 2.7.5. The problem arises when using the @auth.allows_jwt() decorator. The error I get is AttributeError: 'module' object has no attribute 'compare_digest'. Which is being called in : def verify_signature(self, body, signature,