|
libspf2 1.2.11
|
#include "spf_sys_config.h"#include "spf.h"#include "spf_dns.h"#include "spf_internal.h"#include "spf_dns_internal.h"
Go to the source code of this file.
Functions | |
| void | SPF_dns_free (SPF_dns_server_t *spf_dns_server) |
| SPF_dns_rr_t * | SPF_dns_lookup (SPF_dns_server_t *spf_dns_server, const char *domain, ns_type rr_type, int should_cache) |
| SPF_dns_rr_t * | SPF_dns_rlookup (SPF_dns_server_t *spf_dns_server, struct in_addr ipv4, ns_type rr_type, int should_cache) |
| SPF_dns_rr_t * | SPF_dns_rlookup6 (SPF_dns_server_t *spf_dns_server, struct in6_addr ipv6, ns_type rr_type, int should_cache) |
| char * | SPF_dns_get_client_dom (SPF_dns_server_t *spf_dns_server, SPF_request_t *sr) |
| void SPF_dns_free | ( | SPF_dns_server_t * | spf_dns_server | ) |
Definition at line 116 of file spf_dns.c.
References NULL, SPF_ASSERT_NOTNULL, and SPF_dns_free().
Referenced by SPF_dns_free(), and SPF_server_free().

| char * SPF_dns_get_client_dom | ( | SPF_dns_server_t * | spf_dns_server, |
| SPF_request_t * | sr ) |
This may return NULL if the strdup() fails.
This ought to be refactored with the PTR code in the interpreter.
The client domain is the validated domain name of the client IP address. This is not just the domain name(s) found in the reverse DNS tree, but involves checking to make sure these name(s) use the client IP address. The complete validation procedure is described in section 5.4 of the SPF spec.
Definition at line 206 of file spf_dns.c.
References SPF_dns_rr_data_t::a, SPF_dns_rr_data_t::aaaa, FALSE, ns_t_a, ns_t_aaaa, ns_t_ptr, SPF_dns_rr_t::num_rr, SPF_dns_rr_data_t::ptr, SPF_dns_rr_t::rr, SPF_ASSERT_NOTNULL, SPF_dns_lookup(), SPF_dns_rlookup(), SPF_dns_rlookup6(), SPF_dns_rr_free(), and SPF_MAX_DNS_PTR.
Referenced by SPF_request_get_client_dom().

| SPF_dns_rr_t * SPF_dns_lookup | ( | SPF_dns_server_t * | spf_dns_server, |
| const char * | domain, | ||
| ns_type | rr_type, | ||
| int | should_cache ) |
Definition at line 133 of file spf_dns.c.
References NULL, SPF_ASSERT_NOTNULL, and SPF_error.
Referenced by main(), SPF_dns_get_client_dom(), SPF_dns_rlookup(), SPF_dns_rlookup6(), SPF_record_interpret(), SPF_request_get_exp(), and SPF_server_get_record().
| SPF_dns_rr_t * SPF_dns_rlookup | ( | SPF_dns_server_t * | spf_dns_server, |
| struct in_addr | ipv4, | ||
| ns_type | rr_type, | ||
| int | should_cache ) |
Definition at line 150 of file spf_dns.c.
References SPF_dns_lookup().
Referenced by main(), SPF_dns_get_client_dom(), and SPF_record_interpret().

| SPF_dns_rr_t * SPF_dns_rlookup6 | ( | SPF_dns_server_t * | spf_dns_server, |
| struct in6_addr | ipv6, | ||
| ns_type | rr_type, | ||
| int | should_cache ) |
Definition at line 171 of file spf_dns.c.
References SPF_dns_lookup().
Referenced by SPF_dns_get_client_dom(), and SPF_record_interpret().
