[plt-scheme] Re: email using ssl

From: geb a (geb_a at yahoo.com)
Date: Wed Feb 21 13:26:54 EST 2007

I've found this code snippet in the archives because
I've been tackling a similar problem with our school's
email system and I was wondering if this issue might
have been addressed and I've somehow overlooked it.

Thanks for the time,



;    (lib "head.ss" "net")
;    (lib "smtp.ss" "net")
;    (lib "mzssl.ss" "openssl"))
;(let ([gmail-account <gmail-address>]
;       [to <email-address>])
;     (smtp-send-message "smtp.google.com"
;                        gmail-account
;                        (list to)
;                        (standard-message-header
(list to)
;                                                 '()
"This is a test")
;                        (map string->bytes/locale
;                             (list "This message is a
;                                   "It is only a
;                        #:port-no 25
;                        #:auth-user gmail-account
;                        #:auth-passwd
;                        #:tcp-connect ssl-connect))
;This fails with
;ssl-connect: connect failed (error:140770FC:SSL 
;routines:SSL23_GET_SERVER_HELLO:unknown protocol)
;If I replace "ssl-connect" with
;(lambda (host port)
;   (ssl-connect host port 'tls))
;it fails with
;ssl-connect: connect failed (error:1408F10B:SSL 
;routines:SSL3_GET_RECORD:wrong version number)
;which is the same error if I use 'sslv3. The
ssl-connect times out if I 
;use 'sslv2. I get the SSL23_GET_SERVER_HELO error if
I use 'sslv2-or-v3.

We won't tell. Get more on shows you hate to love 
(and love to hate): Yahoo! TV's Guilty Pleasures list.

Posted on the users mailing list.