diff options
Diffstat (limited to 'keysafe.hs')
-rw-r--r-- | keysafe.hs | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -94,7 +94,7 @@ backup cmdline storagelocations ui tunables secretkeysource secretkey = do kek <- promptkek name let sis = shareIdents tunables name secretkeysource let cost = getCreationCost kek <> getCreationCost sis - r <- withProgressIncremental ui "Encrypting and storing data" + (r, queued) <- withProgressIncremental ui "Encrypting and storing data" (encryptdesc cost cores) $ \addpercent -> do let esk = encrypt tunables kek secretkey shares <- genShares esk tunables @@ -103,7 +103,9 @@ backup cmdline storagelocations ui tunables secretkeysource secretkey = do let step = 50 `div` sum (map S.size shares) storeShares storagelocations sis shares (addpercent step) case r of - StoreSuccess -> showInfo ui "Success" "Your secret key was successfully encrypted and backed up." + StoreSuccess + | queued -> showInfo ui "Backup queued" "Some data was not sucessfully uploaded to servers, and has been queued for later upload. Run keysafe --uploadqueued at a later point to finish the backup." + | otherwise -> showInfo ui "Backup success" "Your secret key was successfully encrypted and backed up." StoreFailure s -> showError ui ("There was a problem storing your encrypted secret key: " ++ s) StoreAlreadyExists -> do showError ui $ unlines |