mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2025-02-08 21:38:10 +00:00
org-mobile: Specify message digest for OpenSSL commands
* lisp/org-mobile.el (org-mobile-encrypt-file): (org-mobile-decrypt-file): Fix the message digest as MD5 for compatibility across OpenSSL versions. OpenSSL switched to using SHA256 by default for symmetric encryption in version 1.1. Unfortunately that means that newer versions of the openssl command line tool can not decrypt encrypted org-mobile files without the '-md md5' option. This commit changes the shell commands in org-mobile-encrypt-file and org-mobile-decrypt-file to explicitly specify MD5 as the hash digest. TINYCHANGE
This commit is contained in:
parent
d9713fe3ca
commit
f203d378bd
@ -693,7 +693,7 @@ encryption program does not understand them."
|
|||||||
(defun org-mobile-encrypt-file (infile outfile)
|
(defun org-mobile-encrypt-file (infile outfile)
|
||||||
"Encrypt INFILE to OUTFILE, using `org-mobile-encryption-password'."
|
"Encrypt INFILE to OUTFILE, using `org-mobile-encryption-password'."
|
||||||
(shell-command
|
(shell-command
|
||||||
(format "openssl enc -aes-256-cbc -salt -pass %s -in %s -out %s"
|
(format "openssl enc -md md5 -aes-256-cbc -salt -pass %s -in %s -out %s"
|
||||||
(shell-quote-argument (concat "pass:"
|
(shell-quote-argument (concat "pass:"
|
||||||
(org-mobile-encryption-password)))
|
(org-mobile-encryption-password)))
|
||||||
(shell-quote-argument (expand-file-name infile))
|
(shell-quote-argument (expand-file-name infile))
|
||||||
@ -702,7 +702,7 @@ encryption program does not understand them."
|
|||||||
(defun org-mobile-decrypt-file (infile outfile)
|
(defun org-mobile-decrypt-file (infile outfile)
|
||||||
"Decrypt INFILE to OUTFILE, using `org-mobile-encryption-password'."
|
"Decrypt INFILE to OUTFILE, using `org-mobile-encryption-password'."
|
||||||
(shell-command
|
(shell-command
|
||||||
(format "openssl enc -d -aes-256-cbc -salt -pass %s -in %s -out %s"
|
(format "openssl enc -md md5 -d -aes-256-cbc -salt -pass %s -in %s -out %s"
|
||||||
(shell-quote-argument (concat "pass:"
|
(shell-quote-argument (concat "pass:"
|
||||||
(org-mobile-encryption-password)))
|
(org-mobile-encryption-password)))
|
||||||
(shell-quote-argument (expand-file-name infile))
|
(shell-quote-argument (expand-file-name infile))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user