aboutsummaryrefslogtreecommitdiffstats
path: root/camel/camel-tcp-stream-ssl.h
Commit message (Collapse)AuthorAgeFilesLines
* Various fixes to make it work.Not Zed2003-08-191-3/+4
| | | | | | | | | | | | | | | | | | | | | 2003-08-18 Not Zed <NotZed@Ximian.com> * camel-http-stream.c: Various fixes to make it work. * tests/smime/pgp-mime.c (main): added missing 'ret' variable. * providers/smtp/camel-smtp-transport.c (connect_to_server): * providers/imapp/camel-imapp-store.c (connect_to_server: * providers/imap/camel-imap-store.c (connect_to_server): * providers/pop3/camel-pop3-store.c (connect_to_server): * camel-http-stream.c (http_connect): change service->session for tcp_stream_ssl_new. * camel-tcp-stream-ssl.c: Changed service to session, and fix some refcounting of it. include camel-operation.h svn path=/trunk/; revision=22275
* Same as IMAP and POP.Jeffrey Stedfast2003-03-011-2/+8
| | | | | | | | | | | | | | | | | | | | | | 2003-02-28 Jeffrey Stedfast <fejj@ximian.com> * providers/smtp/camel-smtp-transport.c (connect_to_server): Same as IMAP and POP. * providers/imap/camel-imap-store.c (connect_to_server): Same as the POP3 code. * providers/pop3/camel-pop3-store.c (connect_to_server): Pass in appropriate flags for camel_tcp_stream_ssl_new*() functions. * camel-tcp-stream-ssl.c (enable_ssl): Not all ssl/tls streams will want to allow each of SSLv2, SSLv3 and TLSv1 so use flags to decide which to enable/disable. (camel_tcp_stream_ssl_new): Now takes a flags argument to mask out which SSL/TLS versions the stream should be compatable with. (camel_tcp_stream_ssl_new_raw): Same. svn path=/trunk/; revision=20111
* Start the ssl stream off in non-ssl mode (useful for STARTTLS).Jeffrey Stedfast2002-03-061-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2002-03-05 Jeffrey Stedfast <fejj@ximian.com> * camel-tcp-stream-openssl.c (camel_tcp_stream_openssl_new_raw): Start the ssl stream off in non-ssl mode (useful for STARTTLS). (camel_tcp_stream_openssl_enable_ssl): New function to toggle an ssl stream into ssl mode. (open_ssl_connection): Close the sockfd on fail so our caller doesn't have to - this also allows us to save the original errno. (stream_connect): If we want ssl mode, do our ssl stuff. (camel_tcp_stream_openssl_class_init): Init some SSL stuff here instead of in open_ssl_connection since these only ever need to be called once. (stream_read): Only use SSL_read if we are in ssl mode. (stream_write): Only use SSL_write if we are in ssl mode. * providers/smtp/camel-smtp-transport.c (smtp_helo): Check for the STARTTLS extension. (connect_to_server): Try to use STARTTLS whenever possible rather than the old way of doing things. (connect_to_server_wrapper): Wrapper around connect_to_server() to first try STARTTLS and then attempt normal SSL mode if we can't connect via STARTTLS. * camel-tcp-stream-ssl.c (camel_tcp_stream_ssl_enable_ssl): New function to toggle an ssl stream into ssl mode. (camel_tcp_stream_ssl_new_raw): Start the ssl stream off in non-ssl mode (useful for STARTTLS). (stream_connect): Only connect in SSL mode if required. svn path=/trunk/; revision=15937
* More fixing of the license texts.Ettore Perazzoli2001-10-281-11/+11
| | | | svn path=/trunk/; revision=14216
* Same hack as below.Jeffrey Stedfast2001-10-111-1/+0
| | | | | | | | | | | 2001-10-10 Jeffrey Stedfast <fejj@ximian.com> * camel-tcp-stream-openssl.c (ssl_verify): Same hack as below. * camel-tcp-stream-ssl.c (ssl_bad_cert): Hack around the fact that adding a cert to nss's certdb seems to not work. svn path=/trunk/; revision=13575
* Print info about the issuer of the certificate.Jeffrey Stedfast2001-03-171-9/+1
| | | | | | | | | | | | | | | | | | | | 2001-03-16 Jeffrey Stedfast <fejj@ximian.com> * camel-tcp-stream-ssl.c (ssl_bad_cert): Print info about the issuer of the certificate. * providers/smtp/camel-smtp-transport.c (smtp_connect): Use camel_tcp_stream_get_socket(). * camel-tcp-stream-openssl.c (stream_get_socket): Implemented. * camel-tcp-stream-ssl.c (stream_get_socket): Implemented. * camel-tcp-stream-raw.c (stream_get_socket): Implemented. * camel-tcp-stream.c (camel_tcp_stream_get_socket): New function. svn path=/trunk/; revision=8764
* Uninclude prnetdb.h since it's not needed here.Jeffrey Stedfast2001-03-161-2/+1
| | | | | | | | | | | | | | | | 2001-03-15 Jeffrey Stedfast <fejj@ximian.com> * camel-tcp-stream-ssl.h: Uninclude prnetdb.h since it's not needed here. * providers/smtp/camel-smtp-transport.c: #include prnetdb.h here instead of making camel-tcp-stream-ssl.h include it. Prevents some header bloat. * providers/smtp/Makefile.am: Include the NSPR_CFLAGS and NSS_CFLAGS. svn path=/trunk/; revision=8738
* Update for using CamelTcpStreams and also for using SSL.Jeffrey Stedfast2001-03-151-1/+2
| | | | | | | | | | | | | | | 2001-03-14 Jeffrey Stedfast <fejj@ximian.com> * providers/smtp/camel-smtp-transport.c (smtp_connect): Update for using CamelTcpStreams and also for using SSL. * providers/smtp/libcamelsmtp.urls: defined "ssmtp" * providers/smtp/camel-smtp-provider.c: Defined the Secure SMTP provider. (camel_provider_module_init): Register the Secure SMTP provider. svn path=/trunk/; revision=8728
* Pass the service into the SSL stream, not the session.Jeffrey Stedfast2001-03-151-4/+4
| | | | | | | | | | | | | | | 2001-03-14 Jeffrey Stedfast <fejj@ximian.com> * camel-remote-store.c (remote_connect): Pass the service into the SSL stream, not the session. * camel-tcp-stream-ssl.c (camel_tcp_stream_ssl_init): Set the service to NULL. (camel_tcp_stream_ssl_finalize): Unref the service. (camel_tcp_stream_ssl_new): Takes a CamelService arg now rather than a CamelSession arg. svn path=/trunk/; revision=8720
* Comment out everything unless HAVE_NSS is defined.Jeffrey Stedfast2001-03-111-3/+7
| | | | | | | | | | | | | 2001-03-09 Jeffrey Stedfast <fejj@ximian.com> * camel-tcp-stream-ssl.h: Comment out everything unless HAVE_NSS is defined. * camel-tcp-stream-ssl.c (stream_read): Don't use errno, use nspr's error code stuff. (stream_write): Same. svn path=/trunk/; revision=8626
* Ugh, this design is ugly like my butt.Jeffrey Stedfast2001-01-161-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | 2001-01-16 Jeffrey Stedfast <fejj@ximian.com> Ugh, this design is ugly like my butt. * camel-session.c (camel_session_query_cert_authenticator): New function which will be useful when we integrate SSL. * camel-tcp-stream-ssl.c (ssl_auth_cert): Callback to authenticate a certificate. (ssl_bad_cert): Callback that gets the reason the certificate is bad and then calls camel's cert-authenticator callback to notify the user and to allow the user to override the check. (stream_connect): Set the URL we expect to connect with and setup the auth_cert and bad_cert callbacks. (camel_tcp_stream_ssl_new): Now takes a CamelSession and a expected_host argument that it will use for certificate authentication. (camel_tcp_stream_ssl_finalize): Unref the session and free the expected_host. svn path=/trunk/; revision=7531
* New CamelTcpStream class that implements nspr sockets and eventually willJeffrey Stedfast2001-01-141-0/+66
2001-01-14 Jeffrey Stedfast <fejj@helixcode.com> * camel-tcp-stream-ssl.[c,h]: New CamelTcpStream class that implements nspr sockets and eventually will use nss for SSL/TLS. Currently doesn't do any SSL/TLS but it should still work. It's functionally equivalent to CamelTcpStreamRaw at the moment only it uses nspr i/o. * camel-tcp-stream-raw.[c,h]: New CamelTcpStream class that implements native sockets. Should be usable but may have some bugs yet. svn path=/trunk/; revision=7489