Encrypted cookie support for Tornado Web Server
License
This software is under the MIT License
Requirements
PyCrypto
Tornado
Please file a bug for version issues. Tested on Python 3.2.
Encryption
Encryption is done using AES256 with a 32 byte block.
Example
Handler
from tornadoencookie.encookie import EncookieMixin
class MyHandler(tornado.web.RequestHandler, EncookieMixin):
def get(self):
#Get a cookie
self.encookie.get_cookie('hello')
#Get a secure cookie
self.encookie.get_secure_cookie('hello')
#Set a regular cookie
self.encookie.set_cookie('hi', 'there')
#Set a secure cookie
self.encookie.set_secure_cookie('hello', 'Timmy')
Configuration
application = tornado.web.Application([
(r'/', MyHandler),
], **{
'encookie_secret': 'iamthecookiemons',
},
)
Metadata
Release files for tornado-encookie 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| tornado-encookie-0.0.1.tar.gz | 2.9 kB | Without provenance | Details |
Security for tornado-encookie 0.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.