use new signer and strip trailing base64 padding

This commit is contained in:
Martin Zimmermann 2014-07-25 13:45:26 +02:00
parent 090c01bf8a
commit ea5aa0e80f
2 changed files with 2 additions and 4 deletions

View File

@ -48,8 +48,6 @@ from os.path import dirname, join
from argparse import ArgumentParser
from functools import partial, reduce
from itsdangerous import URLSafeTimedSerializer
from werkzeug.routing import Map, Rule, redirect
from werkzeug.exceptions import HTTPException, InternalServerError
@ -69,7 +67,7 @@ except ImportError:
from isso import cache, config, db, migrate, ext, queue, spam, views, wsgi
from isso.wsgi import origin, urlsplit
from isso.utils import http, JSONRequest, html, hash
from isso.utils import http, JSONRequest, html, hash, URLSafeTimedSerializer
from isso.ext.notifications import Stdout, SMTP

View File

@ -123,4 +123,4 @@ class URLSafeTimedSerializer(TimedSerializer):
def dump_payload(self, obj):
json = super(TimedSerializer, self).dump_payload(obj)
return base64.b64encode(json)
return base64.b64encode(json).rstrip(b"=")