diff options
author | Joey Hess <joeyh@joeyh.name> | 2016-08-11 20:44:07 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2016-08-11 20:44:07 -0400 |
commit | a3834e558cf6ae04826b44e65a02ee22286f7952 (patch) | |
tree | 571159729a9392579aa993e3f3da8dd58745c0b3 /keysafe.hs | |
parent | ab3594dacb0461ae5e253544f65c3e3d50eb721d (diff) | |
download | keysafe-a3834e558cf6ae04826b44e65a02ee22286f7952.tar.gz |
write via temp file
avoids short reads, and also if a backup program came along while the write
was happening, avoids short backups
Diffstat (limited to 'keysafe.hs')
-rw-r--r-- | keysafe.hs | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -45,6 +45,7 @@ retrievedemo = do let l = drop 1 $ zip [1..] (getIdents sis) shards <- map (\(RetrieveSuccess s) -> s) <$> mapM (uncurry (retrieveShard localFiles)) l + _ <- obscureShards localFiles let esk = combineShards tunables shards kek <- genKeyEncryptionKey tunables name password -- TODO: need to solve the encryption puzzle |