I have a directory in a Snow Leopard box that looks something like:
MyDir/ file1 SubDir1/ file2 SubDir2/ file3
I created an encrypted archive of it (still in Snow Leopard):
tar -cvf - MyDir/ | openssl aes-256-cbc -out mydir.tar.enc
and I tried to extract it in a new Mountain Lion box:
openssl aes-256-cbc -d -in mydir.tar.eng | tar -xvf -
but the (modification) timestamps of SubDir1 and SubDir2 are not preserved (instead of the original timestamps, they now have the new timestamps of the extraction). (though, timestamps of file1, file2 and file3 are preserved)
Is there a way for me to keep timestamps from Snow Leopard to Mountain Lion?
Edit: I thought it may be due to different bsdtar versions: In Snow Leopard, bsdtar (the default tar) has version 2.6.2, whereas in Mountain Lion it is 2.8.3. So I tried to do the same with gnutar (which is 1.17 in both Snow Leopard and Mountain Lion), but that did not help.