diff options
| author | Pragaspathi Thilagaraj <tpragasp@codeaurora.org> | 2018-03-29 19:26:47 +0530 |
|---|---|---|
| committer | nshrivas <nshrivas@codeaurora.org> | 2018-04-05 01:36:13 -0700 |
| commit | 3bf102d1f71d8127f89396683db4b0a4b8725f32 (patch) | |
| tree | 43a7fe1c56d802668ce6741fae05e10cba7222e2 /tools/perf/scripts/python | |
| parent | ce53e756c93c07108e69beb72e61bfc36f168a46 (diff) | |
qcacld-3.0: Fix OOB write in wma_unified_debug_print_event_handler
The routine wma_unified_debug_print_event_handler logs the data from debug
print event handler. The param event data from firmware is copied to a
destination buffer .If the maximum size of the data exceeds or equals
BIG_ENDIAN_MAX_DEBUG_BUF for big endian hosts then possible OOB write will
occur in wma_unified_debug_print_event_handler. For other hosts, OOB read
could occur if datalen exceeds maximum firmware message size
WMI_SVC_MAX_SIZE.
Add check to validate datalen doesnot exceed the maximum firmware msg size
WMI_SVC_MAX_SIZE. Return failure if it exceeds.
Add check to ensure datalen doesnot exceed or equal the maximum buffer
length value for big endian hosts BIG_ENDIAN_MAX_DEBUG_BUF.
Invoke strlcpy instead of memcpy to ensure string is null terminated
before is printed.
Change-Id: I45943ae76d8fcf7b53e1f064c462d01cd6d00dcf
CRs-Fixed: 2211133
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
