From 3eb3d0bbdf12eddd1bb5b966a95791a71c958ef0 Mon Sep 17 00:00:00 2001 From: Gani Georgiev Date: Mon, 13 Mar 2023 15:52:51 +0200 Subject: [PATCH] lowered auth record bcrypt round factor to 12 --- CHANGELOG.md | 10 ++++++---- models/record.go | 2 +- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 47a0fc95..f086d525 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,22 +1,24 @@ -<<<<<<< HEAD ## (WIP) v0.14.0 - Added _experimental_ Apple OAuth2 integration. -- Optimized single relation lookups (@todo doc). +- Optimized single relation lookups. - Normalized record values on `maxSelect` field option change (`select`, `file`, `relation`). When changing **from single to multiple** all already inserted single values are converted to an array. When changing **from multiple to single** only the last item of the already inserted array items is kept. +- Changed the cost/round factor of the auth records bcrypt hash generation from 13 to 12 since several users complained about the slow authWithPassword responses on lower spec hardware. + _The change will affect only new users. Depending on the demand, we may make it configurable from the auth options._ + - **!** Changed the request logs `method` value to UPPERCASE, eg. "get" => "GET" ([#1956](https://github.com/pocketbase/pocketbase/discussions/1956)). -======= + + ## v0.13.3 - Fixed view collections import ([#2044](https://github.com/pocketbase/pocketbase/issues/2044)). - Updated the records picker Admin UI to show properly view collection relations. ->>>>>>> master ## v0.13.2 diff --git a/models/record.go b/models/record.go index 276ba63f..b01852c5 100644 --- a/models/record.go +++ b/models/record.go @@ -864,7 +864,7 @@ func (m *Record) SetPassword(password string) error { } // hash the password - hashedPassword, err := bcrypt.GenerateFromPassword([]byte(password), 13) + hashedPassword, err := bcrypt.GenerateFromPassword([]byte(password), 12) if err != nil { return err }