Change in osmo-bts[master]: OML: Properly reject short messages and truncate over-long messages

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Sun Feb 10 22:23:59 UTC 2019


Harald Welte has posted comments on this change. ( https://gerrit.osmocom.org/12873 )

Change subject: OML: Properly reject short messages and truncate over-long messages
......................................................................


Patch Set 1:

(1 comment)

https://gerrit.osmocom.org/#/c/12873/1/src/common/oml.c
File src/common/oml.c:

https://gerrit.osmocom.org/#/c/12873/1/src/common/oml.c@1453
PS1, Line 1453: 		msgb_l3trim(msg, oh->length);
> That's weird imho, I'd drop it with oml_tx_failure_event_rep(), since attempting decoding potentiall […]
To me it's quite clear: The OML protocol states there's 10 bytes of payload (IEs), and that's what we have to parse.  Extra data at the end of the message should not concern us.  In Ethernet, small frames get a trailer at the end.  In LLC, there's a CRC at the end. I think this is generally customary that you use the length value from the protocol/header you currently work on and ignore any extra data at the end.



-- 
To view, visit https://gerrit.osmocom.org/12873
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Ib98f0d7c2cff9172714ed18667c02564540d65d7
Gerrit-Change-Number: 12873
Gerrit-PatchSet: 1
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder (1000002)
Gerrit-CC: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-Comment-Date: Sun, 10 Feb 2019 22:23:59 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190210/658e0cda/attachment.htm>


More information about the gerrit-log mailing list