Neels Hofmeyr has posted comments on this change. ( 
https://gerrit.osmocom.org/13307 )

Change subject: a_iface_bssap: check bssmap length field
......................................................................


Patch Set 5:

> I had a look at your code. To me it looks ok to discard the whole message if 
> there is excess data as it either means that the message was damaged of the 
> receiving end has some significant problems. However, the ticket that is 
> related to the task says that the message should only be truncated: 
> http://osmocom.org/issues/3806

Ah ok, I've adopted this patch's truncation on my branch as:

        if (msgb_l3len(bssmap) > h->length) {
                LOG_NAS_A_DEC(nas_dec, LOGL_NOTICE, "There are %u extra bytes 
after the BSSMAP data, truncating\n",
                             msgb_l3len(bssmap) - h->length);
                msgb_l3trim(bssmap, h->length);
        }


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

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I3b89dd5a66ec83b03860b58b6b8eb58007f433a4
Gerrit-Change-Number: 13307
Gerrit-PatchSet: 5
Gerrit-Owner: dexter <pma...@sysmocom.de>
Gerrit-Reviewer: Harald Welte <lafo...@gnumonks.org>
Gerrit-Reviewer: Jenkins Builder (1000002)
Gerrit-Reviewer: Neels Hofmeyr <nhofm...@sysmocom.de>
Gerrit-Reviewer: Pau Espin Pedrol <pes...@sysmocom.de>
Gerrit-Reviewer: dexter <pma...@sysmocom.de>
Gerrit-Comment-Date: Mon, 08 Apr 2019 14:20:17 +0000
Gerrit-HasComments: No
Gerrit-HasLabels: No

Reply via email to