summaryrefslogtreecommitdiff
path: root/lib/sanitizer_common/sanitizer_win.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Reland "[ASan] Do not misrepresent high value address dereferences as null ↵Julian Lettner2019-10-101-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | dereferences" Updated: Removed offending TODO comment. Dereferences with addresses above the 48-bit hardware addressable range produce "invalid instruction" (instead of "invalid access") hardware exceptions (there is no hardware address decoding logic for those bits), and the address provided by this exception is the address of the instruction (not the faulting address). The kernel maps the "invalid instruction" to SEGV, but fails to provide the real fault address. Because of this ASan lies and says that those cases are null dereferences. This downgrades the severity of a found bug in terms of security. In the ASan signal handler, we can not provide the real faulting address, but at least we can try not to lie. rdar://50366151 Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D68676 llvm-svn: 374265 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@374384 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "[ASan] Do not misrepresent high value address dereferences as null ↵Russell Gallop2019-10-101-5/+0
| | | | | | | | | | dereferences" As it was breaking bots running sanitizer lint check This reverts r374265 (git b577efe4567f1f6a711ad36e1d17280dd1c4f009) git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@374308 91177308-0d34-0410-b5e6-96231b3b80d8
* [ASan] Do not misrepresent high value address dereferences as null dereferencesJulian Lettner2019-10-101-0/+5
| | | | | | | | | | | | | | | | | | | | | | Dereferences with addresses above the 48-bit hardware addressable range produce "invalid instruction" (instead of "invalid access") hardware exceptions (there is no hardware address decoding logic for those bits), and the address provided by this exception is the address of the instruction (not the faulting address). The kernel maps the "invalid instruction" to SEGV, but fails to provide the real fault address. Because of this ASan lies and says that those cases are null dereferences. This downgrades the severity of a found bug in terms of security. In the ASan signal handler, we can not provide the real faulting address, but at least we can try not to lie. rdar://50366151 Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D68676 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@374265 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove NOLINTs from compiler-rtVitaly Buka2019-09-111-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@371687 91177308-0d34-0410-b5e6-96231b3b80d8
* [Sanitizer] Using huge page on FreeBSD for shadow mappingDavid Carlier2019-08-271-0/+5
| | | | | | | | | | | | | - Unless explicit configuration, using FreeBSD super pages feature for shadow mapping. - asan only for now. Reviewers: dim, emaste, vitalybuka Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D65851 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@370008 91177308-0d34-0410-b5e6-96231b3b80d8
* [Sanitizer] Linux explicitally migrate shadow mapping to Transparent Huge PageDavid Carlier2019-08-061-2/+1
| | | | | | | | | | | | in madvise mode, the shadow pages will be migrated only via madvise explicit calls. Reviewers: vitalybuka Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D65775 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@368090 91177308-0d34-0410-b5e6-96231b3b80d8
* [Sanitizer] Linux refactor shadow huge page mode handlingDavid Carlier2019-08-051-1/+1
| | | | | | | | | | | | Disabling Transparent huge page mode refactored in one function. Reviewers: vitalybuka Reviewed By: vitalybuka Differential Revision: https://reviews.llvm.org/D65771 git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@367925 91177308-0d34-0410-b5e6-96231b3b80d8
* compiler-rt: Rename .cc file in lib/sanitizer_common to .cppNico Weber2019-07-311-0/+1115
See https://reviews.llvm.org/D58620 for discussion, and for the commands I ran. In addition I also ran for f in $(svn diff | diffstat | grep .cc | cut -f 2 -d ' '); do rg $f . ; done and manually updated (many) references to renamed files found by that. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@367463 91177308-0d34-0410-b5e6-96231b3b80d8