2
0

BIO_f_readbuffer.pod 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. =pod
  2. =head1 NAME
  3. BIO_f_readbuffer
  4. - read only buffering BIO that supports BIO_tell() and BIO_seek()
  5. =head1 SYNOPSIS
  6. #include <openssl/bio.h>
  7. const BIO_METHOD *BIO_f_readbuffer(void);
  8. =head1 DESCRIPTION
  9. BIO_f_readbuffer() returns the read buffering BIO method.
  10. This BIO filter can be inserted on top of BIO's that do not support BIO_tell()
  11. or BIO_seek() (e.g. A file BIO that uses stdin).
  12. Data read from a read buffering BIO comes from an internal buffer which is
  13. filled from the next BIO in the chain.
  14. BIO_gets() is supported for read buffering BIOs.
  15. Writing data to a read buffering BIO is not supported.
  16. Calling BIO_reset() on a read buffering BIO does not clear any buffered data.
  17. =head1 NOTES
  18. Read buffering BIOs implement BIO_read_ex() by using BIO_read_ex() operations
  19. on the next BIO (e.g. a file BIO) in the chain and storing the result in an
  20. internal buffer, from which bytes are given back to the caller as appropriate
  21. for the call. BIO_read_ex() is guaranteed to give the caller the number of bytes
  22. it asks for, unless there's an error or end of communication is reached in the
  23. next BIO. The internal buffer can grow to cache the entire contents of the next
  24. BIO in the chain. BIO_seek() uses the internal buffer, so that it can only seek
  25. into data that is already read.
  26. =head1 RETURN VALUES
  27. BIO_f_readbuffer() returns the read buffering BIO method.
  28. =head1 SEE ALSO
  29. L<bio(7)>,
  30. L<BIO_read(3)>,
  31. L<BIO_gets(3)>,
  32. L<BIO_reset(3)>,
  33. L<BIO_ctrl(3)>.
  34. =head1 COPYRIGHT
  35. Copyright 2021 The OpenSSL Project Authors. All Rights Reserved.
  36. Licensed under the Apache License 2.0 (the "License"). You may not use
  37. this file except in compliance with the License. You can obtain a copy
  38. in the file LICENSE in the source distribution or at
  39. L<https://www.openssl.org/source/license.html>.
  40. =cut