From 1ebb337a82531ef15e867ff3012bce436ab05d10 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Tue, 27 Nov 2012 16:29:31 -0400 Subject: rsync: Fix bug introduced in last release that broke encrypted rsync special remotes. --- Remote/Rsync.hs | 2 +- debian/changelog | 2 ++ ..._t_transfer_files_to_rsync_remote_with_encryption__61__shared.mdwn | 4 ++++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/Remote/Rsync.hs b/Remote/Rsync.hs index c48a9c14a..a3ad21f73 100644 --- a/Remote/Rsync.hs +++ b/Remote/Rsync.hs @@ -110,7 +110,7 @@ store o k _f p = rsyncSend o p k <=< inRepo $ gitAnnexLocation k storeEncrypted :: RsyncOpts -> (Cipher, Key) -> Key -> MeterUpdate -> Annex Bool storeEncrypted o (cipher, enck) k p = withTmp enck $ \tmp -> do src <- inRepo $ gitAnnexLocation k - liftIO $ decrypt cipher (feedFile src) $ + liftIO $ encrypt cipher (feedFile src) $ readBytes $ L.writeFile tmp rsyncSend o p enck tmp diff --git a/debian/changelog b/debian/changelog index 6ddcbc39b..a9fdd1b07 100644 --- a/debian/changelog +++ b/debian/changelog @@ -2,6 +2,8 @@ git-annex (3.20121127) UNRELEASED; urgency=low * Fix dirContentsRecursive, which had missed some files in deeply nested subdirectories. Could affect various parts of git-annex. + * rsync: Fix bug introduced in last release that broke encrypted rsync + special remotes. -- Joey Hess Mon, 26 Nov 2012 16:45:19 -0400 diff --git a/doc/bugs/Can__39__t_transfer_files_to_rsync_remote_with_encryption__61__shared.mdwn b/doc/bugs/Can__39__t_transfer_files_to_rsync_remote_with_encryption__61__shared.mdwn index 1edefa901..31f37f6e5 100644 --- a/doc/bugs/Can__39__t_transfer_files_to_rsync_remote_with_encryption__61__shared.mdwn +++ b/doc/bugs/Can__39__t_transfer_files_to_rsync_remote_with_encryption__61__shared.mdwn @@ -48,3 +48,7 @@ Here's the output with `--debug`: I'm using git-annex 3.20121127. I think I was able to transfer files to that remote with the previous release. Any idea how to fix this? Am I doing something wrong? + +> Damn. This was a completely stupid bug, calling "decrypt" where it was +> supposed to call "encrypt". [[done]] in git; I'll have to +> make a new release to fix this. --[[Joey]] -- cgit v1.2.3