Commit f6e3ea48 authored by Robert Schmidt's avatar Robert Schmidt

Merge remote-tracking branch 'origin/issue-920-fix-crash-sctp' into integration_2025_w12 (!3315)

SCTP: avoid assert on partial SCTP message

The receive buffer for SCTP, before this branch, is 8192. If a message
is larger, we receive only a partial message, which makes the gNB abort.
Remove the abort to not be susceptible to a message intended to crash
the gNB.

also, increase the receive buffer to be more forgiving for large messages

Closes: #920
parents 9c0eaefb b138b143
...@@ -26,6 +26,6 @@ ...@@ -26,6 +26,6 @@
#define SCTP_IN_STREAMS (16) #define SCTP_IN_STREAMS (16)
#define SCTP_MAX_ATTEMPTS (8) #define SCTP_MAX_ATTEMPTS (8)
#define SCTP_TIMEOUT (60000) #define SCTP_TIMEOUT (60000)
#define SCTP_RECV_BUFFER_SIZE (8192) #define SCTP_RECV_BUFFER_SIZE (65536)
#endif /* SCTP_DEFAULT_VALUES_H_ */ #endif /* SCTP_DEFAULT_VALUES_H_ */
...@@ -806,8 +806,8 @@ sctp_eNB_read_from_socket( ...@@ -806,8 +806,8 @@ sctp_eNB_read_from_socket(
} }
if (!(flags & MSG_EOR)) { if (!(flags & MSG_EOR)) {
SCTP_ERROR("fatal: partial SCTP messages are not handled\n"); SCTP_ERROR("partial SCTP message received, discarding message\n");
exit_fun("fatal: partial SCTP messages are not handled" ); return;
} }
if (flags & MSG_NOTIFICATION) { if (flags & MSG_NOTIFICATION) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment