SSL_COMP_add_compression_method.pod 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. =pod
  2. =head1 NAME
  3. SSL_COMP_add_compression_method - handle SSL/TLS integrated compression methods
  4. =head1 SYNOPSIS
  5. #include <openssl/ssl.h>
  6. int SSL_COMP_add_compression_method(int id, COMP_METHOD *cm);
  7. =head1 DESCRIPTION
  8. SSL_COMP_add_compression_method() adds the compression method B<cm> with
  9. the identifier B<id> to the list of available compression methods. This
  10. list is globally maintained for all SSL operations within this application.
  11. It cannot be set for specific SSL_CTX or SSL objects.
  12. =head1 NOTES
  13. The TLS standard (or SSLv3) allows the integration of compression methods
  14. into the communication. The TLS RFC does however not specify compression
  15. methods or their corresponding identifiers, so there is currently no compatible
  16. way to integrate compression with unknown peers. It is therefore currently not
  17. recommended to integrate compression into applications. Applications for
  18. non-public use may agree on certain compression methods. Using different
  19. compression methods with the same identifier will lead to connection failure.
  20. An OpenSSL client speaking a protocol that allows compression (SSLv3, TLSv1)
  21. will unconditionally send the list of all compression methods enabled with
  22. SSL_COMP_add_compression_method() to the server during the handshake.
  23. Unlike the mechanisms to set a cipher list, there is no method available to
  24. restrict the list of compression method on a per connection basis.
  25. An OpenSSL server will match the identifiers listed by a client against
  26. its own compression methods and will unconditionally activate compression
  27. when a matching identifier is found. There is no way to restrict the list
  28. of compression methods supported on a per connection basis.
  29. The OpenSSL library has the compression methods B<COMP_rle()> and (when
  30. especially enabled during compilation) B<COMP_zlib()> available.
  31. =head1 WARNINGS
  32. Once the identities of the compression methods for the TLS protocol have
  33. been standardized, the compression API will most likely be changed. Using
  34. it in the current state is not recommended.
  35. =head1 RETURN VALUES
  36. SSL_COMP_add_compression_method() may return the following values:
  37. =over 4
  38. =item Z<>0
  39. The operation succeeded.
  40. =item Z<>1
  41. The operation failed. Check the error queue to find out the reason.
  42. =back
  43. =head1 SEE ALSO
  44. L<ssl(3)|ssl(3)>
  45. =cut