Change in libosmocore[master]: tlv_parser: Fix various out-of-bounds accesses

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/.

laforge gerrit-no-reply at lists.osmocom.org
Tue Jan 12 20:11:25 UTC 2021


Hello Jenkins Builder, pespin, fixeria, 

I'd like you to reexamine a change. Please visit

    https://gerrit.osmocom.org/c/libosmocore/+/22113

to look at the new patch set (#3).

Change subject: tlv_parser: Fix various out-of-bounds accesses
......................................................................

tlv_parser: Fix various out-of-bounds accesses

The libosmocore TLV parser had a number of insufficient bounds checks
leading to reads beyond the end of the respective input buffer.

This patch
* adds proper out-of-bounds checks to all TLV types
* simplifies some of the existing checks
* introduces test cases to test all the corner cases
  where either TAG, or length, or value are not fully contained
  in the input buffer.

Thanks to Ilja Van Sprundel for reporting these problems.

Change-Id: I98b02c914c9e3ecf56050af846292aa6979d7508
---
M src/gsm/tlv_parser.c
M tests/tlv/tlv_test.c
M tests/tlv/tlv_test.ok
3 files changed, 115 insertions(+), 15 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/13/22113/3
-- 
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/22113
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I98b02c914c9e3ecf56050af846292aa6979d7508
Gerrit-Change-Number: 22113
Gerrit-PatchSet: 3
Gerrit-Owner: laforge <laforge at osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy at sysmocom.de>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: newpatchset
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210112/92bbe038/attachment.htm>


More information about the gerrit-log mailing list