add support for NDLB-force-rport=safe param that does force-rport behavior only on endpoints we know are safe to do so on. This is a dirty hack to try to work with certain endpoints behind sonicwall which does not use the same port when it does nat, when the devices do not support rport, while not breaking devices that acutally use different ports that force-rport will break

This commit is contained in:
Michael Jerris committed 2010-11-03 11:53:39 -04:00
1 parent 4706d3946d
commit fc4d290cb7
3 files changed
+11 -5

No files matched your search

+6 -2
View File
@@ -2414,7 +2414,9 @@ switch_status_t reconfig_sofia(sofia_profile_t *profile)
profile->dtmf_type = DTMF_NONE;
}
} else if (!strcasecmp(var, "NDLB-force-rport")) {
if (switch_true(val)) {
if (val && !strcasecmp(val, "safe")) {
profile->rport_level = 3;
} else if (switch_true(val)) {
profile->rport_level = 2;
}
} else if (!strcasecmp(var, "caller-id-type")) {
@@ -3083,7 +3085,9 @@ switch_status_t config_sofia(int reload, char *profile_name)
profile->dtmf_type = DTMF_NONE;
}
} else if (!strcasecmp(var, "NDLB-force-rport")) {
if (switch_true(val)) {
if (val && !strcasecmp(val, "safe")) {
profile->rport_level = 3;
} else if (switch_true(val)) {
profile->rport_level = 2;
}
} else if (!strcasecmp(var, "auto-rtp-bugs")) {