diff options
| author | Lars Magne Ingebrigtsen | 2011-06-21 22:51:45 +0200 |
|---|---|---|
| committer | Lars Magne Ingebrigtsen | 2011-06-21 22:51:45 +0200 |
| commit | 6a6e4d9309bb0f94fbde68f3c3dd2ce275eaf107 (patch) | |
| tree | b64d6b2006f53ee994d0ee94e69731c1804b14ca | |
| parent | 4ea31e074dc3505bcddc5be99a67cd3eab8cf389 (diff) | |
| download | emacs-6a6e4d9309bb0f94fbde68f3c3dd2ce275eaf107.tar.gz emacs-6a6e4d9309bb0f94fbde68f3c3dd2ce275eaf107.zip | |
Prefer the ~/.authinfo file over the ~/.authinfo.gpg file, especially when saving.
| -rw-r--r-- | lisp/gnus/ChangeLog | 7 | ||||
| -rw-r--r-- | lisp/gnus/auth-source.el | 9 |
2 files changed, 12 insertions, 4 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 38c8a323eae..818440842cd 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog | |||
| @@ -1,3 +1,10 @@ | |||
| 1 | 2011-06-21 Lars Magne Ingebrigtsen <larsi@gnus.org> | ||
| 2 | |||
| 3 | * auth-source.el (auth-source-netrc-create): Don't print all tokens in | ||
| 4 | %S format, since that looks odd. | ||
| 5 | (auth-sources): Prefer the ~/.authinfo file over the ~/.authinfo.gpg | ||
| 6 | file, especially when saving. | ||
| 7 | |||
| 1 | 2011-06-18 Teodor Zlatanov <tzz@lifelogs.com> | 8 | 2011-06-18 Teodor Zlatanov <tzz@lifelogs.com> |
| 2 | 9 | ||
| 3 | * auth-source.el (auth-source-netrc-use-gpg-tokens): Replace | 10 | * auth-source.el (auth-source-netrc-use-gpg-tokens): Replace |
diff --git a/lisp/gnus/auth-source.el b/lisp/gnus/auth-source.el index e36bc9fbedd..d3261b137b2 100644 --- a/lisp/gnus/auth-source.el +++ b/lisp/gnus/auth-source.el | |||
| @@ -208,7 +208,7 @@ If the value is a function, debug messages are logged by calling | |||
| 208 | (function :tag "Function that takes arguments like `message'") | 208 | (function :tag "Function that takes arguments like `message'") |
| 209 | (const :tag "Don't log anything" nil))) | 209 | (const :tag "Don't log anything" nil))) |
| 210 | 210 | ||
| 211 | (defcustom auth-sources '("~/.authinfo.gpg" "~/.authinfo" "~/.netrc") | 211 | (defcustom auth-sources '("~/.authinfo" "~/.authinfo.gpg" "~/.netrc") |
| 212 | "List of authentication sources. | 212 | "List of authentication sources. |
| 213 | 213 | ||
| 214 | The default will get login and password information from | 214 | The default will get login and password information from |
| @@ -1281,7 +1281,7 @@ See `auth-source-search' for details on SPEC." | |||
| 1281 | (let ((printer (lambda () | 1281 | (let ((printer (lambda () |
| 1282 | ;; append the key (the symbol name of r) | 1282 | ;; append the key (the symbol name of r) |
| 1283 | ;; and the value in r | 1283 | ;; and the value in r |
| 1284 | (format "%s%s %S" | 1284 | (format "%s%s %s" |
| 1285 | ;; prepend a space | 1285 | ;; prepend a space |
| 1286 | (if (zerop (length add)) "" " ") | 1286 | (if (zerop (length add)) "" " ") |
| 1287 | ;; remap auth-source tokens to netrc | 1287 | ;; remap auth-source tokens to netrc |
| @@ -1291,8 +1291,9 @@ See `auth-source-search' for details on SPEC." | |||
| 1291 | (secret "password") | 1291 | (secret "password") |
| 1292 | (port "port") ; redundant but clearer | 1292 | (port "port") ; redundant but clearer |
| 1293 | (t (symbol-name r))) | 1293 | (t (symbol-name r))) |
| 1294 | ;; the value will be printed in %S format | 1294 | (if (string-match "[\" ]" data) |
| 1295 | data)))) | 1295 | (format "%S" data) |
| 1296 | data))))) | ||
| 1296 | (setq add (concat add (funcall printer))))))) | 1297 | (setq add (concat add (funcall printer))))))) |
| 1297 | 1298 | ||
| 1298 | (plist-put | 1299 | (plist-put |