3
0
mirror of https://github.com/ergochat/ergo.git synced 2024-11-26 05:49:25 +01:00

Merge pull request #804 from slingamn/issue775_again

raise passphrase length limit to 300 bytes
This commit is contained in:
Shivaram Lingamneni 2020-02-22 21:15:13 -08:00 committed by GitHub
commit cb356ecaf0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -441,7 +441,7 @@ func (am *AccountManager) Register(client *Client, account string, callbackNames
// validatePassphrase checks whether a passphrase is allowed by our rules
func validatePassphrase(passphrase string) error {
// sanity check the length
if len(passphrase) == 0 || len(passphrase) > 256 {
if len(passphrase) == 0 || len(passphrase) > 300 {
return errAccountBadPassphrase
}
// we use * as a placeholder in some places, if it's gotten this far then fail