-static bool my_parse_authdata(SilcAuthMethod auth_meth, char *p, uint32 line,
- void **auth_data, uint32 *auth_data_len)
+static bool my_parse_authdata(SilcAuthMethod auth_meth, char *p, SilcUInt32 line,
+ void **auth_data, SilcUInt32 *auth_data_len)
{
if (auth_meth == SILC_AUTH_PASSWORD) {
/* p is a plain text password */
if (auth_data)
*auth_data = (void *) strdup(p);
if (auth_data_len)
{
if (auth_meth == SILC_AUTH_PASSWORD) {
/* p is a plain text password */
if (auth_data)
*auth_data = (void *) strdup(p);
if (auth_data_len)
config->require_reverse_lookup = *(bool *)val;
}
else if (!strcmp(name, "connections_max")) {
config->require_reverse_lookup = *(bool *)val;
}
else if (!strcmp(name, "connections_max")) {
}
else if (!strcmp(name, "reconnect_keep_trying")) {
config->param.reconnect_keep_trying = *(bool *)val;
}
else if (!strcmp(name, "key_exchange_rekey")) {
}
else if (!strcmp(name, "reconnect_keep_trying")) {
config->param.reconnect_keep_trying = *(bool *)val;
}
else if (!strcmp(name, "key_exchange_rekey")) {
}
else if (!strcmp(name, "key_exchange_pfs")) {
config->param.key_exchange_pfs = *(bool *)val;
}
else if (!strcmp(name, "channel_rekey_secs")) {
}
else if (!strcmp(name, "key_exchange_pfs")) {
config->param.key_exchange_pfs = *(bool *)val;
}
else if (!strcmp(name, "channel_rekey_secs")) {
tmp->module = (*(char *)val ? strdup((char *) val) : NULL);
}
else if (!strcmp(name, "keylength")) {
tmp->module = (*(char *)val ? strdup((char *) val) : NULL);
}
else if (!strcmp(name, "keylength")) {
fprintf(stderr, "Invalid port number!\n");
return SILC_CONFIG_ESILENT;
}
fprintf(stderr, "Invalid port number!\n");
return SILC_CONFIG_ESILENT;
}
}
else if (!strcmp(name, "servertype")) {
CONFIG_IS_DOUBLE(server_info->server_type);
}
else if (!strcmp(name, "servertype")) {
CONFIG_IS_DOUBLE(server_info->server_type);
config->tmp = silc_calloc(1, sizeof(*tmp));
tmp = (SilcServerConfigLogging *) config->tmp;
}
config->tmp = silc_calloc(1, sizeof(*tmp));
tmp = (SilcServerConfigLogging *) config->tmp;
}
tmp->name = (*(char *)val ? strdup((char *) val) : NULL);
}
else if (!strcmp(name, "connections_max")) {
tmp->name = (*(char *)val ? strdup((char *) val) : NULL);
}
else if (!strcmp(name, "connections_max")) {
}
else if (!strcmp(name, "reconnect_keep_trying")) {
tmp->reconnect_keep_trying = *(bool *)val;
}
else if (!strcmp(name, "key_exchange_rekey")) {
}
else if (!strcmp(name, "reconnect_keep_trying")) {
tmp->reconnect_keep_trying = *(bool *)val;
}
else if (!strcmp(name, "key_exchange_rekey")) {
}
else if (!strcmp(name, "key_exchange_pfs")) {
tmp->key_exchange_pfs = *(bool *)val;
}
else if (!strcmp(name, "key_exchange_pfs")) {
tmp->key_exchange_pfs = *(bool *)val;
fprintf(stderr, "Invalid port number!\n");
return SILC_CONFIG_ESILENT;
}
fprintf(stderr, "Invalid port number!\n");
return SILC_CONFIG_ESILENT;
}
}
else if (!strcmp(name, "passphrase")) {
if (!my_parse_authdata(SILC_AUTH_PASSWORD, (char *) val, line,
}
else if (!strcmp(name, "passphrase")) {
if (!my_parse_authdata(SILC_AUTH_PASSWORD, (char *) val, line,
fprintf(stderr, "Invalid port number!\n");
return SILC_CONFIG_ESILENT;
}
fprintf(stderr, "Invalid port number!\n");
return SILC_CONFIG_ESILENT;
}
}
else if (!strcmp(name, "backuplocal")) {
tmp->backup_local = *(bool *)val;
}
else if (!strcmp(name, "backuplocal")) {
tmp->backup_local = *(bool *)val;
/* handle this special error return which asks to quietly return */
if (ret != SILC_CONFIG_ESILENT) {
char *linebuf, *filename = silc_config_get_filename(file);
/* handle this special error return which asks to quietly return */
if (ret != SILC_CONFIG_ESILENT) {
char *linebuf, *filename = silc_config_get_filename(file);
fprintf(stderr, "\nError while parsing config file: %s.\n",
silc_config_strerror(ret));
linebuf = silc_config_read_line(file, line);
fprintf(stderr, "\nError while parsing config file: %s.\n",
silc_config_strerror(ret));
linebuf = silc_config_read_line(file, line);