BIO_get_ex_new_index.pod 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. =pod
  2. =head1 NAME
  3. BIO_get_ex_new_index, BIO_set_ex_data, BIO_get_ex_data,
  4. BIO_set_app_data, BIO_get_app_data,
  5. DH_get_ex_new_index, DH_set_ex_data, DH_get_ex_data,
  6. DSA_get_ex_new_index, DSA_set_ex_data, DSA_get_ex_data,
  7. ECDH_get_ex_new_index, ECDH_set_ex_data, ECDH_get_ex_data,
  8. EC_KEY_get_ex_new_index, EC_KEY_set_ex_data, EC_KEY_get_ex_data,
  9. ENGINE_get_ex_new_index, ENGINE_set_ex_data, ENGINE_get_ex_data,
  10. EVP_PKEY_get_ex_new_index, EVP_PKEY_set_ex_data, EVP_PKEY_get_ex_data,
  11. RSA_get_ex_new_index, RSA_set_ex_data, RSA_get_ex_data,
  12. RSA_set_app_data, RSA_get_app_data,
  13. SSL_get_ex_new_index, SSL_set_ex_data, SSL_get_ex_data,
  14. SSL_set_app_data, SSL_get_app_data,
  15. SSL_CTX_get_ex_new_index, SSL_CTX_set_ex_data, SSL_CTX_get_ex_data,
  16. SSL_CTX_set_app_data, SSL_CTX_get_app_data,
  17. SSL_SESSION_get_ex_new_index, SSL_SESSION_set_ex_data, SSL_SESSION_get_ex_data,
  18. SSL_SESSION_set_app_data, SSL_SESSION_get_app_data,
  19. UI_get_ex_new_index, UI_set_ex_data, UI_get_ex_data,
  20. UI_set_app_data, UI_get_app_data,
  21. X509_STORE_CTX_get_ex_new_index, X509_STORE_CTX_set_ex_data, X509_STORE_CTX_get_ex_data,
  22. X509_STORE_CTX_set_app_data, X509_STORE_CTX_get_app_data,
  23. X509_STORE_get_ex_new_index, X509_STORE_set_ex_data, X509_STORE_get_ex_data,
  24. X509_get_ex_new_index, X509_set_ex_data, X509_get_ex_data
  25. - application-specific data
  26. =head1 SYNOPSIS
  27. =for openssl generic
  28. #include <openssl/x509.h>
  29. int TYPE_get_ex_new_index(long argl, void *argp,
  30. CRYPTO_EX_new *new_func,
  31. CRYPTO_EX_dup *dup_func,
  32. CRYPTO_EX_free *free_func);
  33. int TYPE_set_ex_data(TYPE *d, int idx, void *arg);
  34. void *TYPE_get_ex_data(const TYPE *d, int idx);
  35. #define TYPE_set_app_data(TYPE *d, void *arg)
  36. #define TYPE_get_app_data(TYPE *d)
  37. =head1 DESCRIPTION
  38. In the description here, I<TYPE> is used a placeholder
  39. for any of the OpenSSL datatypes listed in
  40. L<CRYPTO_get_ex_new_index(3)>.
  41. These functions handle application-specific data for OpenSSL data
  42. structures.
  43. TYPE_get_ex_new_index() is a macro that calls CRYPTO_get_ex_new_index()
  44. with the correct B<index> value.
  45. TYPE_set_ex_data() is a function that calls CRYPTO_set_ex_data() with
  46. an offset into the opaque exdata part of the TYPE object.
  47. TYPE_get_ex_data() is a function that calls CRYPTO_get_ex_data() with
  48. an offset into the opaque exdata part of the TYPE object.
  49. For compatibility with previous releases, the exdata index of zero is
  50. reserved for "application data." There are two convenience functions for
  51. this.
  52. TYPE_set_app_data() is a macro that invokes TYPE_set_ex_data() with
  53. B<idx> set to zero.
  54. TYPE_get_app_data() is a macro that invokes TYPE_get_ex_data() with
  55. B<idx> set to zero.
  56. =head1 RETURN VALUES
  57. TYPE_get_ex_new_index() returns a new index on success or -1 on error.
  58. TYPE_set_ex_data() returns 1 on success or 0 on error.
  59. TYPE_get_ex_data() returns the application data or NULL if an error occurred.
  60. =head1 SEE ALSO
  61. L<CRYPTO_get_ex_new_index(3)>.
  62. =head1 HISTORY
  63. The ENGINE_get_ex_new_index(), ENGINE_set_ex_data() and ENGINE_get_ex_data()
  64. functions were deprecated in OpenSSL 3.0.
  65. =head1 COPYRIGHT
  66. Copyright 2015-2020 The OpenSSL Project Authors. All Rights Reserved.
  67. Licensed under the Apache License 2.0 (the "License"). You may not use
  68. this file except in compliance with the License. You can obtain a copy
  69. in the file LICENSE in the source distribution or at
  70. L<https://www.openssl.org/source/license.html>.
  71. =cut