浏览代码

nathelper: use dedicated function for testing via address against source ip

- reported by Igor Potjevlesch
- previous used functions was checking the presence of rport and
  received parameters, ending in a wrong result for nat testing

(cherry picked from commit 0b10377df11977d7ddd7e6bf30fe060d1fe200aa)
Daniel-Constantin Mierla 10 年之前
父节点
当前提交
a2832bf95b
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      modules/nathelper/nathelper.c

+ 1 - 1
modules/nathelper/nathelper.c

@@ -1556,7 +1556,7 @@ nat_uac_test_f(struct sip_msg* msg, char* str1, char* str2)
 	 * test if source address of signaling is different from
 	 * address advertised in Via
 	 */
-	if ((tests & NAT_UAC_TEST_RCVD) && received_test(msg))
+	if ((tests & NAT_UAC_TEST_RCVD) && received_via_test(msg))
 		return 1;
 	/*
 	 * test for occurrences of RFC1918 addresses in Contact