Sanitize dumped stacks to remove data that may be identifiable.

In order to sanitize the stack contents we erase any pointer-aligned
word that could not be interpreted as a pointer into one of the
processes' memory mappings, or a small integer (+/-4096).

This still retains enough information to unwind stack frames, and also
to recover some register values.

BUG=682278

Change-Id: I541a13b2e92a9d1aea2c06a50bd769a9e25601d3
Reviewed-on: https://chromium-review.googlesource.com/430050
Reviewed-by: Robert Sesek <rsesek@chromium.org>
This commit is contained in:
Tobias Sargeant 2017-01-31 13:42:52 +00:00 committed by Tobias Sargeant
parent cb94b71d28
commit 7c2799f3ba
9 changed files with 362 additions and 62 deletions

View file

@ -594,6 +594,7 @@ bool ExceptionHandler::DoDump(pid_t crashing_process, const void* context,
mapping_list_,
minidump_descriptor_.skip_dump_if_principal_mapping_not_referenced(),
minidump_descriptor_.address_within_principal_mapping(),
minidump_descriptor_.sanitize_stacks(),
*minidump_descriptor_.microdump_extra_info());
}
if (minidump_descriptor_.IsFD()) {