aboutsummaryrefslogtreecommitdiffstats
path: root/lisp/net
diff options
context:
space:
mode:
authorMiles Bader2005-12-17 21:41:34 +0000
committerMiles Bader2005-12-17 21:41:34 +0000
commit3031d8b0bb97f21c79b3022ff3e7564173facd18 (patch)
tree8326caa5ddefa2a97951766f00441456f134f230 /lisp/net
parentabeb585559cb58e735127e487b9614bb680339e2 (diff)
downloademacs-3031d8b0bb97f21c79b3022ff3e7564173facd18.tar.gz
emacs-3031d8b0bb97f21c79b3022ff3e7564173facd18.zip
Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-676
Merge from gnus--rel--5.10 Patches applied: * gnus--rel--5.10 (patch 169-173) - Merge from emacs--cvs-trunk--0 - Update from CVS 2005-12-16 Katsumi Yamaoka <yamaoka@jpl.org> * lisp/gnus/gnus-art.el (gnus-signature-separator): Fix custom type. * lisp/gnus/mm-decode.el (mm-inlined-types): Fix custom type. (mm-keep-viewer-alive-types): Ditto. (mm-automatic-display): Ditto. (mm-attachment-override-types): Ditto. (mm-inline-override-types): Ditto. (mm-automatic-external-display): Ditto. 2005-12-12 Katsumi Yamaoka <yamaoka@jpl.org> * lisp/gnus/gnus-art.el (gnus-buttonized-mime-types): Mention addition of multipart/alternative and add xref to mm-discouraged-alternatives in doc string. * lisp/gnus/mm-decode.el (mm-discouraged-alternatives): Add xref to gnus-buttonized-mime-types in doc string. 2005-12-12 Katsumi Yamaoka <yamaoka@jpl.org> * lisp/gnus/rfc2047.el (rfc2047-charset-to-coding-system): Recognize us-ascii as a MIME charset. * lisp/gnus/mm-bodies.el (mm-decode-content-transfer-encoding): Protect against the case where the 2nd arg TYPE is nil. 2005-12-09 Reiner Steib <Reiner.Steib@gmx.de> * lisp/gnus/gnus-start.el (gnus-no-server-1): Mention `gnus-level-default-subscribed' in doc string. 2005-11-26 Dave Love <fx@gnu.org> * lisp/gnus/tls.el (open-tls-stream): Rename arg SERVICE to PORT. (tls-program, tls-success): Provide openssl alternative. * lisp/gnus/starttls.el: Doc fixes. (starttls-open-stream-gnutls, starttls-open-stream): Rename arg SERVICE to PORT. 2005-12-09 Reiner Steib <Reiner.Steib@gmx.de> * lisp/gnus/gnus-start.el (gnus-start-draft-setup): Enforce `gnus-draft-mode' for nndraft:drafts at startup. * lisp/gnus/gnus.el (gnus-splash): Change custom group. (gnus-group-get-parameter, gnus-group-parameter-value): Describe allow-list argument. * lisp/gnus/gnus-agent.el (gnus-agent-article-alist-save-format): Format doc string. 2005-12-09 ARISAWA Akihiro <ari@mbf.ocn.ne.jp> (tiny change) * lisp/gnus/mm-decode.el (mm-display-external): Add lacked cdr. 2005-12-12 Katsumi Yamaoka <yamaoka@jpl.org> * man/gnus.texi (MIME Commands): Mention addition of multipart/alternative to gnus-buttonized-mime-types and add xref to mm-discouraged-alternatives. * man/emacs-mime.texi (Display Customization): Mention addition of "image/.*" and add xref to gnus-buttonized-mime-types in the mm-discouraged-alternatives section.
Diffstat (limited to 'lisp/net')
-rw-r--r--lisp/net/tls.el24
1 files changed, 13 insertions, 11 deletions
diff --git a/lisp/net/tls.el b/lisp/net/tls.el
index ceebe4b33d5..e46c98b6f6a 100644
--- a/lisp/net/tls.el
+++ b/lisp/net/tls.el
@@ -56,7 +56,8 @@
56 :group 'comm) 56 :group 'comm)
57 57
58(defcustom tls-program '("gnutls-cli -p %p %h" 58(defcustom tls-program '("gnutls-cli -p %p %h"
59 "gnutls-cli -p %p %h --protocols ssl3") 59 "gnutls-cli -p %p %h --protocols ssl3"
60 "openssl s_client -connect %h:%p -no_ssl2")
60 "List of strings containing commands to start TLS stream to a host. 61 "List of strings containing commands to start TLS stream to a host.
61Each entry in the list is tried until a connection is successful. 62Each entry in the list is tried until a connection is successful.
62%s is replaced with server hostname, %p with port to connect to. 63%s is replaced with server hostname, %p with port to connect to.
@@ -64,6 +65,7 @@ The program should read input on stdin and write output to
64stdout. Also see `tls-success' for what the program should output 65stdout. Also see `tls-success' for what the program should output
65after successful negotiation." 66after successful negotiation."
66 :type '(repeat string) 67 :type '(repeat string)
68 :version "22.1"
67 :group 'tls) 69 :group 'tls)
68 70
69(defcustom tls-process-connection-type nil 71(defcustom tls-process-connection-type nil
@@ -72,9 +74,10 @@ after successful negotiation."
72 :type 'boolean 74 :type 'boolean
73 :group 'tls) 75 :group 'tls)
74 76
75(defcustom tls-success "- Handshake was completed" 77(defcustom tls-success "- Handshake was completed\\|SSL handshake has read "
76 "*Regular expression indicating completed TLS handshakes. 78 "*Regular expression indicating completed TLS handshakes.
77The default is what GNUTLS's \"gnutls-cli\" outputs." 79The default is what GNUTLS's \"gnutls-cli\" or OpenSSL's
80\"openssl s_client\" outputs."
78 :version "22.1" 81 :version "22.1"
79 :type 'regexp 82 :type 'regexp
80 :group 'tls) 83 :group 'tls)
@@ -109,11 +112,11 @@ Used by `tls-certificate-information'."
109 (push (cons (match-string 1) (match-string 2)) vals)) 112 (push (cons (match-string 1) (match-string 2)) vals))
110 (nreverse vals)))))) 113 (nreverse vals))))))
111 114
112(defun open-tls-stream (name buffer host service) 115(defun open-tls-stream (name buffer host port)
113 "Open a TLS connection for a service to a host. 116 "Open a TLS connection for a port to a host.
114Returns a subprocess-object to represent the connection. 117Returns a subprocess-object to represent the connection.
115Input and output work as for subprocesses; `delete-process' closes it. 118Input and output work as for subprocesses; `delete-process' closes it.
116Args are NAME BUFFER HOST SERVICE. 119Args are NAME BUFFER HOST PORT.
117NAME is name for process. It is modified if necessary to make it unique. 120NAME is name for process. It is modified if necessary to make it unique.
118BUFFER is the buffer (or buffer-name) to associate with the process. 121BUFFER is the buffer (or buffer-name) to associate with the process.
119 Process output goes at end of that buffer, unless you specify 122 Process output goes at end of that buffer, unless you specify
@@ -121,8 +124,7 @@ BUFFER is the buffer (or buffer-name) to associate with the process.
121 BUFFER may be also nil, meaning that this process is not associated 124 BUFFER may be also nil, meaning that this process is not associated
122 with any buffer 125 with any buffer
123Third arg is name of the host to connect to, or its IP address. 126Third arg is name of the host to connect to, or its IP address.
124Fourth arg SERVICE is name of the service desired, or an integer 127Fourth arg PORT is an integer specifying a port to connect to."
125specifying a port number to connect to."
126 (let ((cmds tls-program) cmd done) 128 (let ((cmds tls-program) cmd done)
127 (message "Opening TLS connection to `%s'..." host) 129 (message "Opening TLS connection to `%s'..." host)
128 (while (and (not done) (setq cmd (pop cmds))) 130 (while (and (not done) (setq cmd (pop cmds)))
@@ -134,9 +136,9 @@ specifying a port number to connect to."
134 cmd 136 cmd
135 (format-spec-make 137 (format-spec-make
136 ?h host 138 ?h host
137 ?p (if (integerp service) 139 ?p (if (integerp port)
138 (int-to-string service) 140 (int-to-string port)
139 service))))) 141 port)))))
140 response) 142 response)
141 (while (and process 143 (while (and process
142 (memq (process-status process) '(open run)) 144 (memq (process-status process) '(open run))