Module: kamailio
Branch: master
Commit: e3ec71b45181c2413b4aba4e2ea5e1b371a6da56
URL:
https://github.com/kamailio/kamailio/commit/e3ec71b45181c2413b4aba4e2ea5e1b…
Author: Konstantin <piligrim_pk(a)mail.ru>
Committer: GitHub <noreply(a)github.com>
Date: 2020-10-14T11:22:20+02:00
registrar: added option to store advertised address in socket field (#2498)
* registrar: added new parameter sock_addr
- override socket address on which the register request was received
- default is NULL - store local socket address
- usefull when kamailio is behind NAT and it is necessary to store public instead private
address
* registrar: replaced dynamically allocated var with static var
Made refactoring of proposed solution.
* registrar: socket field in location db will be initialized by advertise address from
listen parameter
According to code review recommendations I changed my solution - removed new config file
parameter and
use advertise address from listen parameter to initialized received socket which is
written to
location db inside registration record.
* registrar: added additional check socket bind_address for null
* registrar: introduced config parameter to enable/disable socket advertised address
feature
---
Modified: src/modules/registrar/doc/registrar_admin.xml
Modified: src/modules/registrar/registrar.c
Modified: src/modules/registrar/registrar.h
Modified: src/modules/registrar/save.c
---
Diff:
https://github.com/kamailio/kamailio/commit/e3ec71b45181c2413b4aba4e2ea5e1b…
Patch:
https://github.com/kamailio/kamailio/commit/e3ec71b45181c2413b4aba4e2ea5e1b…