Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Sanitizing All* The Things
Search
Greg Heo
September 12, 2017
Technology
0
63
Sanitizing All* The Things
Address sanitizer and thread sanitizer. What, why, how?
Greg Heo
September 12, 2017
Tweet
Share
More Decks by Greg Heo
See All by Greg Heo
Concurrency From the Ground Up
gregheo
0
230
The least you need to know about hashing in Swift
gregheo
0
160
Shared Mutable State
gregheo
0
520
Promises, Futures, and the Shape of Your Code
gregheo
0
68
Shared, Exclusive, Mutable, Immutable
gregheo
0
150
Getting Under Swift’s Skin
gregheo
0
550
Sanitizing Threads for Fun & Profit
gregheo
0
150
Thirteen Ways of Looking at a View Controller
gregheo
0
130
Five Unbelievable Secrets of Reactive Programming the Experts Don't Want You to Know!
gregheo
3
410
Other Decks in Technology
See All in Technology
Introduction to Sansan Meishi Maker Development Engineer
sansan33
PRO
0
330
Data Hubグループ 紹介資料
sansan33
PRO
0
2.6k
アウトプットはいいぞ / output_iizo
uhooi
0
110
「リリースファースト」の実感を届けるには 〜停滞するチームに変化を起こすアプローチ〜 #RSGT2026
kintotechdev
0
930
All About Sansan – for New Global Engineers
sansan33
PRO
1
1.3k
Databricks Free Edition講座 データエンジニアリング編
taka_aki
0
2.6k
Introduction to Sansan, inc / Sansan Global Development Center, Inc.
sansan33
PRO
0
2.9k
技術選定、下から見るか?横から見るか?
masakiokuda
0
190
ソフトとハード両方いけるデータ人材の育て方
waiwai2111
1
250
Claude Codeを使った情報整理術
knishioka
20
12k
研究開発部メンバーの働き⽅ / Sansan R&D Profile
sansan33
PRO
4
21k
Scrum Guide Expansion Pack が示す現代プロダクト開発への補完的視点
sonjin
0
630
Featured
See All Featured
[RailsConf 2023] Rails as a piece of cake
palkan
58
6.2k
Future Trends and Review - Lecture 12 - Web Technologies (1019888BNR)
signer
PRO
0
3.2k
Making the Leap to Tech Lead
cromwellryan
135
9.7k
Odyssey Design
rkendrick25
PRO
0
460
Optimising Largest Contentful Paint
csswizardry
37
3.6k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
359
30k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
Done Done
chrislema
186
16k
Navigating Weather and Climate Data
rabernat
0
71
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
1
360
Groundhog Day: Seeking Process in Gaming for Health
codingconduct
0
75
Transcript
Sanitizing All* The Things tacow / September 2017 / @gregheo
❓ ✋
None
✅
None
‣ ASAN ‣ TSAN
‣ What? ‣ So what? ‣ How? ‣ Show me?
Address Sanitizer allocated buffer unallocated!
‣ Buffer overflows ‣ Subtle bugs ‣ Security vulnerabilities
None
allocated buffer padding shadow memory poisoned poisoned OK
asan_malloc malloc asan_free free Shadow memory check Pointer access
Live Coding!
Address Sanitizer Memory corruption & errors Security & crashes Custom
malloc & free
Thread Sanitizer memory buffer read write
‣ Race conditions ‣ Very subtle and difficult-to-reproduce bugs ‣
Thread mismatch errors
None
‣ Thread ID ‣ Timestamp ‣ Read or write? ‣
Bytes accessed
None
Live Coding!
Thread Sanitizer Data race detector Find race conditions & thread
issues Thread IDs & timestamps
Address Sanitizer Memory corruption & errors Security & crashes Custom
malloc & free
None
@gregheo