|
Botan 3.13.0
Crypto and TLS for C&
|
#include <botan/ffi.h>#include <botan/assert.h>#include <botan/internal/ffi_cert.h>#include <botan/internal/ffi_util.h>Go to the source code of this file.
Functions | |
| int | botan_x509_ext_as_blocks_get_entry_at (botan_x509_cert_t cert, int asnum, size_t i, uint32_t *min, uint32_t *max) |
| int | botan_x509_ext_as_blocks_get_info (botan_x509_cert_t cert, int asnum, int *present, size_t *count) |
| int | botan_x509_ext_ip_addr_blocks_get_address (botan_x509_cert_t cert, int ipv6, size_t i, size_t entry, uint8_t min_out[], uint8_t max_out[], size_t *out_len) |
| int | botan_x509_ext_ip_addr_blocks_get_counts (botan_x509_cert_t cert, size_t *v4_count, size_t *v6_count) |
| int | botan_x509_ext_ip_addr_blocks_get_family (botan_x509_cert_t cert, int ipv6, size_t i, int *has_safi, uint8_t *safi, int *present, size_t *count) |
| int botan_x509_ext_as_blocks_get_entry_at | ( | botan_x509_cert_t | cert, |
| int | asnum, | ||
| size_t | i, | ||
| uint32_t * | min, | ||
| uint32_t * | max ) |
Get a specific entry in the AS Blocks extension from RFC 3779
| cert | the certificate to inspect |
| asnum | Set to 1 to get info about AS numbers, 0 for RDIs (the type) |
| i | The index of the entry to get |
| min | is set to the min value of the range |
| max | is set to the max value of the range |
If the extension is not present or an error occurs, min and max are not modified
Definition at line 222 of file ffi_cert_ext.cpp.
References Botan::any_null_pointers(), Botan::Cert_Extension::ASBlocks::as_identifiers(), Botan::Cert_Extension::ASBlocks::ASIdentifiers::asnum(), BOTAN_FFI_ERROR_BAD_PARAMETER, BOTAN_FFI_ERROR_NO_VALUE, BOTAN_FFI_ERROR_NOT_IMPLEMENTED, BOTAN_FFI_ERROR_NULL_POINTER, BOTAN_FFI_ERROR_OUT_OF_RANGE, BOTAN_FFI_SUCCESS, BOTAN_UNUSED, Botan_FFI::ffi_guard_thunk(), and Botan_FFI::safe_get().
| int botan_x509_ext_as_blocks_get_info | ( | botan_x509_cert_t | cert, |
| int | asnum, | ||
| int * | present, | ||
| size_t * | count ) |
Get basic info about the AS Blocks extension from RFC 3779
| cert | the certificate to inspect |
| asnum | must be set to 1 to get info about AS numbers, 0 for RDIs (the type) |
| present | is set to 1 if the extension contains entries for the type, 0 if it is marked as "inherit" |
| count | is set to number of entries for this type, if it was present, otherwise count is not modified |
If the extension is not present or an error occurs, present and count are not modified
Definition at line 183 of file ffi_cert_ext.cpp.
References Botan::any_null_pointers(), Botan::Cert_Extension::ASBlocks::as_identifiers(), Botan::Cert_Extension::ASBlocks::ASIdentifiers::asnum(), BOTAN_FFI_ERROR_BAD_PARAMETER, BOTAN_FFI_ERROR_NO_VALUE, BOTAN_FFI_ERROR_NOT_IMPLEMENTED, BOTAN_FFI_ERROR_NULL_POINTER, BOTAN_FFI_SUCCESS, BOTAN_UNUSED, Botan_FFI::ffi_guard_thunk(), and Botan_FFI::safe_get().
| int botan_x509_ext_ip_addr_blocks_get_address | ( | botan_x509_cert_t | cert, |
| int | ipv6, | ||
| size_t | i, | ||
| size_t | entry, | ||
| uint8_t | min_out[], | ||
| uint8_t | max_out[], | ||
| size_t * | out_len ) |
Get info about a specific range in the IP Address Blocks extension from RFC 3779
| cert | the certificate to inspect |
| ipv6 | must be set to 1 if the family is an IPv6 family, 0 for IPv4 families |
| i | is the (local) index of the family, see botan_x509_ext_ip_addr_blocks_get_family |
| entry | is the index of the range |
| min_out | is set to the lower address of the range |
| max_out | is set to the upper address of the range |
| out_len | is set to the length of the addresses (4 for IPv4, 16 for IPv6) |
The output parameters min_out, max_out and out_len may be modified even if the extension is not present or some other error occurs. In this event, the value of each output parameter after the call returns is undefined.
Definition at line 142 of file ffi_cert_ext.cpp.
References Botan::any_null_pointers(), BOTAN_FFI_ERROR_BAD_PARAMETER, BOTAN_FFI_ERROR_NO_VALUE, BOTAN_FFI_ERROR_NOT_IMPLEMENTED, BOTAN_FFI_ERROR_NULL_POINTER, BOTAN_FFI_ERROR_OUT_OF_RANGE, BOTAN_UNUSED, Botan_FFI::ffi_guard_thunk(), Botan_FFI::safe_get(), and Botan::Cert_Extension::IPAddressBlocks::v4_count().
| int botan_x509_ext_ip_addr_blocks_get_counts | ( | botan_x509_cert_t | cert, |
| size_t * | v4_count, | ||
| size_t * | v6_count ) |
Get info about the IP Address Blocks extension from RFC 3779
| cert | the certificate to inspect |
| v4_count | is set to the number of v4 families contained in the extension |
| v6_count | is set to the number of v6 families |
If the extension is not present or an error occurs, v4_count and v6_count are not modified
Definition at line 73 of file ffi_cert_ext.cpp.
References Botan::any_null_pointers(), BOTAN_FFI_ERROR_NO_VALUE, BOTAN_FFI_ERROR_NOT_IMPLEMENTED, BOTAN_FFI_ERROR_NULL_POINTER, BOTAN_FFI_SUCCESS, BOTAN_UNUSED, Botan_FFI::ffi_guard_thunk(), Botan_FFI::safe_get(), and Botan::Cert_Extension::IPAddressBlocks::v4_count().
| int botan_x509_ext_ip_addr_blocks_get_family | ( | botan_x509_cert_t | cert, |
| int | ipv6, | ||
| size_t | i, | ||
| int * | has_safi, | ||
| uint8_t * | safi, | ||
| int * | present, | ||
| size_t * | count ) |
Get info about a specific family in the IP Address Blocks extension from RFC 3779
| cert | the certificate to inspect |
| ipv6 | must be set to 1 if the family is an IPv6 family, 0 for IPv4 families |
| i | is the (local) index for this family kind (the first v4 family is at i = 0, ipv6 = 0; the first v6 family is at i = 0, ipv6 = 1) |
| has_safi | will be set to 1 if the family has an associated SAFI |
| safi | will be set to the families' SAFI, if it has one, otherwise safi is not modified |
| present | is set to 1 if the family contains values (ranges), 0 if it is marked as "inherit" |
| count | is set to the number of values (ranges), if they were present, otherwise count is not modified |
The output parameters has_safi, safi, present and count may be modified even if the extension is not present or some other error occurs. In this event, the value of each output parameter after the call returns is undefined.
Definition at line 96 of file ffi_cert_ext.cpp.
References Botan::any_null_pointers(), BOTAN_FFI_ERROR_BAD_PARAMETER, BOTAN_FFI_ERROR_NO_VALUE, BOTAN_FFI_ERROR_NOT_IMPLEMENTED, BOTAN_FFI_ERROR_NULL_POINTER, BOTAN_FFI_ERROR_OUT_OF_RANGE, BOTAN_UNUSED, Botan_FFI::ffi_guard_thunk(), Botan_FFI::safe_get(), Botan::Cert_Extension::IPAddressBlocks::IPAddressFamily::safi(), and Botan::Cert_Extension::IPAddressBlocks::v4_count().