**Description**
We use below config to test the topology hiding function,when kamailio receive “update”
message,doesn't send out,it will send to itself with destination port 5060;
Sorry for raising this question again,I really don’t know what parameters need to be
configured。And after I modified some codes, it could succeed probabilistically...
Sorry again, excuse me
**Troubleshooting**
```
loadmodule "ndb_redis.so"
loadmodule "topos_redis.so"
loadmodule "topos.so"
modparam("ndb_redis", "server",
"name=srv8;addr=127.0.0.1;port=6381;db=2")
modparam("topos", "storage", "redis")
modparam("topos", "db_url", "redis://127.0.0.1:6381/2")
modparam("topos_redis", "serverid", "srv8")
...Omit the configuration in the middle...
route[WITHINDLG] {
if (has_totag()) {
# sequential request withing a dialog should
# take the path determined by record-routing
xlog("L_INFO","yang yangyang testin to not here");
if (loose_route()){
if(is_method("INFO")){
route("INFO_SELF");
}
route(BYE);
route(REINVITE);
route(ACK);
route(RELAY);
} else {
if ( is_method("ACK")) {
if ( t_check_trans() ) {
# no loose-route, but stateful ACK;
# must be an ACK after a 487
# or e.g. 404 $var(obj) =
$sht(call_objects=>$ci);
xlog("L_INFO","Call $ci: ACK
received in A-Leg, $fU@$si:$sp -----> $rU@$Ri:$Rp relaying
downstreamrouteWITHINDLG\n");
t_relay();
exit;
} else {
exit;
}
}
xlog("L_INFO","yang in to not here");
sl_send_reply("404","Not here");
}
exit;
}
}
```
--------
Call flow
```
UE-----------------PROXY-------------B2bua
invite-------------->|------------------>invite
183<----------------|<------------------183
Prack------------ ->|------------------>Prack
200ok<-------------|<-----------------200ok
update1---------->|
|update2<-----------|
| 404 not here-------> |
````
**Additional Information**
```
version: kamailio master (x86_64/linux)
```
### Possible Solutions
I set the log level to debug, and the comparison found that the logic of prack and update
is different。After checking the code of topos, it is found that
kamailio/src/modules/topos/tps_msg.c has a separate processing for prack.according to
commit
[
37830f5](https://github.com/kamailio/kamailio/commit/37830f53b1f21fba5beef5…
So I added update to the prack processing method,Later I found that when the B-side update
message comes, it should follow the original logic。
So I distinguish whether to follow the modified logic according to ONREPLY_ROUTE。
But after probabilistic success,The problem is that the value returned by get_route_type()
is sometimes 1 and sometimes 4
Call flow after modification:
```
UE-----------------PROXY-------------B2bua
invite-------------->|------------------>invite
183<----------------|<------------------183
Prack------------ ->|------------------>Prack
200ok<-------------|<-----------------200ok
update1---------->|----------------->|update
200ok<-------------|<-----------------200ok
|<-----------------|update2
| 404 not here---------> |
````
Here is the code I modified:
/src/modules/topos/tps_msg.c
![image](https://user-images.githubusercontent.com/16113837/109925737-107b0580-7cfd-11eb-9eaf-7a66ba224b55.png)
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/2659