|
|
|
|
@ -15445,6 +15445,7 @@ static int handle_common_options(struct ast_flags *flags, struct ast_flags *mask
|
|
|
|
|
ast_log(LOG_WARNING, "Unknown dtmf mode '%s' on line %d, using rfc2833\n", v->value, v->lineno);
|
|
|
|
|
ast_set_flag(&flags[0], SIP_DTMF_RFC2833);
|
|
|
|
|
}
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "nat")) {
|
|
|
|
|
ast_set_flag(&mask[0], SIP_NAT);
|
|
|
|
|
ast_clear_flag(&flags[0], SIP_NAT);
|
|
|
|
|
@ -15456,6 +15457,7 @@ static int handle_common_options(struct ast_flags *flags, struct ast_flags *mask
|
|
|
|
|
ast_set_flag(&flags[0], SIP_NAT_ALWAYS);
|
|
|
|
|
else
|
|
|
|
|
ast_set_flag(&flags[0], SIP_NAT_RFC3581);
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "canreinvite")) {
|
|
|
|
|
ast_set_flag(&mask[0], SIP_REINVITE);
|
|
|
|
|
ast_clear_flag(&flags[0], SIP_REINVITE);
|
|
|
|
|
@ -15477,6 +15479,7 @@ static int handle_common_options(struct ast_flags *flags, struct ast_flags *mask
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "insecure")) {
|
|
|
|
|
ast_set_flag(&mask[0], SIP_INSECURE_PORT | SIP_INSECURE_INVITE);
|
|
|
|
|
ast_clear_flag(&flags[0], SIP_INSECURE_PORT | SIP_INSECURE_INVITE);
|
|
|
|
|
@ -15495,6 +15498,7 @@ static int handle_common_options(struct ast_flags *flags, struct ast_flags *mask
|
|
|
|
|
ast_log(LOG_WARNING, "Unknown insecure mode '%s' on line %d\n", v->value, v->lineno);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "progressinband")) {
|
|
|
|
|
ast_set_flag(&mask[0], SIP_PROG_INBAND);
|
|
|
|
|
ast_clear_flag(&flags[0], SIP_PROG_INBAND);
|
|
|
|
|
@ -15502,8 +15506,7 @@ static int handle_common_options(struct ast_flags *flags, struct ast_flags *mask
|
|
|
|
|
ast_set_flag(&flags[0], SIP_PROG_INBAND_YES);
|
|
|
|
|
else if (strcasecmp(v->value, "never"))
|
|
|
|
|
ast_set_flag(&flags[0], SIP_PROG_INBAND_NO);
|
|
|
|
|
} else if (!strcasecmp(v->name, "allowguest")) {
|
|
|
|
|
global_allowguest = ast_true(v->value) ? 1 : 0;
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "promiscredir")) {
|
|
|
|
|
ast_set_flag(&mask[0], SIP_PROMISCREDIR);
|
|
|
|
|
ast_set2_flag(&flags[0], ast_true(v->value), SIP_PROMISCREDIR);
|
|
|
|
|
@ -15511,27 +15514,34 @@ static int handle_common_options(struct ast_flags *flags, struct ast_flags *mask
|
|
|
|
|
} else if (!strcasecmp(v->name, "videosupport")) {
|
|
|
|
|
ast_set_flag(&mask[1], SIP_PAGE2_VIDEOSUPPORT);
|
|
|
|
|
ast_set2_flag(&flags[1], ast_true(v->value), SIP_PAGE2_VIDEOSUPPORT);
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "allowoverlap")) {
|
|
|
|
|
ast_set_flag(&mask[1], SIP_PAGE2_ALLOWOVERLAP);
|
|
|
|
|
ast_set2_flag(&flags[1], ast_true(v->value), SIP_PAGE2_ALLOWOVERLAP);
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "allowsubscribe")) {
|
|
|
|
|
ast_set_flag(&mask[1], SIP_PAGE2_ALLOWSUBSCRIBE);
|
|
|
|
|
ast_set2_flag(&flags[1], ast_true(v->value), SIP_PAGE2_ALLOWSUBSCRIBE);
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "t38pt_udptl")) {
|
|
|
|
|
ast_set_flag(&mask[1], SIP_PAGE2_T38SUPPORT_UDPTL);
|
|
|
|
|
ast_set2_flag(&flags[1], ast_true(v->value), SIP_PAGE2_T38SUPPORT_UDPTL);
|
|
|
|
|
res = 1;
|
|
|
|
|
#ifdef WHEN_WE_HAVE_T38_FOR_OTHER_TRANSPORTS
|
|
|
|
|
} else if (!strcasecmp(v->name, "t38pt_rtp")) {
|
|
|
|
|
ast_set_flag(&mask[1], SIP_PAGE2_T38SUPPORT_RTP);
|
|
|
|
|
ast_set2_flag(&flags[1], ast_true(v->value), SIP_PAGE2_T38SUPPORT_RTP);
|
|
|
|
|
res = 1;
|
|
|
|
|
} else if (!strcasecmp(v->name, "t38pt_tcp")) {
|
|
|
|
|
ast_set_flag(&mask[1], SIP_PAGE2_T38SUPPORT_TCP);
|
|
|
|
|
ast_set2_flag(&flags[1], ast_true(v->value), SIP_PAGE2_T38SUPPORT_TCP);
|
|
|
|
|
res = 1;
|
|
|
|
|
#endif
|
|
|
|
|
} else if (!strcasecmp(v->name, "rfc2833compensate")) {
|
|
|
|
|
ast_set_flag(&mask[1], SIP_PAGE2_RFC2833_COMPENSATE);
|
|
|
|
|
ast_set2_flag(&flags[1], ast_true(v->value), SIP_PAGE2_RFC2833_COMPENSATE);
|
|
|
|
|
}
|
|
|
|
|
res = 1;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return res;
|
|
|
|
|
}
|
|
|
|
|
@ -16271,6 +16281,8 @@ static int reload_config(enum channelreloadreason reason)
|
|
|
|
|
/* Create the dialogs list */
|
|
|
|
|
if (!strcasecmp(v->name, "context")) {
|
|
|
|
|
ast_copy_string(default_context, v->value, sizeof(default_context));
|
|
|
|
|
} else if (!strcasecmp(v->name, "allowguest")) {
|
|
|
|
|
global_allowguest = ast_true(v->value) ? 1 : 0;
|
|
|
|
|
} else if (!strcasecmp(v->name, "realm")) {
|
|
|
|
|
ast_copy_string(global_realm, v->value, sizeof(global_realm));
|
|
|
|
|
} else if (!strcasecmp(v->name, "useragent")) {
|
|
|
|
|
|