On 12-11 22:55, Richard wrote:
Hi,
We have some SIP UAs behind NAT. It is capable of sending NOTIFY messages to
keep NAT binding fresh. I am thinking about two setups and would like to
know which one has less hit on ser's performance.
. Register with ser every 150 seconds, assume that most NAT udp binding is
180 seconds.
. Send Notify every 50 seconds, the NOTIFY includes the authentication nonce
from REGISTER message. So ser can verify that the message is real and send a
200 OK back.
Your option is appreciated.
Since the purpose of NOTIFY messages is just to get some reply from
SER and keep the NAT bindings open, I would recommend to put a simple
test at the beginning of the configuration file and send 200 OK
immediately, something like:
if (method == "NOTIFY" && <some test here>) {
sl_send_reply("200", "OK");
break;
};
Note that you have to replace <some test here> with something that
tests if this is one of the NOTIFYs keeping the NAT open, you could
probably test for some particular value in the Request-URI, or
something like that. You probably do not want to reply all NOTIFY
messages this way.
Jan.