master-settings.c revision 3bc1d0e7556a072b492cfc8c0c2496fe3935a8dc
2670cd577aa57eb9f915a4f4220ae48c9b4fc5fbTimo Sirainen/* Copyright (c) 2002-2007 Dovecot authors, see the included COPYING file */
2670cd577aa57eb9f915a4f4220ae48c9b4fc5fbTimo Sirainen#define DEF_STR(name) DEF_STRUCT_STR(name, auth_settings)
15ab2452b0220a115f4351ad9d7fd5ec70ae7966Timo Sirainen#define DEF_INT(name) DEF_STRUCT_INT(name, auth_settings)
2670cd577aa57eb9f915a4f4220ae48c9b4fc5fbTimo Sirainen#define DEF_BOOL(name) DEF_STRUCT_BOOL(name, auth_settings)
b6b9c99fefbbc662bd9a0006566133c4480bf0e8Timo Sirainenstatic struct setting_def auth_setting_defs[] = {
e4194f4703eeec32b432371ae30fc8f25ab720d8Timo Sirainen#define DEF_STR(name) DEF_STRUCT_STR(name, socket_settings)
e4194f4703eeec32b432371ae30fc8f25ab720d8Timo Sirainen#define DEF_INT(name) DEF_STRUCT_INT(name, socket_settings)
e4194f4703eeec32b432371ae30fc8f25ab720d8Timo Sirainen#define DEF_BOOL(name) DEF_STRUCT_BOOL(name, socket_settings)
e4194f4703eeec32b432371ae30fc8f25ab720d8Timo Sirainenstatic struct setting_def socket_setting_defs[] = {
5e9bb72de1209cd39fdf3e95bdb26e047cc5594eTimo Sirainenstatic struct setting_def auth_socket_setting_defs[] = {
15ab2452b0220a115f4351ad9d7fd5ec70ae7966Timo Sirainen#define DEF_STR(name) DEF_STRUCT_STR(name, auth_passdb_settings)
15ab2452b0220a115f4351ad9d7fd5ec70ae7966Timo Sirainen#define DEF_INT(name) DEF_STRUCT_INT(name, auth_passdb_settings)
15ab2452b0220a115f4351ad9d7fd5ec70ae7966Timo Sirainen#define DEF_BOOL(name) DEF_STRUCT_BOOL(name, auth_passdb_settings)
15ab2452b0220a115f4351ad9d7fd5ec70ae7966Timo Sirainenstatic struct setting_def auth_passdb_setting_defs[] = {
e4194f4703eeec32b432371ae30fc8f25ab720d8Timo Sirainenstatic struct setting_def auth_userdb_setting_defs[] = {
{ 0, NULL, 0 }
#ifdef MMAP_CONFLICTS_WRITE
return TRUE;
return FALSE;
return TRUE;
return TRUE;
return FALSE;
return TRUE;
return FALSE;
return FALSE;
return TRUE;
struct auth_socket_settings *s;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return TRUE;
const char *name;
name);
return FALSE;
return TRUE;
char *str, *p;
if (p == NULL)
return str;
return TRUE;
return FALSE;
return FALSE;
return TRUE;
return TRUE;
return FALSE;
unsigned int prefix_len;
#ifdef HAVE_MODULES
static const char *args[] = {
unsigned int pos;
return TRUE;
if (uid != 0) {
return FALSE;
return FALSE;
alarm(0);
if (status != 0) {
status);
return FALSE;
pos = 0;
if (ret < 0) {
return FALSE;
return FALSE;
return TRUE;
const char *dir;
int facility;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
dir);
return FALSE;
return FALSE;
#ifdef HAVE_SSL
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
#ifdef HAVE_MODULES
return FALSE;
return FALSE;
return TRUE;
return FALSE;
return FALSE;
return FALSE;
#ifdef HAVE_MODULES
return FALSE;
return TRUE;
if (nochecks)
return TRUE;
return FALSE;
int fd;
if (ret <= 0) {
if (ret == 0)
ret--;
ret = 0;
return ret;
static struct auth_settings *
return auth;
static struct auth_settings *
const char **errormsg)
return NULL;
return NULL;
static struct auth_passdb_settings *
return as;
static struct auth_userdb_settings *
return as;
static struct auth_socket_settings *
return as;
static struct auth_socket_settings *
const char **errormsg)
return NULL;
return NULL;
static struct namespace_settings *
return ns;
static struct namespace_settings *
const char **errormsg)
return NULL;
const char *error;
return NULL;
case SETTINGS_TYPE_ROOT:
case SETTINGS_TYPE_SERVER:
return NULL;
return error;
case SETTINGS_TYPE_AUTH:
case SETTINGS_TYPE_NAMESPACE:
case SETTINGS_TYPE_SOCKET:
case SETTINGS_TYPE_DICT:
return NULL;
case SETTINGS_TYPE_PLUGIN:
return NULL;
i_unreached();
static struct server_settings *
return server;
return TRUE;
return FALSE;
return TRUE;
return FALSE;
return FALSE;
return TRUE;
return FALSE;
return TRUE;
return TRUE;
return TRUE;
return TRUE;
return FALSE;
errormsg);
return FALSE;
return TRUE;
return FALSE;
return TRUE;
return FALSE;
#ifdef HAVE_SETRLIMIT
unsigned int fd_count = 0;
return FALSE;
return FALSE;
return FALSE;
return FALSE;
nofixes))
return FALSE;
return FALSE;
return FALSE;
return FALSE;
if (!nochecks) {
return FALSE;
return FALSE;
return FALSE;
if (!nochecks)
return TRUE;
const char **str;
case SET_STR: {
const char *const *strp;
for (i = 0; i < count; i++) {
case SET_INT: {
for (i = 0; i < count; i++) {
case SET_BOOL: {
for (i = 0; i < count; i++) {
if (same) {
for (i = 0; i < indent; i++)
for (i = 0; i < indent; i++)
const void *empty_defaults;
sizeof(struct auth_userdb_settings) +
sizeof(struct auth_socket_settings));
const char *const *envs;
unsigned int i, count;
if (count == 0)
const char *const *dicts;
unsigned int i, count;
if (count == 0)
unsigned int count;
count++;
count++;
void master_settings_init(void)
void master_settings_deinit(void)