From 5a0beb1a7513692fe60480185ba42bf2db010c04 Mon Sep 17 00:00:00 2001 From: Nicholas Charriere Date: Sun, 6 May 2018 14:55:18 -0700 Subject: [PATCH] Quote url to fix equal sign breaking outlook clients --- snappass/main.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/snappass/main.py b/snappass/main.py index 15de24e..9a51308 100644 --- a/snappass/main.py +++ b/snappass/main.py @@ -1,6 +1,7 @@ import os import re import sys +import urllib import uuid import redis @@ -165,7 +166,7 @@ def handle_password(): base_url = request.url_root else: base_url = request.url_root.replace("http://", "https://") - link = base_url + token + link = base_url + urllib.quote(token) return render_template('confirm.html', password_link=link) @@ -173,6 +174,7 @@ def handle_password(): def show_password(password_key): if not request_is_valid(request): abort(404) + password_key = urllib.unquote(password_key) password = get_password(password_key) if not password: abort(404)