summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichael Klishin <mklishin@pivotal.io>2017-01-03 15:08:45 +0800
committerMichael Klishin <mklishin@pivotal.io>2017-01-03 15:08:45 +0800
commitccebf4a0043d2c346f33cb95ece1995a10e8735c (patch)
treeb4b198a65feefe6ace05941b97880471e4515883 /src
parent634a53f44a4795baa68a0b654e71210e5589b524 (diff)
downloadrabbitmq-server-git-ccebf4a0043d2c346f33cb95ece1995a10e8735c.tar.gz
Property-based tests for regexp credential validator
Diffstat (limited to 'src')
-rw-r--r--src/rabbit_credential_validator_regexp.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/rabbit_credential_validator_regexp.erl b/src/rabbit_credential_validator_regexp.erl
index 187e679416..a8d4f36d1b 100644
--- a/src/rabbit_credential_validator_regexp.erl
+++ b/src/rabbit_credential_validator_regexp.erl
@@ -42,7 +42,7 @@ validate_password(Password) ->
-spec validate_password(rabbit_types:password(), string()) -> 'ok' | {'error', string(), [any()]}.
validate_password(Password, Pattern) ->
- case re:run(Password, Pattern) of
+ case re:run(rabbit_data_coercion:to_list(Password), Pattern) of
{match, _} -> ok;
nomatch -> {error, "provided password does not match the validator regular expression"}
end.