README 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. easy_tls - generic SSL/TLS proxy
  2. ========
  3. (... and example for non-blocking SSL/TLS I/O multiplexing.)
  4. easy_tls.c, easy_tls.h:
  5. Small generic SSL/TLS proxy library: With a few function calls,
  6. an application socket will be replaced by a pipe handled by a
  7. separate SSL/TLS proxy process. This allows easily adding
  8. SSL/TLS support to many programs not originally designed for it.
  9. [Actually easy_tls.c is not a proper library: Customization
  10. requires defining preprocessor macros while compiling it.
  11. This is quite confusing, so I'll probably change it.]
  12. These files may be used under the OpenSSL license.
  13. test.c, test.h, Makefile, cert.pem, cacerts.pem:
  14. Rudimentary example program using the easy_tls library, and
  15. example key and certificates for it. Usage examples:
  16. $ ./test 8443 # create server listening at port 8443
  17. $ ./test 127.0.0.1 8443 # create client, connect to port 8443
  18. # at IP address 127.0.0.1
  19. 'test' will not automatically do SSL/TLS, or even read or write
  20. data -- it must be told to do so on input lines starting
  21. with a command letter. 'W' means write a line, 'R' means
  22. read a line, 'C' means close the connection, 'T' means
  23. start an SSL/TLS proxy. E.g. (user input tagged with '*'):
  24. * R
  25. <<< 220 mail.example.net
  26. * WSTARTTLS
  27. >>> STARTTLS
  28. * R
  29. <<< 220 Ready to start TLS
  30. * T
  31. test_process_init(fd = 3, client_p = 1, apparg = (nil))
  32. +++ `E:self signed certificate in certificate chain'
  33. +++ `<... certificate info ...>'
  34. * WHELO localhost
  35. >>> HELO localhost
  36. R
  37. <<< 250 mail.example.net
  38. You can even do SSL/TLS over SSL/TLS over SSL/TLS ... by using
  39. 'T' multiple times. I have no idea why you would want to though.
  40. This code is rather old. When I find time I will update anything that
  41. should be changed, and improve code comments. To compile the sample
  42. program 'test' on platforms other then Linux or Solaris, you will have
  43. to edit the Makefile.
  44. As noted above, easy_tls.c will be changed to become a library one
  45. day, which means that future revisions will not be fully compatible to
  46. the current version.
  47. Bodo Möller <bodo@openssl.org>