bio.h 1.1 KB

12345678910111213141516171819202122232425262728293031323334
  1. #include <contrib/libs/openssl/redef.h>
  2. /*
  3. * Copyright 2016-2018 The OpenSSL Project Authors. All Rights Reserved.
  4. *
  5. * Licensed under the OpenSSL license (the "License"). You may not use
  6. * this file except in compliance with the License. You can obtain a copy
  7. * in the file LICENSE in the source distribution or at
  8. * https://www.openssl.org/source/license.html
  9. */
  10. #include <openssl/bio.h>
  11. struct bio_method_st {
  12. int type;
  13. char *name;
  14. int (*bwrite) (BIO *, const char *, size_t, size_t *);
  15. int (*bwrite_old) (BIO *, const char *, int);
  16. int (*bread) (BIO *, char *, size_t, size_t *);
  17. int (*bread_old) (BIO *, char *, int);
  18. int (*bputs) (BIO *, const char *);
  19. int (*bgets) (BIO *, char *, int);
  20. long (*ctrl) (BIO *, int, long, void *);
  21. int (*create) (BIO *);
  22. int (*destroy) (BIO *);
  23. long (*callback_ctrl) (BIO *, int, BIO_info_cb *);
  24. };
  25. void bio_free_ex_data(BIO *bio);
  26. void bio_cleanup(void);
  27. /* Old style to new style BIO_METHOD conversion functions */
  28. int bwrite_conv(BIO *bio, const char *data, size_t datal, size_t *written);
  29. int bread_conv(BIO *bio, char *data, size_t datal, size_t *read);