On Mon, Apr 28, 2008 at 12:44:10AM +0300, Shachar Shemesh wrote:
>           o Using the later, I find it hard to believe that it
>           actually provides rsync friendliness. In particular,
>           does it provide rsync friendliness if the change (not at
>           the end of the file) caused a modification to the file
>           size?

OK, here's what I did:

dd if=/dev/zero of=test_long1 bs=1M count=16
dd if=/dev/urandom of=test_rand_1m bs=1M count=1
cat test_long1 test_rand_1m >test_long2             
cat test_rand_1m test_long1 >test_long3             
cat test_rand_1m test_long1 test_rand_1m >test_long4

Then I unmounted.

Then I figured out which was which by file size, more or less:

-rw-r--r-- 1 rlpowell users 16777216 2008-04-27 17:06 SfNM,dlfBajg2NiV0YzRJQz4
-rw-r--r-- 1 rlpowell users 17825792 2008-04-27 17:38 NZ92YbAoRtXWp29DypUz6g,n
-rw-r--r-- 1 rlpowell users 17825792 2008-04-27 17:38 3XnzDYA9ebc1ZNTuxQjsyVw8
-rw-r--r-- 1 rlpowell users 18874368 2008-04-27 17:38 X3bNiy35p439CRPql54uJ7I9

cp SfNM,dlfBajg2NiV0YzRJQz4 /tmp/target                           
rsync --stats --no-whole-file NZ92YbAoRtXWp29DypUz6g,n /tmp/target
[snip]
sent 1065173 bytes  received 24607 bytes  726520.00 bytes/sec
total size is 17825792  speedup is 16.36

cp SfNM,dlfBajg2NiV0YzRJQz4 /tmp/target                           
rsync --stats --no-whole-file 3XnzDYA9ebc1ZNTuxQjsyVw8 /tmp/target
[snip]
sent 2112853 bytes  received 24607 bytes  854984.00 bytes/sec
total size is 17825792  speedup is 8.34

cp SfNM,dlfBajg2NiV0YzRJQz4 /tmp/target                           
rsync --stats --no-whole-file X3bNiy35p439CRPql54uJ7I9 /tmp/target
[snip]
sent 3161557 bytes  received 24607 bytes  6372328.00 bytes/sec
total size is 18874368  speedup is 5.92

So yeah, it appears to work.  If you want me to test something else,
let me know.

It's worth noting that I prioritized rsyncability over security in
my setup; I used block encoding, and no IV at all.

>     * I have not looked at the actual implementation, only at the
>     presentation, but it seems to me that the "stream mode" offers
>     grave security issues if an attacker ever has access to the
>     same encrypted image before and after a modification that
>     changes the file length. This is unrelated to rsyncrypto. This
>     is, by the way, an issue with many file encrypting programs.

Stream mode only affects files names, AFAICT.

-Robin

-- 
Lojban Reason #17: http://en.wikipedia.org/wiki/Buffalo_buffalo
Proud Supporter of the Singularity Institute - http://singinst.org/
http://www.digitalkingdom.org/~rlpowell/ *** http://www.lojban.org/

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
Rsyncrypto-devel mailing list
Rsyncrypto-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rsyncrypto-devel

Reply via email to