lists.osmocom.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

gerrit-log

Thread Start a new thread
Download
Threads by month
  • ----- 2026 -----
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
gerrit-log@lists.osmocom.org

October 2022

  • 2 participants
  • 2331 discussions
Change in libosmocore[master]: socket.h: Reorder sockaddr APIs to have them all together
by pespin 04 Oct '22

04 Oct '22
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/29585 ) Change subject: socket.h: Reorder sockaddr APIs to have them all together ...................................................................... socket.h: Reorder sockaddr APIs to have them all together Change-Id: Iab2ee2854be8027ee5978e06a83248b530a39bf7 --- M include/osmocom/core/socket.h 1 file changed, 25 insertions(+), 25 deletions(-) git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/85/29585/1 diff --git a/include/osmocom/core/socket.h b/include/osmocom/core/socket.h index 183220d..79de6c5 100644 --- a/include/osmocom/core/socket.h +++ b/include/osmocom/core/socket.h @@ -30,6 +30,31 @@ } u; }; +int osmo_sockaddr_is_local(struct sockaddr *addr, unsigned int addrlen); + +unsigned int osmo_sockaddr_to_str_and_uint(char *addr, unsigned int addr_len, uint16_t *port, + const struct sockaddr *sa); +size_t osmo_sockaddr_in_to_str_and_uint(char *addr, unsigned int addr_len, uint16_t *port, + const struct sockaddr_in *sin); + +const char *osmo_sockaddr_ntop(const struct sockaddr *sa, char *dst); +uint16_t osmo_sockaddr_port(const struct sockaddr *sa); +void osmo_sockaddr_set_port(struct sockaddr *sa, uint16_t port); + +int osmo_sockaddr_local_ip(struct osmo_sockaddr *local_ip, + const struct osmo_sockaddr *remote_ip); +int osmo_sockaddr_cmp(const struct osmo_sockaddr *a, + const struct osmo_sockaddr *b); + +int osmo_sockaddr_to_octets(uint8_t *dst, size_t dst_maxlen, const struct osmo_sockaddr *os); +int osmo_sockaddr_from_octets(struct osmo_sockaddr *os, const void *src, size_t src_len); + +const char *osmo_sockaddr_to_str(const struct osmo_sockaddr *sockaddr); +char *osmo_sockaddr_to_str_buf(char *buf, size_t buf_len, + const struct osmo_sockaddr *sockaddr); +int osmo_sockaddr_to_str_buf2(char *buf, size_t buf_len, const struct osmo_sockaddr *sockaddr); +char *osmo_sockaddr_to_str_c(void *ctx, const struct osmo_sockaddr *sockaddr); + /* flags for osmo_sock_init. */ /*! connect the socket to a remote peer */ #define OSMO_SOCK_F_CONNECT (1 << 0) @@ -87,17 +112,6 @@ int osmo_sock_init_sa(struct sockaddr *ss, uint16_t type, uint8_t proto, unsigned int flags); -int osmo_sockaddr_is_local(struct sockaddr *addr, unsigned int addrlen); - -unsigned int osmo_sockaddr_to_str_and_uint(char *addr, unsigned int addr_len, uint16_t *port, - const struct sockaddr *sa); -size_t osmo_sockaddr_in_to_str_and_uint(char *addr, unsigned int addr_len, uint16_t *port, - const struct sockaddr_in *sin); - -const char *osmo_sockaddr_ntop(const struct sockaddr *sa, char *dst); -uint16_t osmo_sockaddr_port(const struct sockaddr *sa); -void osmo_sockaddr_set_port(struct sockaddr *sa, uint16_t port); - int osmo_sock_unix_init(uint16_t type, uint8_t proto, const char *socket_path, unsigned int flags); @@ -123,20 +137,6 @@ int osmo_sock_local_ip(char *local_ip, const char *remote_ip); -int osmo_sockaddr_local_ip(struct osmo_sockaddr *local_ip, - const struct osmo_sockaddr *remote_ip); -int osmo_sockaddr_cmp(const struct osmo_sockaddr *a, - const struct osmo_sockaddr *b); - -int osmo_sockaddr_to_octets(uint8_t *dst, size_t dst_maxlen, const struct osmo_sockaddr *os); -int osmo_sockaddr_from_octets(struct osmo_sockaddr *os, const void *src, size_t src_len); - -const char *osmo_sockaddr_to_str(const struct osmo_sockaddr *sockaddr); -char *osmo_sockaddr_to_str_buf(char *buf, size_t buf_len, - const struct osmo_sockaddr *sockaddr); -int osmo_sockaddr_to_str_buf2(char *buf, size_t buf_len, const struct osmo_sockaddr *sockaddr); -char *osmo_sockaddr_to_str_c(void *ctx, const struct osmo_sockaddr *sockaddr); - int osmo_sock_set_dscp(int fd, uint8_t dscp); int osmo_sock_set_priority(int fd, int prio); -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/29585 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: Iab2ee2854be8027ee5978e06a83248b530a39bf7 Gerrit-Change-Number: 29585 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
Change in osmo-mgw[master]: send_dummy: Use proper condition to test if conn is osmux
by osmith 04 Oct '22

