diff options
author | Mitch Phillips <mitchp@google.com> | 2021-01-20 11:25:11 -0800 |
---|---|---|
committer | Mitch Phillips <mitchp@google.com> | 2021-01-20 12:45:07 -0800 |
commit | 347b01b58324516941b338614dec33cc59c6e018 (patch) | |
tree | b67214d52098360a8ac78e3056bf32654cf19aa2 /tests/stdio_test.cpp | |
parent | d65b31fad659b806401201adb3cd1dcbf38e61e3 (diff) |
[MTE] Change scudo init order to get correct PROT_MTE pages.
scudo_malloc_* for fill contents in __libc_init_scudo calls scudo's
initializers. We haven't told Scudo whether we want MTE-capable (i.e.
mapped with PROT_MTE) size class regions yet, which happens in
SetDefaultHeapTaggingLevel. This can lead to inconsistent mappings,
where processes without ELF notes get the base region with PROT_MTE
(which is undesirable because the performance implications are not
known).
Make sure that scudo is informed of whether regions need to be mapped
PROT_MTE or not by hoising the tagging level up.
Bug: 135772972
Bug: 172365548
Test: On FVP - 'adb shell MEMTAG_OPTIONS=off sanitizer-status' should
have no PROT_MTE mappings (validation by looking for no 'mt' under
'VmFlags:' in /proc/smaps').
Change-Id: Idad64479c4a9459cb40dd211fe942437f8ca16fd
Diffstat (limited to 'tests/stdio_test.cpp')
0 files changed, 0 insertions, 0 deletions