lisp/gnus/nntp.el (nntp-send-authinfo): Error out if the password is wrong
This commit is contained in:
parent
0f238ea450
commit
d0b8d4bb32
2 changed files with 15 additions and 8 deletions
|
@ -1,3 +1,7 @@
|
|||
2015-01-15 Lars Magne Ingebrigtsen <larsi@gnus.org>
|
||||
|
||||
* nntp.el (nntp-send-authinfo): Error out if the password is wrong.
|
||||
|
||||
2015-01-08 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* registry.el: Don't use <class> as a variable.
|
||||
|
|
|
@ -1219,14 +1219,17 @@ If SEND-IF-FORCE, only send authinfo to the server if the
|
|||
nntp-authinfo-user user))
|
||||
(unless (member user '(nil ""))
|
||||
(nntp-send-command "^3.*\r?\n" "AUTHINFO USER" user)
|
||||
(when t ;???Should check if AUTHINFO succeeded
|
||||
(nntp-send-command
|
||||
"^2.*\r?\n" "AUTHINFO PASS"
|
||||
(or passwd
|
||||
nntp-authinfo-password
|
||||
(setq nntp-authinfo-password
|
||||
(read-passwd (format "NNTP (%s@%s) password: "
|
||||
user nntp-address))))))))))
|
||||
(let ((result
|
||||
(nntp-send-command
|
||||
"^2.*\r?\n" "AUTHINFO PASS"
|
||||
(or passwd
|
||||
nntp-authinfo-password
|
||||
(setq nntp-authinfo-password
|
||||
(read-passwd (format "NNTP (%s@%s) password: "
|
||||
user nntp-address)))))))
|
||||
(if (not result)
|
||||
(signal 'nntp-authinfo-rejected "Password rejected")
|
||||
result))))))
|
||||
|
||||
;;; Internal functions.
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue