Content deleted Content added
No edit summary Tags: references removed Visual edit Mobile edit Mobile web edit |
m Reverted 1 edit by 114.124.236.209 (talk) to last revision by Kiwi128 (TW) |
||
Line 42:
==Bounds checking==
{{Main|Bounds checking}}
Bounds checking is a compiler-based technique that adds run-time bounds information for each allocated block of memory, and checks all pointers against those at run-time. For C and C++, bounds checking can be performed at pointer calculation time<ref name="joneskelly">{{cite web|url=http://www.doc.ic.ac.uk/~phjk/BoundsChecking.html |title=Bounds Checking for C |publisher=Doc.ic.ac.uk |date= |accessdate=2014-04-27}}</ref> or at dereference time.<ref name="safecodesva">{{cite web|url=http://sva.cs.illinois.edu/sva.html |title=SAFECode: Secure Virtual Architecture |publisher=Sva.cs.illinois.edu |date=2009-08-12 |accessdate=2014-04-27}}</ref><ref name="asan">{{cite web|url=https://code.google.com/p/address-sanitizer/|title=google/sanitizers}}</ref><ref name="failsafec">{{cite web|url=http://staff.aist.go.jp/y.oiwa/FailSafeC/index-en.html |title=Fail-Safe C: Top Page |publisher=Staff.aist.go.jp |date=2013-05-07 |accessdate=2014-04-27}}</ref>
Implementations of this approach use either a central repository, which describes each allocated block of memory, or , which contain both the pointer and additional data, describing the region that they point to.▼
▲Implementations of this approach use either a central repository, which describes each allocated block of memory,<ref name="joneskelly"/><ref name="safecodesva"/><ref name="asan"/> or [[fat pointer]]s,<ref name="failsafec"/> which contain both the pointer and additional data, describing the region that they point to.
==Tagging==
Line 73 ⟶ 75:
===Clang/[[LLVM]]===
Clang supports three buffer overflow detectors, namely
[[AddressSanitizer]] (-fsanitize=address),<ref name="asan"
-fsanitize=bounds,<ref>{{cite web|url=http://clang.llvm.org/docs/UsersManual.html |title=Clang Compiler User's Manual — Clang 3.5 documentation |publisher=Clang.llvm.org |date= |accessdate=2014-04-27}}</ref>
and SafeCode.<ref>{{cite web|url=http://safecode.cs.illinois.edu/ |title=SAFECode |publisher=Safecode.cs.illinois.edu |date= |accessdate=2014-04-27}}</ref>
Line 82 ⟶ 84:
=== {{Anchor|FSC}}Fail-Safe C ===
''Fail-Safe C''<ref name="failsafec"
===StackGhost (hardware-based)===
|