diff options
author | 2022-05-09 01:31:46 -0700 | |
---|---|---|
committer | 2022-05-09 10:31:46 +0200 | |
commit | b24b71c0a4ca9c86e1d5db12e9472c6ab1ecd5f5 (patch) | |
tree | 03f35f6f3fe2b2fa4cd26dae9fd820d355e16668 /internal/api/client/user/passwordchange_test.go | |
parent | [bugfix] Fix remote media pruning failing if media already gone (#548) (diff) | |
download | gotosocial-b24b71c0a4ca9c86e1d5db12e9472c6ab1ecd5f5.tar.xz |
[feature] Include password strength in error message when password strength is too low (#550)
* When password validation fails, return how close to enough entropy it has.
* Shorter version of low-strength password error message
Diffstat (limited to 'internal/api/client/user/passwordchange_test.go')
-rw-r--r-- | internal/api/client/user/passwordchange_test.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/internal/api/client/user/passwordchange_test.go b/internal/api/client/user/passwordchange_test.go index 0cb44bbe9..23a234116 100644 --- a/internal/api/client/user/passwordchange_test.go +++ b/internal/api/client/user/passwordchange_test.go @@ -153,7 +153,7 @@ func (suite *PasswordChangeTestSuite) TestPasswordWeakNewPassword() { defer result.Body.Close() b, err := ioutil.ReadAll(result.Body) suite.NoError(err) - suite.Equal(`{"error":"bad request: insecure password, try including more special characters, using uppercase letters, using numbers or using a longer password"}`, string(b)) + suite.Equal(`{"error":"bad request: password is 94% strength, try including more special characters, using uppercase letters, using numbers or using a longer password"}`, string(b)) } func TestPasswordChangeTestSuite(t *testing.T) { |