From 13dd402c39440d8a6b9d0f9be76508e4d7e952cf Mon Sep 17 00:00:00 2001 From: oliv5 Date: Sun, 15 Jul 2018 23:59:42 +0000 Subject: [PATCH] Added a comment --- ..._756aeeee7be8cb67c5cc9dfa6ea7b82c._comment | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 doc/forum/Future_proofing___47___disaster_recovery_with_an_encrypted_special_remote/comment_9_756aeeee7be8cb67c5cc9dfa6ea7b82c._comment diff --git a/doc/forum/Future_proofing___47___disaster_recovery_with_an_encrypted_special_remote/comment_9_756aeeee7be8cb67c5cc9dfa6ea7b82c._comment b/doc/forum/Future_proofing___47___disaster_recovery_with_an_encrypted_special_remote/comment_9_756aeeee7be8cb67c5cc9dfa6ea7b82c._comment new file mode 100644 index 0000000000..b58d3ce94b --- /dev/null +++ b/doc/forum/Future_proofing___47___disaster_recovery_with_an_encrypted_special_remote/comment_9_756aeeee7be8cb67c5cc9dfa6ea7b82c._comment @@ -0,0 +1,25 @@ +[[!comment format=mdwn + username="oliv5" + avatar="http://cdn.libravatar.org/avatar/d7f0d33c51583bbd8578e4f1f9f8cf4b" + subject="comment 9" + date="2018-07-15T23:59:42Z" + content=""" +I'm trying to add support for the sharedpubkey encryption scheme, and while decrypting the files is straight-forward, I cannot get the \"lookup_key\" function to work with this scheme. I tried the following: + + # Pull out MAC cipher from beginning of cipher + if [ \"$encryption\" = \"hybrid\" ] ; then + cipher=\"$(echo -n \"$cipher\" | head -c 256 )\" + elif [ \"$encryption\" = \"shared\" ] ; then + cipher=\"$(echo -n \"$cipher\" | base64 -d | tr -d '\n' | head -c 256 )\" + elif [ \"$encryption\" = \"pubkey\" ] ; then + # pubkey cipher includes a trailing newline which was stripped in + # decrypt_cipher process substitution step above + IFS= read -rd '' cipher < <( printf \"$cipher\n\" ) + elif [ \"$encryption\" = \"sharedpubkey\" ] ; then + cipher=\"$(echo -n \"$cipher\" | base64 -d | tr -d '\n' | head -c 256)\" + fi + +as well as many other variations (full cipher, no base 64 etc...) without success. The cipher is said to be unencrypted, so I guess it is base-64 encoded only. Would it be possible that an extra character has been added to the cipher like in the \"pubkey\" encryption scheme ? + +My tests are done in a directory special remote, sharedpubkey encryption, no chunks, a single test file in the repository. +"""]]