X-Git-Url: http://www.git.cypherpunks.ru/?a=blobdiff_plain;f=src%2Fcypherpunks.ru%2Fgovpn%2Fverifier.go;fp=src%2Fcypherpunks.ru%2Fgovpn%2Fverifier.go;h=15955e77a2cf65e35ab18172d638a677170a3200;hb=4c8e5a136aba85dea639103c6618be46f7c41d49;hp=a452a50a84737231a2e0e3d28701dee10138bf23;hpb=4b6010d63d3512094c7cef4a119a8d45cb1a7b18;p=govpn.git diff --git a/src/cypherpunks.ru/govpn/verifier.go b/src/cypherpunks.ru/govpn/verifier.go index a452a50..15955e7 100644 --- a/src/cypherpunks.ru/govpn/verifier.go +++ b/src/cypherpunks.ru/govpn/verifier.go @@ -73,7 +73,7 @@ func (v *Verifier) PasswordApply(password string) *[ed25519.PrivateKeySize]byte // Parse either short or long verifier form. func VerifierFromString(input string) (*Verifier, error) { s := strings.Split(input, "$") - if !(len(s) != 4 || len(s) != 5) || s[1] != "argon2d" { + if len(s) < 4 || s[1] != "argon2d" { return nil, errors.New("Invalid verifier structure") } var m, t, p int