04 Oct '22
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29583 ) Change subject: send_dummy: Use proper condition to test if conn is osmux ...................................................................... Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29583 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: I493e7afaf8e6edb5bf975b3097fab49986d064cf Gerrit-Change-Number: 29583 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 04 Oct 2022 10:38:02 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-mgw[master]: osmux: Log remote address upon rx of osmux pkt
by osmith 04 Oct '22

04 Oct '22
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29570 ) Change subject: osmux: Log remote address upon rx of osmux pkt ...................................................................... Patch Set 1: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29570 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: Ie2a375711c7c0989161ae651ea6f0695799e2670 Gerrit-Change-Number: 29570 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 04 Oct 2022 10:37:25 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-mgw[master]: osmux: Fill in from_addr in struct osmo_rtp_msg_ctx
by osmith 04 Oct '22

04 Oct '22
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29567 ) Change subject: osmux: Fill in from_addr in struct osmo_rtp_msg_ctx ...................................................................... Patch Set 4: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29567 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: I9783978e295b964ca914f8d90d73effa8785f10d Gerrit-Change-Number: 29567 Gerrit-PatchSet: 4 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 04 Oct 2022 10:35:53 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-mgw[master]: osmux: Match remote address in osmux_conn_lookup()
by osmith 04 Oct '22

04 Oct '22
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29565 ) Change subject: osmux: Match remote address in osmux_conn_lookup() ...................................................................... Patch Set 4: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29565 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: Ia717efa5f68e9412b86ef44a4c42a0715ff0e469 Gerrit-Change-Number: 29565 Gerrit-PatchSet: 4 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 04 Oct 2022 10:35:18 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-mgw[master]: osmux: Unify rtp_conn osmux type into a single type
by osmith 04 Oct '22

04 Oct '22
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29568 ) Change subject: osmux: Unify rtp_conn osmux type into a single type ...................................................................... Patch Set 2: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29568 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: I65effeddf033eb1955553e8d659c593b4e67f7bc Gerrit-Change-Number: 29568 Gerrit-PatchSet: 2 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 04 Oct 2022 10:32:33 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-mgw[master]: osmux: cleanup misleading code calling rtp_bridge_cb
by osmith 04 Oct '22

04 Oct '22
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29566 ) Change subject: osmux: cleanup misleading code calling rtp_bridge_cb ...................................................................... Patch Set 3: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29566 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: I42d1f2e2919eae3b1555ca4929e571855960792e Gerrit-Change-Number: 29566 Gerrit-PatchSet: 3 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 04 Oct 2022 10:31:12 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
Change in osmo-mgw[master]: Fix regression in detection of legacy dummy packets
by pespin 04 Oct '22

