PostgreSQL Source Code
git master
|
#include "postgres.h"
#include "utils/memutils.h"
#include "common/saslprep.h"
#include "common/string.h"
#include "common/unicode_norm.h"
#include "mb/pg_wchar.h"
Go to the source code of this file.
Macros | |
#define | STRDUP(s) pstrdup(s) |
#define | ALLOC(size) palloc(size) |
#define | FREE(size) pfree(size) |
#define | IS_CODE_IN_TABLE(code, map) is_code_in_table(code, map, lengthof(map)) |
Functions | |
static int | codepoint_range_cmp (const void *a, const void *b) |
static bool | is_code_in_table (pg_wchar code, const pg_wchar *map, int mapsize) |
static int | pg_utf8_string_len (const char *source) |
pg_saslprep_rc | pg_saslprep (const char *input, char **output) |
Variables | |
static const pg_wchar | non_ascii_space_ranges [] |
static const pg_wchar | commonly_mapped_to_nothing_ranges [] |
static const pg_wchar | prohibited_output_ranges [] |
static const pg_wchar | unassigned_codepoint_ranges [] |
static const pg_wchar | RandALCat_codepoint_ranges [] |
static const pg_wchar | LCat_codepoint_ranges [] |
Definition at line 40 of file saslprep.c.
Definition at line 41 of file saslprep.c.
#define IS_CODE_IN_TABLE | ( | code, | |
map | |||
) | is_code_in_table(code, map, lengthof(map)) |
Definition at line 966 of file saslprep.c.
#define STRDUP | ( | s | ) | pstrdup(s) |
Definition at line 39 of file saslprep.c.
|
static |
Definition at line 969 of file saslprep.c.
References a, b, sort-test::key, and range().
Referenced by is_code_in_table().
Definition at line 983 of file saslprep.c.
References Assert, and codepoint_range_cmp().
pg_saslprep_rc pg_saslprep | ( | const char * | input, |
char ** | output | ||
) |
Definition at line 1047 of file saslprep.c.
References ALLOC, Assert, buf, commonly_mapped_to_nothing_ranges, FREE, i, input, IS_CODE_IN_TABLE, LCat_codepoint_ranges, MaxAllocSize, non_ascii_space_ranges, output, pg_is_ascii(), pg_utf8_string_len(), pg_utf_mblen, prohibited_output_ranges, RandALCat_codepoint_ranges, SASLPREP_INVALID_UTF8, SASLPREP_OOM, SASLPREP_PROHIBITED, SASLPREP_SUCCESS, STRDUP, unassigned_codepoint_ranges, UNICODE_NFKC, unicode_normalize(), unicode_to_utf8(), and utf8_to_unicode().
Referenced by pg_be_scram_build_secret(), pg_fe_scram_build_secret(), scram_init(), and scram_verify_plain_password().
|
static |
Definition at line 1003 of file saslprep.c.
References len, pg_utf8_islegal(), pg_utf_mblen, and source.
Referenced by pg_saslprep().
|
static |
Definition at line 82 of file saslprep.c.
Referenced by pg_saslprep().
|
static |
Definition at line 598 of file saslprep.c.
Referenced by pg_saslprep().
|
static |
Definition at line 67 of file saslprep.c.
Referenced by pg_saslprep().
|
static |
Definition at line 117 of file saslprep.c.
Referenced by pg_saslprep().
|
static |
Definition at line 559 of file saslprep.c.
Referenced by pg_saslprep().
|
static |
Definition at line 158 of file saslprep.c.
Referenced by pg_saslprep().