SSL_pending.pod 992 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. =pod
  2. =head1 NAME
  3. SSL_pending - obtain number of readable bytes buffered in an SSL object
  4. =head1 SYNOPSIS
  5. #include <openssl/ssl.h>
  6. int SSL_pending(const SSL *ssl);
  7. =head1 DESCRIPTION
  8. SSL_pending() returns the number of bytes which are available inside
  9. B<ssl> for immediate read.
  10. =head1 NOTES
  11. Data are received in blocks from the peer. Therefore data can be buffered
  12. inside B<ssl> and are ready for immediate retrieval with
  13. L<SSL_read(3)|SSL_read(3)>.
  14. =head1 RETURN VALUES
  15. The number of bytes pending is returned.
  16. =head1 BUGS
  17. SSL_pending() takes into account only bytes from the TLS/SSL record
  18. that is currently being processed (if any). If the B<SSL> object's
  19. I<read_ahead> flag is set, additional protocol bytes may have been
  20. read containing more TLS/SSL records; these are ignored by
  21. SSL_pending().
  22. Up to OpenSSL 0.9.6, SSL_pending() does not check if the record type
  23. of pending data is application data.
  24. =head1 SEE ALSO
  25. L<SSL_read(3)|SSL_read(3)>, L<ssl(3)|ssl(3)>
  26. =cut