|
@@ -479,7 +479,11 @@ func validatePassphrase(passphrase string) error {
|
479
|
479
|
if passphrase == "*" {
|
480
|
480
|
return errAccountBadPassphrase
|
481
|
481
|
}
|
482
|
|
- // for now, just enforce that spaces are not allowed
|
|
482
|
+ // validate that the passphrase contains no spaces, and furthermore is valid as a
|
|
483
|
+ // non-final IRC parameter. we already checked that it is nonempty:
|
|
484
|
+ if passphrase[0] == ':' {
|
|
485
|
+ return errAccountBadPassphrase
|
|
486
|
+ }
|
483
|
487
|
for _, r := range passphrase {
|
484
|
488
|
if unicode.IsSpace(r) {
|
485
|
489
|
return errAccountBadPassphrase
|