0
0
Fork 1
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-08-22 13:18:29 +00:00

Increase security by limiting what file variables can do for evaluation query.

* lisp/org.el (org-confirm-shell-link-function):
(org-confirm-elisp-link-function): Limit the values that can be set by
file variables.
This commit is contained in:
Carsten Dominik 2010-06-30 15:29:55 +02:00
parent 025a96d46f
commit a0962e02fd

View file

@ -1488,6 +1488,9 @@ single keystroke rather than having to type \"yes\"."
(const :tag "with yes-or-no (safer)" yes-or-no-p)
(const :tag "with y-or-n (faster)" y-or-n-p)
(const :tag "no confirmation (dangerous)" nil)))
(put 'org-confirm-shell-link-function
'safe-local-variable
'(lambda (x) (member x '(yes-or-no-p y-or-n-p))))
(defcustom org-confirm-elisp-link-function 'yes-or-no-p
"Non-nil means ask for confirmation before executing Emacs Lisp links.
@ -1505,6 +1508,9 @@ single keystroke rather than having to type \"yes\"."
(const :tag "with yes-or-no (safer)" yes-or-no-p)
(const :tag "with y-or-n (faster)" y-or-n-p)
(const :tag "no confirmation (dangerous)" nil)))
(put 'org-confirm-shell-link-function
'safe-local-variable
'(lambda (x) (member x '(yes-or-no-p y-or-n-p))))
(defconst org-file-apps-defaults-gnu
'((remote . emacs)