Thank you for your input so far. All the alternatives seem to work-around the issue but not fulfill our needs.

We have debugged a little using gdb. We noticed that the value of msg->rcv->bind_address->address_str is correct before calling do_action. Afterwards, it is wrong.

Before:

s = "172.20.21.3"
len = 11

After:

s = "217.116.120.247"
len = 11 (sic!)

We took a closer look (step by step) and the problem seems to be using ip_addr2a. It returns a pointer to a local static char[]. This is assigned to the original struct of address_str inside of parsing_hepv3_message.

Later, when ip_addr2a is called again for xlog, then the same address is used again and hence the value of address_str.s is overwriten.

A quick look at the git history for the functions did not show any relevant changes to my untrained eyes.

As the jump from 5.1/5.4 (debian jessie) to 5.5/5.8 (debian bookworm) is kind of huge, maybe this is related to changes in the compiler?


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <kamailio/kamailio/issues/3835/2098758267@github.com>