jolly has uploaded this change for review. (
https://gerrit.osmocom.org/c/osmo-bts/+/35082?usp=email )
Change subject: LAPDm: Reject (release) establishment on DCC0, SAPI 0 without L3 payload
......................................................................
LAPDm: Reject (release) establishment on DCC0, SAPI 0 without L3 payload
Related: OS#5971
Change-Id: I6819b51a876b8743c2d4a04165b7900723a1631c
---
M src/common/rsl.c
1 file changed, 24 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/82/35082/1
diff --git a/src/common/rsl.c b/src/common/rsl.c
index deeb255..705eef7 100644
--- a/src/common/rsl.c
+++ b/src/common/rsl.c
@@ -3831,6 +3831,20 @@
msg->trx = lchan->ts->trx;
msg->lchan = lchan;
+ /* Reject L2 establishment on main DCCH, SAPI 0 without contention resolution. */
+ if (rh->msg_type == RSL_MT_EST_IND) {
+ const struct abis_rsl_rll_hdr *rllh = msgb_l2(msg);
+
+ /* no L3 payload && main signaling channel && SAPI 0 */
+ if (msgb_l2len(msg) == sizeof(*rllh) && (rllh->link_id & 0xc7) == 0x00)
{
+ LOGPLCHAN(lchan, DRSL, LOGL_ERROR, "RLL establishment without contention
resolution.\n");
+ /* Release normally, re-use the msgb. */
+ rh->msg_type = RSL_MT_REL_REQ;
+ msgb_tv_put(msg, RSL_IE_RELEASE_MODE, RSL_REL_NORMAL);
+ return rsl_rx_rll(lchan->ts->trx, msg);
+ }
+ }
+
/* If this is a Measurement Report, then we simply ignore it,
* because it has already been processed in l1sap_ph_data_ind(). */
if (rslms_is_meas_rep(msg)) {
--
To view, visit
https://gerrit.osmocom.org/c/osmo-bts/+/35082?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I6819b51a876b8743c2d4a04165b7900723a1631c
Gerrit-Change-Number: 35082
Gerrit-PatchSet: 1
Gerrit-Owner: jolly <andreas(a)eversberg.eu>
Gerrit-MessageType: newchange