full encryption support for directory special remotes
This commit is contained in:
parent
9fe7e6be70
commit
4f9fafa023
3 changed files with 83 additions and 15 deletions
|
@ -9,6 +9,8 @@
|
|||
-}
|
||||
|
||||
module Crypto (
|
||||
Cipher,
|
||||
EncryptedCipher,
|
||||
genCipher,
|
||||
updateCipher,
|
||||
storeCipher,
|
||||
|
@ -133,7 +135,10 @@ gpgRead params = pOpen ReadFromPipe "gpg" (gpgParams params) hGetContentsStrict
|
|||
|
||||
gpgPipeStrict :: [CommandParam] -> String -> IO String
|
||||
gpgPipeStrict params input = do
|
||||
(_, output) <- pipeBoth "gpg" (gpgParams params) input
|
||||
(pid, fromh, toh) <- hPipeBoth "gpg" (gpgParams params)
|
||||
_ <- forkIO $ finally (hPutStr toh input) (hClose toh)
|
||||
output <- hGetContentsStrict fromh
|
||||
forceSuccess pid
|
||||
return output
|
||||
|
||||
gpgPipeBytes :: [CommandParam] -> L.ByteString -> IO (PipeHandle, L.ByteString)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue