version 1.1.1.3, 2013/07/22 10:46:11
|
version 1.1.1.4, 2013/10/14 07:56:33
|
Line 49
|
Line 49
|
|
|
#include "missing.h" |
#include "missing.h" |
#include "alloc.h" |
#include "alloc.h" |
#include "error.h" | #include "fatal.h" |
#include "fileops.h" |
#include "fileops.h" |
#include "pathnames.h" |
#include "pathnames.h" |
#include "sudo_plugin.h" |
#include "sudo_plugin.h" |
Line 110 static struct sudo_conf_data {
|
Line 110 static struct sudo_conf_data {
|
int group_source; |
int group_source; |
int max_groups; |
int max_groups; |
const char *debug_flags; |
const char *debug_flags; |
struct sudo_conf_paths paths[4]; | struct sudo_conf_paths paths[5]; |
struct plugin_info_list plugins; |
struct plugin_info_list plugins; |
} sudo_conf_data = { |
} sudo_conf_data = { |
true, |
true, |
Line 126 static struct sudo_conf_data {
|
Line 126 static struct sudo_conf_data {
|
#define SUDO_CONF_NOEXEC_IDX 2 |
#define SUDO_CONF_NOEXEC_IDX 2 |
{ "noexec", sizeof("noexec") - 1, _PATH_SUDO_NOEXEC }, |
{ "noexec", sizeof("noexec") - 1, _PATH_SUDO_NOEXEC }, |
#endif |
#endif |
|
#ifdef _PATH_SUDO_PLUGIN_DIR |
|
#define SUDO_CONF_PLUGIN_IDX 3 |
|
{ "plugin", sizeof("plugin") - 1, _PATH_SUDO_PLUGIN_DIR }, |
|
#endif |
{ NULL } |
{ NULL } |
} |
} |
}; |
}; |
Line 181 set_var_max_groups(const char *entry, const char *conf
|
Line 185 set_var_max_groups(const char *entry, const char *conf
|
char *ep; |
char *ep; |
|
|
lval = strtol(entry, &ep, 10); |
lval = strtol(entry, &ep, 10); |
if (*entry == '\0' || *ep != '\0' || lval < 0 || lval > INT_MAX || | if (*entry == '\0' || *ep != '\0' || lval <= 0 || lval > INT_MAX || |
(errno == ERANGE && lval == LONG_MAX)) { |
(errno == ERANGE && lval == LONG_MAX)) { |
warningx(_("invalid max groups `%s' in %s, line %d"), entry, |
warningx(_("invalid max groups `%s' in %s, line %d"), entry, |
conf_file, conf_lineno); |
conf_file, conf_lineno); |
Line 321 const char *
|
Line 325 const char *
|
sudo_conf_noexec_path(void) |
sudo_conf_noexec_path(void) |
{ |
{ |
return sudo_conf_data.paths[SUDO_CONF_NOEXEC_IDX].pval; |
return sudo_conf_data.paths[SUDO_CONF_NOEXEC_IDX].pval; |
|
} |
|
#endif |
|
|
|
#ifdef _PATH_SUDO_PLUGIN_DIR |
|
const char * |
|
sudo_conf_plugin_dir_path(void) |
|
{ |
|
return sudo_conf_data.paths[SUDO_CONF_PLUGIN_IDX].pval; |
} |
} |
#endif |
#endif |
|
|