Page MenuHomeFreeBSD

libc: Disable ASAN for certain string functions
ClosedPublic

Authored by arichardson on Jul 5 2021, 10:52 AM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Nov 25, 9:45 AM
Unknown Object (File)
Thu, Nov 21, 8:44 AM
Unknown Object (File)
Tue, Nov 19, 9:58 PM
Unknown Object (File)
Tue, Nov 19, 4:12 AM
Unknown Object (File)
Fri, Nov 15, 12:34 AM
Unknown Object (File)
Wed, Nov 13, 7:45 PM
Unknown Object (File)
Wed, Nov 13, 7:28 PM
Unknown Object (File)
Mon, Nov 11, 11:52 PM
Subscribers

Details

Summary

They deliberately read out-of-bounds values to avoid byte-by-byte
loads and check multiple bytes at once. While this will work on x86,
it is flagged as an out-of-bounds read with ASAN, so we have to
disable instrumentation here. This also causes bounds errors for CHERI,
so in CheriBSD we use implementations that avoid OOB reads.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

arichardson retitled this revision from libc: Disable ASAN for certain str* functions to libc: Disable ASAN for certain string functions.Jul 5 2021, 5:42 PM
This revision was not accepted when it landed; it landed in state Needs Review.Aug 2 2021, 1:35 PM
This revision was automatically updated to reflect the committed changes.