The error message here is not helpful. I believe the real problem is that CL + SSL expects an octet stream, while the main standard input stream in Common Lisp is a character stream. Instead, try using an octet stream. This should work on SBCL on Linux:
(let ((stdin (sb-sys:make-fd-stream 0 :input t :buffering :full :element-type '(unsigned-byte 8))) (cl+ssl:make-ssl-client-stream (cl+ssl:stream-fd stdin)))
It depends on the fact that Unix has standard input available as a file descriptor of 0. I am not sure how to perform such a trick on Windows.
For a real application, you probably really don't want to work with standard input, something like this will work using the usocket library:
(let ((sock (usocket:socket-connect host port :element-type '(unsigned-byte 8)))) (cl+ssl:make-ssl-client-stream (usocket:socket-stream sock)))
source share