#include "spf_sys_config.h"
#include "spf.h"
#include "spf_internal.h"
Go to the source code of this file.
Functions | |
void | SPF_get_lib_version (int *major, int *minor, int *patch) |
char * | SPF_sanitize (SPF_server_t *spf_server, char *str) |
const char * | SPF_strresult (SPF_result_t result) |
const char * | SPF_strreason (SPF_reason_t reason) |
const char * | SPF_strrrtype (ns_type rr_type) |
SPF_errcode_t | SPF_recalloc (char **bufp, size_t *buflenp, size_t buflen) |
void SPF_get_lib_version | ( | int * | major, | |
int * | minor, | |||
int * | patch | |||
) |
Returns the version numbers of this library.
Definition at line 38 of file spf_utils.c.
Referenced by main().
SPF_errcode_t SPF_recalloc | ( | char ** | bufp, | |
size_t * | buflenp, | |||
size_t | buflen | |||
) |
This is NOT a general-purpose realloc. It is used only for text buffers. It will allocate at least 64 bytes of storage.
This function is allowed to zero all the RAM returned, so it really isn't a realloc.
Do not call this function from outside the library.
Definition at line 188 of file spf_utils.c.
References NULL, and SPF_ASSERT_NOTNULL.
Referenced by SPF_record_expand_data(), and SPF_record_stringify().
char* SPF_sanitize | ( | SPF_server_t * | spf_server, | |
char * | str | |||
) |
Sanitizes a string for printing.
This replaces all nonprintable characters in str with a '?'. The source string is modified in-place.
Definition at line 54 of file spf_utils.c.
References NULL, and SPF_ASSERT_NOTNULL.
const char* SPF_strreason | ( | SPF_reason_t | reason | ) |
Converts an SPF reason to a short human-readable string.
Definition at line 128 of file spf_utils.c.
References SPF_REASON_2MX, SPF_REASON_DEFAULT, SPF_REASON_LOCAL_POLICY, SPF_REASON_LOCALHOST, SPF_REASON_MECH, and SPF_REASON_NONE.
Referenced by SPF_record_interpret().
const char* SPF_strresult | ( | SPF_result_t | result | ) |
Converts an SPF result to a short human-readable string.
Definition at line 81 of file spf_utils.c.
References SPF_RESULT_FAIL, SPF_RESULT_INVALID, SPF_RESULT_NEUTRAL, SPF_RESULT_NONE, SPF_RESULT_PASS, SPF_RESULT_PERMERROR, SPF_RESULT_SOFTFAIL, and SPF_RESULT_TEMPERROR.
Referenced by main(), and SPF_record_interpret().