Comments (2)
@vasilakisfil thanks for your interest and sorry for a delay with the reply. The situation with the "IP" in the response is somewhat convoluted. It stems from the fact that initially both RTPProxy and control protocol had no notion of listening on a specific IP along with the fact that rtpproxy was supposed to run on the same machine as Kamailio/OpenSIPS. In this the most simplistic mode of operation the RTPproxy would use bind(INADDR_ANY) for its RTP/RTCP ports allowing call control component to pick whatever IP it deems the most appropriate.
As the time went on, it became clear that in multi-homed scenarios as well as in cases when RTPproxy is running on a separate node it needs to communicate both IP and port back to the call controller. Perhaps I will have to review this situation and see if the behavior can be collapsed to a single case somehow.
from rtpproxy.
I think I found something from Kamailio's code in rtpproxy module. If I read the code right though, I think the docs are wrong. Basically these are the cases:
- just port (like
5060
): RTPProxy keeps the same AF as the request sent (so if it's IPv4, port is also in IPv4 // if it's IPv6 port is also in IPv6). - port with IP (like
5060 127.0.0.1
): according to Kamailio, for historical reasons if RTPProxy returns a bare address (port + IP), then it is assumed that the IP address is in IPv4) - port with IP + '6' (like
5060 ::1 6
):6
here denotes that it's an IPv6.
In practice, in Rust parsing just the IP address using STD is possible to figure out if it's IPv4 or IPv6, but it's nice to have a complete documentation of what RTPProxy returns.
I am closing this ticket, but would be nice to get a confirmation from @sobomax
from rtpproxy.
Related Issues (20)
- rtpproxy briefly sends RTP from out-of-range source port and with unrelated RTP header fields before starting to properly forward HOT 4
- Difference between rtpp_weakref_obj and rtpp_hash_table HOT 1
- rtpproxy command protocol - stats - UDP stream timeout? HOT 2
- rtpp_acct_rtcp_hep - RTCP Type 203 (BYE)? HOT 2
- SIGSEGV in rtpp_wi_free HOT 2
- Play command fails HOT 7
- OSS-Fuzz issue 56543
- OSS-Fuzz issue 56764
- OSS-Fuzz issue 56786 HOT 1
- OSS-Fuzz issue 57069
- OSS-Fuzz issue 57278
- haw i can write RTCP code in c++
- OSS-Fuzz issue 59215
- What is the memory and CPU requirements for RTPProxy HOT 1
- Can't put all packets from both directions into a single file HOT 2
- OSS-Fuzz issue 59712
- Memory leak in `rtpp_cmd_rcache_insert` function HOT 1
- -Wincompatible-pointer-types configure check may fail unconditionally with future compilers
- SRTP support and 'transcoding' between encrypted and unencrypted streams
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rtpproxy.