From 999ac808638a47c71232598d851fc73cf570857a Mon Sep 17 00:00:00 2001 From: Chad Birch Date: Mon, 31 Dec 2018 18:13:34 -0700 Subject: [PATCH] Add note about false positives on password check Since the check to see if a password has been present in a data breach is using a Bloom filter, there's a small chance of false positives (I believe it's 0.1% currently). This is confusing when it happens, so this just clarifies that it's possible but they'll have to pick a new password anyway. --- tildes/scss/modules/_sidebar.scss | 1 - tildes/tildes/schemas/user.py | 2 +- .../tildes/templates/includes/password_restrictions.jinja2 | 5 ++++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/tildes/scss/modules/_sidebar.scss b/tildes/scss/modules/_sidebar.scss index f572528..42bd747 100644 --- a/tildes/scss/modules/_sidebar.scss +++ b/tildes/scss/modules/_sidebar.scss @@ -4,7 +4,6 @@ #sidebar { p { margin-bottom: 0.4rem; - line-height: 1rem; } .btn { diff --git a/tildes/tildes/schemas/user.py b/tildes/tildes/schemas/user.py index 20e65f3..afd9733 100644 --- a/tildes/tildes/schemas/user.py +++ b/tildes/tildes/schemas/user.py @@ -90,7 +90,7 @@ class UserSchema(Schema): return if is_breached_password(value): - raise ValidationError("That password exists in a data breach") + raise ValidationError("That password exists in a data breach (see sidebar)") @pre_load def prepare_email_address(self, data: dict) -> dict: diff --git a/tildes/tildes/templates/includes/password_restrictions.jinja2 b/tildes/tildes/templates/includes/password_restrictions.jinja2 index 574a28d..dff53a8 100644 --- a/tildes/tildes/templates/includes/password_restrictions.jinja2 +++ b/tildes/tildes/templates/includes/password_restrictions.jinja2 @@ -6,6 +6,9 @@