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
59
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
190
The least you need to know about hashing in Swift
gregheo
0
130
Shared Mutable State
gregheo
0
420
Promises, Futures, and the Shape of Your Code
gregheo
0
59
Shared, Exclusive, Mutable, Immutable
gregheo
0
140
Getting Under Swift’s Skin
gregheo
0
520
Sanitizing Threads for Fun & Profit
gregheo
0
120
Thirteen Ways of Looking at a View Controller
gregheo
0
120
Five Unbelievable Secrets of Reactive Programming the Experts Don't Want You to Know!
gregheo
3
380
Other Decks in Technology
See All in Technology
短縮URLをお手軽に導入しよう
nakasho
0
150
【詳説】コンテンツ配信 システムの複数機能 基盤への拡張
hatena
0
230
内製化を加速させるlaC活用術
nrinetcom
PRO
2
140
エンジニアリング価値を黒字化する バリューベース戦略を用いた 技術戦略策定の道のり
kzkmaeda
6
2.6k
IAMポリシーのAllow/Denyについて、改めて理解する
smt7174
2
200
AIエージェント元年
shukob
0
160
PHPで印刷所に入稿できる名札データを作る / Generating Print-Ready Name Tag Data with PHP
tomzoh
0
180
RayでPHPのデバッグをちょっと快適にする
muno92
PRO
0
190
分解して理解する Aspire
nenonaninu
2
1k
いまからでも遅くない!コンテナでWebアプリを動かしてみよう!コンテナハンズオン編
nomu
0
150
サイト信頼性エンジニアリングとAmazon Web Services / SRE and AWS
ymotongpoo
7
1.5k
データエンジニアリング領域におけるDuckDBのユースケース
chanyou0311
9
2.2k
Featured
See All Featured
JavaScript: Past, Present, and Future - NDC Porto 2020
reverentgeek
47
5.2k
Fantastic passwords and where to find them - at NoRuKo
philnash
51
3k
VelocityConf: Rendering Performance Case Studies
addyosmani
328
24k
The Psychology of Web Performance [Beyond Tellerrand 2023]
tammyeverts
46
2.3k
Automating Front-end Workflow
addyosmani
1368
200k
Site-Speed That Sticks
csswizardry
4
400
Six Lessons from altMBA
skipperchong
27
3.6k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
30
4.6k
Fireside Chat
paigeccino
34
3.2k
Reflections from 52 weeks, 52 projects
jeffersonlam
348
20k
Building Your Own Lightsaber
phodgson
104
6.2k
Practical Orchestrator
shlominoach
186
10k
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