diff options
author | Jakob Unterwurzacher | 2015-10-11 18:33:28 +0200 |
---|---|---|
committer | Jakob Unterwurzacher | 2015-10-11 18:33:28 +0200 |
commit | d1d444435cf4351fc50ffd02c203cf4a2209b8e5 (patch) | |
tree | 773ca8a914f9a5cc4165060da22c7810eda51ca8 /cryptfs | |
parent | a863a6569c294cb06916cbf303a1230a04e73f76 (diff) |
main: check directories for existence early
This prevents that the user enters the password only to get an error
later.
Diffstat (limited to 'cryptfs')
-rw-r--r-- | cryptfs/config_file.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cryptfs/config_file.go b/cryptfs/config_file.go index 9be80ca..ef426ff 100644 --- a/cryptfs/config_file.go +++ b/cryptfs/config_file.go @@ -67,7 +67,8 @@ func LoadConfFile(filename string, password string) ([]byte, *ConfFile, error) { cfs := NewCryptFS(scryptHash, false) key, err := cfs.DecryptBlock(cf.EncryptedKey, 0) if err != nil { - Warn.Printf("Failed to unlock master key: %s\n", err.Error()) + Warn.Printf("failed to unlock master key: %s\n", err.Error()) + Warn.Printf("Password incorrect.\n") return nil, nil, err } |