Migrat pkg/password to using pkglib package

This commit is contained in:
Tom Wiesing 2023-02-26 10:24:06 +01:00
parent 010fd536ea
commit aa3580c248
No known key found for this signature in database
11 changed files with 56 additions and 158 deletions

View file

@ -6,8 +6,9 @@ import (
"fmt"
"io"
"github.com/FAU-CDI/wisski-distillery/internal/passwordx"
"github.com/FAU-CDI/wisski-distillery/internal/phpx"
"github.com/FAU-CDI/wisski-distillery/pkg/password"
"github.com/tkw1536/pkglib/password"
)
var errGetValidator = errors.New("GetPasswordValidator: Unknown Error")
@ -64,7 +65,7 @@ func (pv PasswordValidator) CheckDictionary(ctx context.Context, writer io.Write
}
return errPasswordUsername
}
for candidate := range password.CommonPasswords() {
for candidate := range password.Passwords(passwordx.Sources...) {
if ctx.Err() != nil {
continue
}