commit | 53243faf690a49e00952b3d3956d2fff0b8d4a3c | [log] [tgz] |
---|---|---|
author | Shruti Bihani <shrutibihani@google.com> | Mon Jul 10 08:53:42 2023 +0000 |
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Thu Sep 07 21:54:29 2023 +0000 |
tree | 258f8db5b4dfa6432a90d68925e80901812ee367 | |
parent | 052a9dc9e4c2740c239d041d50a356fb364ecddf [diff] |
Fix for heap buffer overflow issue flagged by fuzzer test. OOB write occurs when a value is assigned to a buffer index which is greater than the buffer size. Adding a check on buffer bounds fixes the issue. Similar checks have been added wherever applicable on other such methods of the class. Bug: 243463593 Test: Build mtp_packet_fuzzer and run on the target device (cherry picked from commit a669e34bb8e6f0f7b5d7a35144bd342271a24712) (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:0c26c2f4595b58bd7a11512227eacd480c4ddcd9) Merged-In: Icd0f2307803a1a35e655bc08d9d4cca5e2b58a9b Change-Id: Icd0f2307803a1a35e655bc08d9d4cca5e2b58a9b