int require_strong;
int with_ntdomain_hack; /* this should be in another module */
char *passwd_file;
- const char *xlat_name;
+ char *xlat_name;
char *ntlm_auth;
char *ntlm_cpw;
char *ntlm_cpw_username;
*/
static int mschap_instantiate(CONF_SECTION *conf, void **instance)
{
+ const char *name;
rlm_mschap_t *inst;
inst = *instance = rad_malloc(sizeof(*inst));
/*
* Create the dynamic translation.
*/
- inst->xlat_name = cf_section_name2(conf);
- if (!inst->xlat_name) inst->xlat_name = cf_section_name1(conf);
- inst->xlat_name = strdup(inst->xlat_name);
+ name = cf_section_name2(conf);
+ if (name) name = cf_section_name1(conf);
+ inst->xlat_name = strdup(name);
xlat_register(inst->xlat_name, mschap_xlat, inst);
/*
pid_t pid, child_pid;
int status, len;
char buf[2048];
- char *emsg;
+ char *pmsg;
+ const char *emsg;
RDEBUG("Doing MS-CHAPv2 password change via ntlm_auth helper");
return 0;
}
- emsg = strstr(buf, "Password-Change-Error: ");
- if (emsg) {
- emsg = strsep(&emsg, "\n");
+ pmsg = strstr(buf, "Password-Change-Error: ");
+ if (pmsg) {
+ emsg = strsep(&pmsg, "\n");
} else {
emsg = "could not find error";
}
VALUE_PAIR *new_pass, *new_hash;
uint8_t *p;
- int i, result_len;
- uint32_t passlen;
+ size_t i, result_len;
+ size_t passlen;
char result[253];
uint8_t nt_pass_decrypted[516], old_nt_hash_expected[16];
RC4_KEY key;