Bug #5581
closedosmo_stream_srv_link_get_sockname() only supports showing 1st IP address
100%
Description
osmo_stream_cli_get_sockname API has a similar issue. osmo_stream_srv_get_sockname doesn't exist, but when adding it this ticket should be taken into account (see #5580).
The osmo_stream API allows setting up SCTP sockets, which support multihomin. The osmo_stream API already supports setting several addresses and using them. However, if an SCTP socket is setup with multiple local IP addresses, osmo_stream_cli_get_sockname() will only return the first one in the string returned. This is misleading and should be fixed.
I had to manually check /proc/net/sctp/eps to see the issue.
Related issues
Updated by pespin about 2 years ago
- Related to Feature #5580: Missing API: osmo_stream_srv_get_sockname() added
Updated by msuraev almost 2 years ago
- Status changed from New to In Progress
That's a bit tricky as we rely on getsockname() in libosmocore for socket description which is (silently!) incompatible with multi-homed SCTP. Should bedoable via sctp_getladdrs() though: see https://www.rfc-editor.org/rfc/rfc6458
Note: according to https://datatracker.ietf.org/doc/html/rfc4960 multi-homed SCTP has to use the same port number.
Updated by msuraev over 1 year ago
- Status changed from In Progress to Stalled
- % Done changed from 0 to 50
Implemented in https://gerrit.osmocom.org/c/libosmo-netif/+/29079, blocked by patches in https://gerrit.osmocom.org/q/topic:sctp_addr waiting for review
Updated by pespin 7 months ago
- Status changed from Stalled to Feedback
- % Done changed from 50 to 90
Fixed by:
https://gerrit.osmocom.org/c/libosmo-netif/+/35287 stream_srv_link: osmo_stream_srv_link_get_sockname() now returns the full ...
Once merged, the ticket can be closed.