Basic SNI support.

master
Tomek Dubrownik 2012-07-23 07:58:31 +02:00
parent f6a380940b
commit ad70733015
2 changed files with 4 additions and 2 deletions

View File

@ -563,6 +563,7 @@ PARAMETERS will not be used."
:key key
:certificate-password certificate-password
:verify verify
:hostname (uri-host uri)
:max-depth max-depth
:ca-file ca-file
:ca-directory ca-directory)))

View File

@ -305,7 +305,7 @@ which are not meant as separators."
(go next-cookie))))))
#-:lispworks
(defun make-ssl-stream (http-stream &key certificate key certificate-password verify (max-depth 10) ca-file ca-directory)
(defun make-ssl-stream (http-stream &key certificate key certificate-password verify (max-depth 10) ca-file ca-directory hostname)
"Attaches SSL to the stream HTTP-STREAM and returns the SSL stream
\(which will not be equal to HTTP-STREAM)."
(declare (ignorable max-depth))
@ -337,6 +337,7 @@ which are not meant as separators."
:close-callback (lambda () (close s))
:certificate certificate
:key key
:hostname hostname
:password certificate-password))
#+:drakma-no-ssl
(error "SSL not supported. Remove :drakma-no-ssl from *features* to enable SSL"))
@ -347,4 +348,4 @@ corresponding alist of name/value pairs."
(when query-string
(loop for parameter-pair in (cl-ppcre:split "&" query-string)
for (name value) = (cl-ppcre:split "=" parameter-pair :limit 2)
collect (cons name value))))
collect (cons name value))))