04 Oct '22
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29584 ) Change subject: Fix regression in detection of legacy dummy packets ...................................................................... Fix regression in detection of legacy dummy packets A commit refactored this code around one year ago, which broke osmux detection of dummy messages. This commit partially reverts the earlier commit and rearranges the existing code to make it more robust. Fixes: b3d14eb552cba1c58970acf90dae1bee291d5293 Change-Id: Iedf085932c45af5d13e04e56a4cd1082de81d869 --- M include/osmocom/mgcp/mgcp_network.h M src/libosmo-mgcp/mgcp_osmux.c 2 files changed, 9 insertions(+), 24 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-mgw refs/changes/84/29584/1 diff --git a/include/osmocom/mgcp/mgcp_network.h b/include/osmocom/mgcp/mgcp_network.h index 5668711..854c92d 100644 --- a/include/osmocom/mgcp/mgcp_network.h +++ b/include/osmocom/mgcp/mgcp_network.h @@ -9,7 +9,8 @@ /* The following constant defines an RTP dummy payload that is used for * "UDP Hole Punching" (NAT) */ -static const char rtp_dummy_payload[] = { 0x23 }; +#define MGCP_DUMMY_LOAD 0x23 +static const char rtp_dummy_payload[] = { MGCP_DUMMY_LOAD }; /* Check if the data in a given message buffer matches the rtp dummy payload * defined above */ diff --git a/src/libosmo-mgcp/mgcp_osmux.c b/src/libosmo-mgcp/mgcp_osmux.c index aae9579..23e4dad 100644 --- a/src/libosmo-mgcp/mgcp_osmux.c +++ b/src/libosmo-mgcp/mgcp_osmux.c @@ -363,30 +363,14 @@ } } -static int osmux_legacy_dummy_parse_cid(const struct osmo_sockaddr *rem_addr, struct msgb *msg, - uint8_t *osmux_cid) -{ - if (msg->len < 1 + sizeof(*osmux_cid)) { - LOGP(DOSMUX, LOGL_ERROR, - "Discarding truncated Osmux dummy load: %s\n", osmo_hexdump(msg->data, msg->len)); - return -1; - } - - /* extract the osmux CID from the dummy message */ - memcpy(osmux_cid, &msg->data[1], sizeof(*osmux_cid)); - return 0; -} - -/* This is called from the bsc-nat */ -static int osmux_handle_dummy(struct mgcp_trunk *trunk, const struct osmo_sockaddr *rem_addr, +/* Old versions of osmux used to send dummy packets [0x23 0x<CID>] to punch the + * hole in the NAT. Let's handle them speficially. */ +static int osmux_handle_legacy_dummy(struct mgcp_trunk *trunk, const struct osmo_sockaddr *rem_addr, struct msgb *msg) { - uint8_t osmux_cid; + uint8_t osmux_cid = msg->data[1]; struct mgcp_conn_rtp *conn; - if (osmux_legacy_dummy_parse_cid(rem_addr, msg, &osmux_cid) < 0) - goto out; - conn = osmux_conn_lookup(trunk, osmux_cid, rem_addr); if (!conn) { LOGP(DOSMUX, LOGL_DEBUG, @@ -426,9 +410,9 @@ goto out; } - /* not any further processing dummy messages */ - if (mgcp_is_rtp_dummy_payload(msg)) - return osmux_handle_dummy(trunk, &rem_addr, msg); + /* Catch legacy dummy message and process them separately: */ + if (msg->len == 2 && msg->data[0] == MGCP_DUMMY_LOAD) + return osmux_handle_legacy_dummy(trunk, &rem_addr, msg); rem = msg->len; while((osmuxh = osmux_xfrm_output_pull(msg)) != NULL) { -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29584 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: Iedf085932c45af5d13e04e56a4cd1082de81d869 Gerrit-Change-Number: 29584 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
Change in osmo-mgw[master]: send_dummy: Use proper condition to test if conn is osmux
by pespin 04 Oct '22

04 Oct '22
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29583 ) Change subject: send_dummy: Use proper condition to test if conn is osmux ...................................................................... send_dummy: Use proper condition to test if conn is osmux Change-Id: I493e7afaf8e6edb5bf975b3097fab49986d064cf --- M src/libosmo-mgcp/mgcp_protocol.c 1 file changed, 1 insertion(+), 1 deletion(-) git pull ssh://gerrit.osmocom.org:29418/osmo-mgw refs/changes/83/29583/1 diff --git a/src/libosmo-mgcp/mgcp_protocol.c b/src/libosmo-mgcp/mgcp_protocol.c index 79fbc53..5493917 100644 --- a/src/libosmo-mgcp/mgcp_protocol.c +++ b/src/libosmo-mgcp/mgcp_protocol.c @@ -323,7 +323,7 @@ * osmux connection, send the dummy packet via OSMUX */ static void send_dummy(struct mgcp_endpoint *endp, struct mgcp_conn_rtp *conn) { - if (conn->osmux.state != OSMUX_STATE_DISABLED) + if (mgcp_conn_rtp_is_osmux(conn)) osmux_send_dummy(endp, conn); else mgcp_send_dummy(endp, conn); -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29583 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: I493e7afaf8e6edb5bf975b3097fab49986d064cf Gerrit-Change-Number: 29583 Gerrit-PatchSet: 1 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-MessageType: newchange
1 0
0 0
Change in osmo-mgw[master]: osmux: Drop logging of osmux internal counters
by osmith 04 Oct '22

04 Oct '22
Attention is currently required from: pespin. osmith has posted comments on this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/29531 ) Change subject: osmux: Drop logging of osmux internal counters ...................................................................... Patch Set 2: Code-Review+1 -- To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/29531 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-mgw Gerrit-Branch: master Gerrit-Change-Id: I853e118f843070ea29b19e1b0fe56b52f267437a Gerrit-Change-Number: 29531 Gerrit-PatchSet: 2 Gerrit-Owner: pespin <pespin(a)sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge(a)osmocom.org> Gerrit-Reviewer: osmith <osmith(a)sysmocom.de> Gerrit-Attention: pespin <pespin(a)sysmocom.de> Gerrit-Comment-Date: Tue, 04 Oct 2022 10:04:38 +0000 Gerrit-HasComments: No Gerrit-Has-Labels: Yes Gerrit-MessageType: comment
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 215
  • 216
  • 217
  • 218
  • 219
  • 220
  • 221
  • ...
  • 234
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.