summaryrefslogtreecommitdiff
path: root/linker/linker_block_allocator_test.cpp
diff options
context:
space:
mode:
authorKen Chen <cken@google.com>2020-08-07 19:04:25 +0800
committerKen Chen <cken@google.com>2020-08-07 20:19:43 +0800
commit43264bc36557db9a281b321aab16e574401dfddc (patch)
tree7b95545601c687451e6a09f49b7e9f78b3be9a9e /linker/linker_block_allocator_test.cpp
parentdad73ef232034dd0f4f46bda90c74e8727d840cc (diff)
Fix OOB read in DNS resolver
The remote server specifies resplen, the length of the response it intends to send. anssiz represents the size of the destination buffer. If the reported resplen is larger than the anssiz, the code correctly only reads up to anssiz bytes, but returns resplen. so later functions will access far out of bounds. The fix ensures that the length of send_vc return does not exceed the buffer size. Bug: 161362564 Test: build, flash, boot Test: atest netd_integration_test Merged-In: Id4b5df1be4652e4623847b0b0bad0af65b80fdd5 Change-Id: Id4b5df1be4652e4623847b0b0bad0af65b80fdd5
Diffstat (limited to 'linker/linker_block_allocator_test.cpp')
0 files changed, 0 insertions, 0 deletions