diff options
| author | redwrasse <mail@redwrasse.io> | 2025-05-12 17:20:25 +0000 |
|---|---|---|
| committer | Daniel McCarney <daniel@binaryparadox.net> | 2025-05-12 11:46:18 -0700 |
| commit | 9dbbcf002b5cbae3b65a93e406438711bef52e53 (patch) | |
| tree | f6582d8888719d64a87e6102232300637ce244ce | |
| parent | 9f6bf8449a9fc2528340bc04e46364f63b80e91d (diff) | |
| download | go-x-crypto-9dbbcf002b5cbae3b65a93e406438711bef52e53.tar.xz | |
bcrypt: update InvalidCostError message to describe cost range inclusive
Change InvalidCostError string to explicitly state cost bounds
range as inclusive, rather than using parentheses that might
imply an exclusive range.
Change-Id: Ie5e7d53ef4217c8560e6a7fe23e3d65ecc24a2a3
GitHub-Last-Rev: b49002b6b2cff0939858553a28e3f255bde397b6
GitHub-Pull-Request: golang/crypto#300
Reviewed-on: https://go-review.googlesource.com/c/crypto/+/609455
Reviewed-by: Daniel McCarney <daniel@binaryparadox.net>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: Michael Knyszek <mknyszek@google.com>
| -rw-r--r-- | bcrypt/bcrypt.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bcrypt/bcrypt.go b/bcrypt/bcrypt.go index dc93118..3e7f8df 100644 --- a/bcrypt/bcrypt.go +++ b/bcrypt/bcrypt.go @@ -50,7 +50,7 @@ func (ih InvalidHashPrefixError) Error() string { type InvalidCostError int func (ic InvalidCostError) Error() string { - return fmt.Sprintf("crypto/bcrypt: cost %d is outside allowed range (%d,%d)", int(ic), MinCost, MaxCost) + return fmt.Sprintf("crypto/bcrypt: cost %d is outside allowed inclusive range %d..%d", int(ic), MinCost, MaxCost) } const ( |
