add more info in "alias expire" error
This commit is contained in:
parent
e9d03d1d4b
commit
d9e9a54082
|
@ -124,7 +124,7 @@ def new_custom_alias_v2():
|
||||||
try:
|
try:
|
||||||
alias_suffix = signer.unsign(signed_suffix, max_age=300).decode()
|
alias_suffix = signer.unsign(signed_suffix, max_age=300).decode()
|
||||||
except SignatureExpired:
|
except SignatureExpired:
|
||||||
LOG.error("Alias creation time expired")
|
LOG.error("Alias creation time expired for %s", user)
|
||||||
return jsonify(error="alias creation is expired, please try again"), 400
|
return jsonify(error="alias creation is expired, please try again"), 400
|
||||||
except Exception:
|
except Exception:
|
||||||
LOG.error("Alias suffix is tampered, user %s", user)
|
LOG.error("Alias suffix is tampered, user %s", user)
|
||||||
|
|
|
@ -73,7 +73,7 @@ def custom_alias():
|
||||||
try:
|
try:
|
||||||
alias_suffix = signer.unsign(signed_suffix, max_age=300).decode()
|
alias_suffix = signer.unsign(signed_suffix, max_age=300).decode()
|
||||||
except SignatureExpired:
|
except SignatureExpired:
|
||||||
LOG.error("Alias creation time expired")
|
LOG.error("Alias creation time expired for %s", current_user)
|
||||||
flash("Alias creation time is expired, please retry", "warning")
|
flash("Alias creation time is expired, please retry", "warning")
|
||||||
return redirect(url_for("dashboard.custom_alias"))
|
return redirect(url_for("dashboard.custom_alias"))
|
||||||
except Exception:
|
except Exception:
|
||||||
|
|
|
@ -156,7 +156,7 @@ def authorize():
|
||||||
try:
|
try:
|
||||||
alias_suffix = signer.unsign(signed_suffix, max_age=300).decode()
|
alias_suffix = signer.unsign(signed_suffix, max_age=300).decode()
|
||||||
except SignatureExpired:
|
except SignatureExpired:
|
||||||
LOG.error("Alias creation time expired")
|
LOG.error("Alias creation time expired for %s", current_user)
|
||||||
flash("Alias creation time is expired, please retry", "warning")
|
flash("Alias creation time is expired, please retry", "warning")
|
||||||
return redirect(request.url)
|
return redirect(request.url)
|
||||||
except Exception:
|
except Exception:
|
||||||
|
|
Loading…
Reference in a new issue