aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Magne Ingebrigtsen2011-06-21 22:51:45 +0200
committerLars Magne Ingebrigtsen2011-06-21 22:51:45 +0200
commit6a6e4d9309bb0f94fbde68f3c3dd2ce275eaf107 (patch)
treeb64d6b2006f53ee994d0ee94e69731c1804b14ca
parent4ea31e074dc3505bcddc5be99a67cd3eab8cf389 (diff)
downloademacs-6a6e4d9309bb0f94fbde68f3c3dd2ce275eaf107.tar.gz
emacs-6a6e4d9309bb0f94fbde68f3c3dd2ce275eaf107.zip
Prefer the ~/.authinfo file over the ~/.authinfo.gpg file, especially when saving.
-rw-r--r--lisp/gnus/ChangeLog7
-rw-r--r--lisp/gnus/auth-source.el9
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 @@
12011-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
12011-06-18 Teodor Zlatanov <tzz@lifelogs.com> 82011-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
214The default will get login and password information from 214The 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