New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rtpengine module added receive-from option to flags to managing rtpengine by a kamailio node behind dispatcher #3230
Conversation
Add receive-from option to flags receive-from=1.2.3.4 required for manageing rtpengine by a kamailio node behind a dispatcher kamailio node
bugfix in line ip_af == AF_INET6
|
Hi, From looking at the code, I'm not sure this is correct? In case of |
ng_flags-> recive_flags is set in the funtion in line number 2279 as
|
Bugfix initialize ng_flags.received-from = bencode_list(bencbuf);
Thank you I have fixed it by adding |
src/modules/rtpengine/rtpengine.c
Outdated
@@ -2529,6 +2551,7 @@ static bencode_item_t *rtpp_function_call(bencode_buffer_t *bencbuf, struct sip_ | |||
|
|||
body.s = NULL; | |||
ng_flags.flags = bencode_list(bencbuf); | |||
ng_flags.received-from = bencode_list(bencbuf); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo here (dash instead of underscore). Maybe at least try to compile it before submitting?
src/modules/rtpengine/rtpengine.c
Outdated
bencode_dictionary_add(ng_flags.dict, "received-from", ng_flags.received_from); | ||
} | ||
else { | ||
item = bencode_list(bencbuf); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a suggestion, but you could reuse ng_flags.received_from
here instead of creating a new list item. But up to you.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reuse of ng_flags.received_from done
fixed ng_flags.received-from = bencode_list(bencbuf); to ng_flags.received_from = bencode_list(bencbuf);
complied and verified. Thank you for your support.
Fixed bug ng_flags.received-from = bencode_list(bencbuf); to ng_flags.received_from = bencode_list(bencbuf); removed the double declaration bencode_list(bencbuf) for received_from when "received-from " is not given in flags by user.
Added received-from=IP in document
ADD received-from option in Document
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM now. @miconda I can squash and merge this if you want.
@rfuchs: ok, go ahead! And thanks for looking into it! |
Add receive-from option to flags
receive-from=1.2.3.4
required for managing rtpengine by a kamailio node behind a dispatcher
kamailio node
In this scenario when the Kamailio behind the Dispatcher will be getting the $Ri as dispatcher IP and by default that will be passed to RTP Engine for NAT negotiation which will fail.
In this pull merge requst, RTP engine module a new flag is added receive-from=IP which is supposed to be the received IP from the First node through P-Accessnetwork-Info header or the contact recived tag etc..
Pre-Submission Checklist
in
doc/
subfolder, the README file is autogenerated)Type Of Change
Checklist:
Description