summaryrefslogtreecommitdiff
path: root/internal/authentication/file_user_provider_database.go
diff options
context:
space:
mode:
authorJames Elliott <james-d-elliott@users.noreply.github.com>2022-12-05 09:37:08 +1100
committerGitHub <noreply@github.com>2022-12-05 09:37:08 +1100
commit0aa674505928f1d1d28f70db777710f5c7a4713a (patch)
tree1d1fdacba24dca1368e57c0cab405c8209dd11e3 /internal/authentication/file_user_provider_database.go
parent87004ccb570eb76b5656bd9cbd617932ab1b0312 (diff)
build(deps): update module github.com/go-crypt/crypt to v0.2.2 (#4452)
Diffstat (limited to 'internal/authentication/file_user_provider_database.go')
-rw-r--r--internal/authentication/file_user_provider_database.go5
1 files changed, 3 insertions, 2 deletions
diff --git a/internal/authentication/file_user_provider_database.go b/internal/authentication/file_user_provider_database.go
index 4d710e34b..509f025e0 100644
--- a/internal/authentication/file_user_provider_database.go
+++ b/internal/authentication/file_user_provider_database.go
@@ -8,6 +8,7 @@ import (
"github.com/asaskevich/govalidator"
"github.com/go-crypt/crypt"
+ "github.com/go-crypt/crypt/algorithm"
"gopkg.in/yaml.v3"
)
@@ -203,7 +204,7 @@ func (m *FileUserDatabase) ToDatabaseModel() (model *DatabaseModel) {
// DatabaseUserDetails is the model of user details in the file database.
type DatabaseUserDetails struct {
Username string
- Digest crypt.Digest
+ Digest algorithm.Digest
Disabled bool
DisplayName string
Email string
@@ -308,7 +309,7 @@ type UserDetailsModel struct {
// ToDatabaseUserDetailsModel converts a UserDetailsModel into a *DatabaseUserDetails.
func (m UserDetailsModel) ToDatabaseUserDetailsModel(username string) (model *DatabaseUserDetails, err error) {
- var d crypt.Digest
+ var d algorithm.Digest
if d, err = crypt.Decode(m.HashedPassword); err != nil {
return nil, err