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
Radeco Pseudo C Code Generation
Search
kriw
September 08, 2018
Technology
1
110
Radeco Pseudo C Code Generation
The slide of r2con2018
kriw
September 08, 2018
Tweet
Share
More Decks by kriw
See All by kriw
セキュリティキャンプ2017全国大会 集中コースZ5
kriw
1
500
Other Decks in Technology
See All in Technology
AWSで始める実践Dagster入門
kitagawaz
1
580
「どこから読む?」コードとカルチャーに最速で馴染むための実践ガイド
zozotech
PRO
0
280
フィンテック養成勉強会#56
finengine
0
140
開発者を支える Internal Developer Portal のイマとコレカラ / To-day and To-morrow of Internal Developer Portals: Supporting Developers
aoto
PRO
1
440
オブザーバビリティが広げる AIOps の世界 / The World of AIOps Expanded by Observability
aoto
PRO
0
340
職種の壁を溶かして開発サイクルを高速に回す~情報透明性と職種越境から考えるAIフレンドリーな職種間連携~
daitasu
0
140
機械学習を扱うプラットフォーム開発と運用事例
lycorptech_jp
PRO
0
230
Obsidian応用活用術
onikun94
1
450
Codeful Serverless / 一人運用でもやり抜く力
_kensh
7
370
なぜSaaSがMCPサーバーをサービス提供するのか?
sansantech
PRO
8
2.7k
Agile PBL at New Grads Trainings
kawaguti
PRO
1
390
Language Update: Java
skrb
2
290
Featured
See All Featured
Unsuck your backbone
ammeep
671
58k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
16k
[RailsConf 2023] Rails as a piece of cake
palkan
57
5.8k
Why You Should Never Use an ORM
jnunemaker
PRO
59
9.5k
Stop Working from a Prison Cell
hatefulcrawdad
271
21k
RailsConf 2023
tenderlove
30
1.2k
Bash Introduction
62gerente
615
210k
It's Worth the Effort
3n
187
28k
Designing for Performance
lara
610
69k
4 Signs Your Business is Dying
shpigford
184
22k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
252
21k
Practical Orchestrator
shlominoach
190
11k
Transcript
Radeco Pseudo C Code Generation GSoC’2018
Radeco Pseudo C Code Generation I have done - writing
pseudo C Code generator - writing r2 integration
Demo
Decompilers
Projects - radeco-lib - https://github.com/radareorg/radeco-lib - Core library for binary
analysis, decompilation - radeco - https://github.com/radareorg/radeco - User interface
Design (radare2 to radeco) Input (ESIL)
Design (radeco-lib) radeco has 3 stages - Loading Binary (ESIL)
- Analyses - deadcode elimination, ... - Decompilation - heuristics - control flow structuring
Works Before GSoC After GSoC
Works Before GSoC After GSoC
IR Assembly-like intermidiate representation - Generated from ESIL - SSA
form Example IR
C-like CFG - CFG with C expressions
IR to C-like CFG - CFG is copied from the
one of IR No for/if/while - Expressions are recovered by expr tree %34 = (%30 | %31) & 0xffffffff %33 = %30 | %31 %34 = %33 & 0xffffffff
C-like CFG to Pseudo C code - Recover C code
from CFG (with GOTOs) - Only recover assignments with memory reference - Recovered: mov [ebp - 0x1c], 0x10 - Ignored: mov eax, 0x10
Challenges - Required knowledge of program/binary analysis - Sharing tasks
with HMPerson1 - Few information about decompiler
TODOs Milestone for Radeco-0.1 - Bug fixes - API stabilization
(radeco-lib) - Documentation - etc
Commits
Thank you