Commit: 547f9e37b89126a74d69a6066f0d315250ee70d2
Parent: 3d6f41b498980e9a48b9f716b04cc9a2c223ef83
Author: Anderson Lizardo <anderson.lizardo@openbossa.org>
Committer: Johan Hedberg <johan.hedberg@intel.com>
Date: 2011-10-01 10:09:13
Tree: 79c8ab8a7a18ab2250cbe46be293ec57cbb1c7f5

Fix memory corruption when decoding Read Response PDU A bogus (or hostile) Proximity Reporter device may send a TX Power value bigger than the buffer used. Therefore, create a temporary buffer with the maximum size, and check for the length before using the value. Note that all other current users of the dec_read_resp() already do this. Another option would be to change dec_read_resp() to accept a buffer length, but this would break external code, so it is avoided for now.

Diffstat

M proximity/monitor.c | 11 ++++++++- - -

1 files changed, 8 insertions(+), 3 deletions(-)

View Full Diff | Patch