A simple change, which allows to check, if a coming request matches not only by an IP address and a transport protocol, but also using the source port of a request.
Improvements are done for the following functions of the lcr module: - from_any_gw() - from_gw()
Back compatibility provided, hence it does not affect already existing behavior. You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2832
-- Commit Summary --
* lcr: source port check for from_any_gw() and from_gw().
-- File Changes --
M src/modules/lcr/doc/lcr_admin.xml (31) M src/modules/lcr/lcr_mod.c (116)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2832.patch https://github.com/kamailio/kamailio/pull/2832.diff
This pull request **introduces 2 alerts** when merging 14e6fc80b3d2389567c73c4a2196bf8e6d92d8d2 into 5ad81a45bb28ca419d9285cc59816db0fa1afefd - [view on LGTM.com](https://lgtm.com/projects/g/kamailio/kamailio/rev/pr-44137a6742f3d77205026dc...)
**new alerts:**
* 2 for Comparison result is always the same
Thanks for the pull request. There are two alerts mentioned above (check for < 0 for an unsigned int is obviously not necessary), please have a look to it. After fixing you can push to the branch, no need for a new pull request.
@zenichev pushed 1 commit.
d8583d6ce1748c1ac8494616fced507b01dd4375 lcr: remove excessive checks for the 'src_port' accuracy
I haven't tested the new feature, but from backwards compatibility point of view, the implementation looks good to me. Thus I have nothing against the merge.
Merged #2832 into master.