# decompiler

Published articles for decompiler.

This is one page of public article previews, not the complete archive. Follow Next page to continue. Summaries are not the original full articles.

## DeCompCert: A Verified Decompiler for CompCert-Generated AArch64

DevFeed: [DeCompCert: A Verified Decompiler for CompCert-Generated AArch64](<https://devfeed.tech/articles/decompcert-a-verified-decompiler-for-compcert-generated-aarch64-136043.md>)

Original publisher: [Read original article](<https://arxiv.org/abs/2611.18055>)

Author: Swarn Priya, Basavesh Ammanaghatta Shivakumar, Thomas Gilray, Kristopher Micinski

Published: 2026-11-16T05:00:00Z

Content type: article

Language: en

Sources: [arXiv: Cryptography and Security](<https://devfeed.tech/sources/arxiv-cryptography-and-security.md>)

Topics: [code analysis](<https://devfeed.tech/topics/code-analysis.md>), [inlining](<https://devfeed.tech/topics/inlining.md>)

Tags: [assembly](<https://devfeed.tech/tags/assembly.md>), [behavior](<https://devfeed.tech/tags/behavior.md>), [c](<https://devfeed.tech/tags/c.md>), [call](<https://devfeed.tech/tags/call.md>), [cs-cr](<https://devfeed.tech/tags/cs-cr.md>), [cs-pl](<https://devfeed.tech/tags/cs-pl.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [experiments](<https://devfeed.tech/tags/experiments.md>), [function](<https://devfeed.tech/tags/function.md>), [ida](<https://devfeed.tech/tags/ida.md>), [inference](<https://devfeed.tech/tags/inference.md>), [native](<https://devfeed.tech/tags/native.md>), [ocaml](<https://devfeed.tech/tags/ocaml.md>), [optimized](<https://devfeed.tech/tags/optimized.md>), [pipelines](<https://devfeed.tech/tags/pipelines.md>), [platform](<https://devfeed.tech/tags/platform.md>), [quality](<https://devfeed.tech/tags/quality.md>), [recovery](<https://devfeed.tech/tags/recovery.md>), [safety](<https://devfeed.tech/tags/safety.md>), [semantic](<https://devfeed.tech/tags/semantic.md>), [translation](<https://devfeed.tech/tags/translation.md>), [validation](<https://devfeed.tech/tags/validation.md>)

### AI overview

DeCompCert reconstructs CompCert C from CompCert-generated AArch64 assembly through nine reverse passes. Untrusted OCaml and Datalog analyses suggest candidates; Rocq-verified transformations and validators accept only reconstructions satisfying semantic correspondence. The theorem ensures every defined, safe behavior of accepted C is matched by the input assembly, with observational equivalence under a safety assumption. In evaluation on about 2.16 million lines of C, exact function and call signatures enabled reconstruction and recompilation of all 3,173 eligible contexts across optimized and unoptimized pipelines. Without retained signatures, its inference portfolio validated 2,606 of 3,164 contexts (82.4%), compared with 2,407 (76.1%) for platform-plus-IDA. The abstract says further experiments assess native execution and output quality, and notes remaining limits in signature recovery and resemblance to original source.

### Source excerpt

arXiv:2611.18055v1 Announce Type: cross Abstract: DeCompCert is a Rocq-verified decompiler for AArch64 assembly generated by CompCert. It reconstructs CompCert C through nine reverse passes, combining deductively verified transformations with translation validation. Untrusted OCaml and Datalog analyses propose candidate reconstructions, while verified validators accept only candidates that satisfy the required semantic correspondence. The composed correctness theorem guarantees that every defined, safe behavior of an accepted C reconstruction is matched by the input CompCert assembly; under a safety assumption, the two programs are observationally equivalent. We evaluate DeCompCert on approximately 2.16 million lines of C. With exact function and call signatures, it reconstructs and recompiles all 3,173 eligible contexts under both unoptimized and optimized CompCert pipelines. Without retained signatures, its cumulative inference portfolio validates 2,606 of 3,164 contexts (82.4%), while the platform-plus-IDA configuration validates 2,407 contexts (76.1%). Native execution and output-quality experiments further evaluate the generated C and characterize the remaining limitations in signature recovery and source resemblance.

## ASAP: Assembly-Source Aligned Pseudocode Refinement For Binary Decompilation

DevFeed: [ASAP: Assembly-Source Aligned Pseudocode Refinement For Binary Decompilation](<https://devfeed.tech/articles/asap-assembly-source-aligned-pseudocode-refinement-for-binary-decompilation-131679.md>)

Original publisher: [Read original article](<https://arxiv.org/abs/2610.06900>)

Author: Yujian Zhuang, Dehong Gao, Qichao Zhang, Qijing Lai, Jiaxin Wang, Libin Yang, Xiaoyan Cai

Published: 2026-11-13T05:00:00Z

Content type: article

Language: en

Sources: [arXiv: Cryptography and Security](<https://devfeed.tech/sources/arxiv-cryptography-and-security.md>), [arXiv: Software Engineering](<https://devfeed.tech/sources/arxiv-software-engineering.md>)

Topics: [Reverse Engineering](<https://devfeed.tech/topics/reverse-engineering.md>), [Assembly](<https://devfeed.tech/topics/assembly.md>), [code analysis](<https://devfeed.tech/topics/code-analysis.md>), [Large Language Model](<https://devfeed.tech/topics/llm.md>), [LLM evaluation / benchmarking](<https://devfeed.tech/topics/llm-evaluation-benchmarking.md>)

Tags: [alignment](<https://devfeed.tech/tags/alignment.md>), [assembly](<https://devfeed.tech/tags/assembly.md>), [benchmarks](<https://devfeed.tech/tags/benchmarks.md>), [binaries](<https://devfeed.tech/tags/binaries.md>), [c](<https://devfeed.tech/tags/c.md>), [compiler](<https://devfeed.tech/tags/compiler.md>), [compiler-optimization](<https://devfeed.tech/tags/compiler-optimization.md>), [cs-cr](<https://devfeed.tech/tags/cs-cr.md>), [cs-pl](<https://devfeed.tech/tags/cs-pl.md>), [cs-se](<https://devfeed.tech/tags/cs-se.md>), [decompilation](<https://devfeed.tech/tags/decompilation.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [errors](<https://devfeed.tech/tags/errors.md>), [language-models](<https://devfeed.tech/tags/language-models.md>), [large-language-models-llms](<https://devfeed.tech/tags/large-language-models-llms.md>), [pseudocode](<https://devfeed.tech/tags/pseudocode.md>), [source](<https://devfeed.tech/tags/source.md>)

### AI overview

ASAP refines decompiler-produced pseudocode by conditioning a decompilation LLM on both that pseudocode and assembly features aligned with source code. It learns the alignment from paired source and binary functions, compresses assembly features into a fixed set of tokens, and uses stochastic pseudocode masking plus a relative assembly-advantage loss to reduce reliance on potentially lossy pseudocode alone. Across two benchmarks and multiple compiler optimization levels, it raises average re-execution rates from 64.7% to 71.9% and recompilation rates from 91.6% to 96.6% versus the strongest baseline.

### Source excerpt

arXiv:2610.06900v2 Announce Type: replace-cross Abstract: Large language models (LLMs) are increasingly used in binary decompilation to refine the C-like pseudocode produced by traditional rule-based decompilers. While this pseudocode is useful, it is a heuristic and lossy abstraction rather than a faithful copy of the source code. It often contains decompiler errors, especially for aggressively optimized binaries where critical low-level details are obscured. We present ASAP, an Assembly-Source Aligned Pseudocode refinement framework for binary decompilation. ASAP learns source-aligned assembly representations from paired source and binary functions using joint function-level and snippet-level contrastive alignment. A Q-Former then compresses chunk-level assembly features into a fixed number of assembly tokens. These tokens and the decompiler-produced pseudocode jointly condition the decompilation LLM. During refinement, we use stochastic pseudocode masking and a relative assembly-advantage loss to discourage the model from relying solely on pseudocode. On two decompilation benchmarks across multiple compiler optimization levels, ASAP improves the average re-execution rate from 64.7% to 71.9% and the average recompilation rate from 91.6% to 96.6% compared with the strongest baseline. Our approach offers both a new perspective and a practical solution to binary decompilation.

## A vibe-coded GTA VI PC port is coming, whether Rockstar likes it or not

DevFeed: [A vibe-coded GTA VI PC port is coming, whether Rockstar likes it or not](<https://devfeed.tech/articles/a-vibe-coded-gta-vi-pc-port-is-coming-whether-rockstar-likes-it-or-not-127387.md>)

Original publisher: [Read original article](<https://www.techspot.com/news/114494-vibe-coded-gta-6-pc-port-coming-whether.html>)

Author: Alfonso Maruccia

Published: 2026-11-10T20:50:00Z

Content type: news

Language: en

Sources: [TechSpot](<https://devfeed.tech/sources/techspot.md>)

Topics: [Source Port](<https://devfeed.tech/topics/source-port.md>), [Game Development](<https://devfeed.tech/topics/game-development.md>)

Tags: [ai](<https://devfeed.tech/tags/ai.md>), [ai-assisted](<https://devfeed.tech/tags/ai-assisted.md>), [brute-force](<https://devfeed.tech/tags/brute-force.md>), [coding](<https://devfeed.tech/tags/coding.md>), [console](<https://devfeed.tech/tags/console.md>), [consoles](<https://devfeed.tech/tags/consoles.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [developers](<https://devfeed.tech/tags/developers.md>), [gaming](<https://devfeed.tech/tags/gaming.md>), [genai](<https://devfeed.tech/tags/genai.md>), [generative-ai](<https://devfeed.tech/tags/generative-ai.md>), [gta](<https://devfeed.tech/tags/gta.md>), [gta-6](<https://devfeed.tech/tags/gta-6.md>), [gta-vi](<https://devfeed.tech/tags/gta-vi.md>), [pc](<https://devfeed.tech/tags/pc.md>), [pc-port](<https://devfeed.tech/tags/pc-port.md>), [playstation](<https://devfeed.tech/tags/playstation.md>), [rockstar](<https://devfeed.tech/tags/rockstar.md>), [slop](<https://devfeed.tech/tags/slop.md>), [take-two](<https://devfeed.tech/tags/take-two.md>), [vibe-coding](<https://devfeed.tech/tags/vibe-coding.md>)

### AI overview

Former Rockstar North technical director Obbe Vermeij speculates that the prospect of an unofficial, AI-assisted GTA 6 PC build could prompt Rockstar to release an official port sooner. He expects someone to attempt a recompiled version after launch, though he says it could take a long time, cost tens of thousands of dollars in AI tokens and still be inferior to a properly developed port. Vermeij says major publishers can use lawyers to challenge decompilation efforts, but he does not see how developers could fully prevent them; he also considers smaller studios more vulnerable. He acknowledges he does not know Rockstar's plans. The excerpt notes that GTA historically launched on consoles first, while many publishers prefer simultaneous releases to pay for one marketing campaign.

### Source excerpt

Former Rockstar North technical director Obbe Vermeij thinks a PC port of GTA 6 could arrive sooner than expected, because Rockstar and Take-Two may want to get ahead of any attempt to put an unofficial version of the game out on the platform. Read Entire Article

## Anthropic tells Claude Code to stop recreating existing video games

DevFeed: [Anthropic tells Claude Code to stop recreating existing video games](<https://devfeed.tech/articles/anthropic-tells-claude-code-to-stop-recreating-existing-video-games-114936.md>)

Original publisher: [Read original article](<https://www.techspot.com/news/114423-anthropic-tells-claude-code-stop-recreating-existing-video.html>)

Author: Alfonso Maruccia

Published: 2026-11-03T18:39:00Z

Content type: news

Language: en

Sources: [TechSpot](<https://devfeed.tech/sources/techspot.md>)

Topics: [Claude Code](<https://devfeed.tech/topics/claude-code.md>), [Claude](<https://devfeed.tech/topics/claude.md>), [Reverse Engineering](<https://devfeed.tech/topics/reverse-engineering.md>), [Vibe coding](<https://devfeed.tech/topics/vibe-coding.md>), [generative-ai-tools](<https://devfeed.tech/topics/generative-ai-tools.md>), [anthropic](<https://devfeed.tech/topics/anthropic.md>)

Tags: [2026](<https://devfeed.tech/tags/2026.md>), [addy-osmani](<https://devfeed.tech/tags/addy-osmani.md>), [ai](<https://devfeed.tech/tags/ai.md>), [ai-assisted-coding](<https://devfeed.tech/tags/ai-assisted-coding.md>), [anthropic](<https://devfeed.tech/tags/anthropic.md>), [anyps5](<https://devfeed.tech/tags/anyps5.md>), [claude](<https://devfeed.tech/tags/claude.md>), [claude-code](<https://devfeed.tech/tags/claude-code.md>), [copyright](<https://devfeed.tech/tags/copyright.md>), [decomp-dev](<https://devfeed.tech/tags/decomp-dev.md>), [decompilation](<https://devfeed.tech/tags/decompilation.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [games](<https://devfeed.tech/tags/games.md>), [intellectual-property](<https://devfeed.tech/tags/intellectual-property.md>), [tech-culture](<https://devfeed.tech/tags/tech-culture.md>), [vibe-coding](<https://devfeed.tech/tags/vibe-coding.md>)

### AI overview

Anthropic is instructing Claude Code to avoid recreating existing commercial games and instead build original games from users' designs and assets. The article says the rule appeared behind a feature flag on October 27, 2026, and Addy Osmani confirmed two new sentences were being added to Claude Code's Opus 5.5 model; Anthropic plans to keep adjusting the rules to find the right balance. The change may make recreations harder with Claude, but the article expects decompilation and porting projects to continue through other AI models, open-weight models, or offline setups. It also reports that AI-assisted coding has disrupted human-led game decompilation research, including the closure of decomp.dev.

### Source excerpt

Claude might soon stop being one of the best AI tools for decompiling and recompiling existing games. According to Anthropic programmer Addy Osmani, the model behind the company's vibe-coding service will now avoid user prompts that request recreations of someone else's video games. Read Entire Article

## VMSpec: A Decompiler-based Approach against Virtual Machine Obfuscation

DevFeed: [VMSpec: A Decompiler-based Approach against Virtual Machine Obfuscation](<https://devfeed.tech/articles/vmspec-a-decompiler-based-approach-against-virtual-machine-obfuscation-94537.md>)

Original publisher: [Read original article](<https://arxiv.org/abs/2610.29566>)

Author: Fabian Kilger, Leonard Auer, Manuel Andreas

Published: 2026-10-22T04:00:00Z

Content type: article

Language: en

Sources: [arXiv: Cryptography and Security](<https://devfeed.tech/sources/arxiv-cryptography-and-security.md>)

Topics: [obfuscation](<https://devfeed.tech/topics/obfuscation.md>), [Reverse Engineering](<https://devfeed.tech/topics/reverse-engineering.md>), [code analysis](<https://devfeed.tech/topics/code-analysis.md>), [Ghidra](<https://devfeed.tech/topics/ghidra.md>)

Tags: [analysis](<https://devfeed.tech/tags/analysis.md>), [approach](<https://devfeed.tech/tags/approach.md>), [behavior](<https://devfeed.tech/tags/behavior.md>), [benchmark](<https://devfeed.tech/tags/benchmark.md>), [bytecode](<https://devfeed.tech/tags/bytecode.md>), [code](<https://devfeed.tech/tags/code.md>), [cs-cr](<https://devfeed.tech/tags/cs-cr.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [generation](<https://devfeed.tech/tags/generation.md>), [ghidra](<https://devfeed.tech/tags/ghidra.md>), [hash](<https://devfeed.tech/tags/hash.md>), [infinite](<https://devfeed.tech/tags/infinite.md>), [input](<https://devfeed.tech/tags/input.md>), [interpreter](<https://devfeed.tech/tags/interpreter.md>), [malware](<https://devfeed.tech/tags/malware.md>), [obfuscation](<https://devfeed.tech/tags/obfuscation.md>), [reverse-engineering](<https://devfeed.tech/tags/reverse-engineering.md>), [semantics](<https://devfeed.tech/tags/semantics.md>), [virtual-machine](<https://devfeed.tech/tags/virtual-machine.md>)

### AI overview

VMSpec addresses a gap in VM deobfuscation by automatically constructing processor specifications so established decompilers can recover higher-level program semantics from VM-obfuscated code. The authors evaluate a prototype on 147 benchmark programs obfuscated with Tigress and Code Virtualizer, plus six domain generation algorithms from real-world malware. They report that it removes VM obfuscation from nearly all samples, with output comparable to Ghidra's decompilation of the original code, and can reconstruct complete behavior for programs with input-dependent paths and recursive calls. These are claims from the supplied abstract; it does not provide detailed methods, per-configuration results, or limitations.

### Source excerpt

arXiv:2610.29566v1 Announce Type: new Abstract: Malicious actors frequently obfuscate their code to hinder investigative reverse engineering efforts. Among the most formidable techniques is virtual machine (VM) obfuscation: programs are translated into bytecode for a custom VM, often with a randomized virtual instruction set and distributed alongside a corresponding interpreter. Manual analysis and deobfuscation scale poorly due to the complexity of VM obfuscation and the diversification techniques that render each VM and interpreter unique. Existing methods primarily focus on simplifying execution traces and identifying virtual execution boundaries. However, comparatively little attention has been given to recovering higher-level program semantics from VM-obfuscated code. To address this gap, we propose VMSpec, a novel decompiler-based approach that automates the construction of VM processor specifications, enabling existing, well-known decompilers to analyze the VM-obfuscated code. We evaluate our prototype of VMSpec on 147 programs from an established obfuscation benchmark, comprising hash functions, standard algorithms, and randomized functions, obfuscated with different configurations of the Tigress and Code Virtualizer obfuscators. To demonstrate real-world applicability, we additionally include six domain generation algorithms stemming from real-world malware. VMSpec completely strips VM-obfuscation from nearly all obfuscated samples, producing output comparable to Ghidra's decompilation of the original code. Furthermore, it is the first method capable of reconstructing the complete program behavior of VM-obfuscated programs with infinite, input-dependent paths and recursive calls.

## ExeBench-FHD: Addressing Fidelity Issues in Decompiler Evaluation

DevFeed: [ExeBench-FHD: Addressing Fidelity Issues in Decompiler Evaluation](<https://devfeed.tech/articles/exebench-fhd-addressing-fidelity-issues-in-decompiler-evaluation-93721.md>)

Original publisher: [Read original article](<https://arxiv.org/abs/2610.28212>)

Author: Akarsh Ashok, Dinil Mon Divakaran, Vivek Balachandran

Published: 2026-10-21T04:00:00Z

Content type: article

Language: en

Sources: [arXiv: Machine Learning](<https://devfeed.tech/sources/arxiv-machine-learning.md>), [arXiv: Software Engineering](<https://devfeed.tech/sources/arxiv-software-engineering.md>)

Topics: [Audit-then-score](<https://devfeed.tech/topics/audit-then-score.md>), [Data Quality](<https://devfeed.tech/topics/data-quality.md>), [Dataset development](<https://devfeed.tech/topics/dataset-development.md>)

Tags: [benchmarks](<https://devfeed.tech/tags/benchmarks.md>), [cs-lg](<https://devfeed.tech/tags/cs-lg.md>), [cs-pl](<https://devfeed.tech/tags/cs-pl.md>), [cs-se](<https://devfeed.tech/tags/cs-se.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [evaluation](<https://devfeed.tech/tags/evaluation.md>), [llm](<https://devfeed.tech/tags/llm.md>)

### AI overview

ExeBench-FHD addresses nine fidelity problems in ExeBench that can hinder C-code recovery or weaken test validity. It adds 16 backward-compatible fields, including call-site assembly, data sections, test wrappers, linked-binary disassembly and warning flags. In the original benchmark, 38.9% of functions have at least one of five flags; excluding records with any of four flags, while retaining unused_param records made evaluable by the new wrappers, leaves 63.9% of the corpus. At -O2 across four architectures, the added fields increased GPT 6 Sol's re-execution rate by up to 26.5% for functions reading data sections, 19.1% for mixed integer and floating-point parameters, and 21.0% for unused parameters.

### Source excerpt

arXiv:2610.28212v1 Announce Type: new Abstract: ExeBench is one of the most widely used benchmarks for evaluating LLM-based decompilers. We analyze ExeBench and identify nine issues that affect how faithfully a test measures a decompiler. Three of them prevent LLM decompilers from recovering C code from ExeBench's function. These are ambiguous parameter order when integer and floating-point types are mixed, unused parameters that optimized assembly may drop, and constants stored outside the function's assembly code. Six more affect test validity: non-void functions without a return, placeholder types, static or inline functions removed by the optimizer, functions named main, trivial bodies and truncated definitions. We present ExeBench-FHD, a backward-compatible revision of ExeBench that adds 16 new fields: call-site assembly, data sections, test wrappers, linked-binary disassembly and five warning flags. In ExeBench, 38.9% of functions have at least one of the five flags; dropping records with any of the four warning flags (all except unused_param, which marks functions that the new wrappers make evaluable) keeps 63.9% of the corpus. In an evaluation at -O2 on four architectures, the new fields raise GPT 6 Sol's re-execution rate by up to 26.5%, 19.1% and 21.0% on functions that read data sections, mix parameter types and have unused parameters, respectively.

## The developer who cloned Photoshop using AI has now created Word, Excel, and PowerPoint replicas with Claude

DevFeed: [The developer who cloned Photoshop using AI has now created Word, Excel, and PowerPoint replicas with Claude](<https://devfeed.tech/articles/the-developer-who-cloned-photoshop-using-ai-has-now-created-word-excel-and-powerpoint-replicas-with-claude-86480.md>)

Original publisher: [Read original article](<https://www.techspot.com/news/114179-developer-who-cloned-photoshop-using-ai-has-now.html>)

Author: Kishalaya Kundu

Published: 2026-10-13T18:53:00Z

Content type: news

Language: en

Sources: [TechSpot](<https://devfeed.tech/sources/techspot.md>)

Topics: [Groovy](<https://devfeed.tech/topics/groovy.md>), [Open Source](<https://devfeed.tech/topics/open-source.md>), [anthropic](<https://devfeed.tech/topics/anthropic.md>), [AI Chat](<https://devfeed.tech/topics/ai-chat.md>), [AutoCorrode library](<https://devfeed.tech/topics/autocorrode-library.md>)

Tags: [ai](<https://devfeed.tech/tags/ai.md>), [ai-developer](<https://devfeed.tech/tags/ai-developer.md>), [apache-2-0](<https://devfeed.tech/tags/apache-2-0.md>), [claude-opus](<https://devfeed.tech/tags/claude-opus.md>), [claude-opus-5-5](<https://devfeed.tech/tags/claude-opus-5-5.md>), [clone](<https://devfeed.tech/tags/clone.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [developers](<https://devfeed.tech/tags/developers.md>), [development](<https://devfeed.tech/tags/development.md>), [excel](<https://devfeed.tech/tags/excel.md>), [microsoft-office](<https://devfeed.tech/tags/microsoft-office.md>), [mit](<https://devfeed.tech/tags/mit.md>), [open-source](<https://devfeed.tech/tags/open-source.md>), [powerpoint](<https://devfeed.tech/tags/powerpoint.md>), [rust](<https://devfeed.tech/tags/rust.md>), [software](<https://devfeed.tech/tags/software.md>), [vibe-coding](<https://devfeed.tech/tags/vibe-coding.md>), [word](<https://devfeed.tech/tags/word.md>)

### AI overview

Developer Brandon Thomas is building WordCraft, GridCraft, and DeckCraft, open-source Rust applications that reproduce Microsoft Word, Excel, and PowerPoint with Claude Opus 5.5. They support major Microsoft Office formats, and the project reports varying degrees of feature parity. All three remain in alpha and need more development before they can serve as viable Office alternatives.

### Source excerpt

Called WordCraft, GridCraft, and DeckCraft, respectively, the open-source applications are written in Rust with Anthropic's Claude Opus 5.5, as the Adobe replicas were, and are available for download under MIT or Apache 2.0 licenses. They are, however, still at a relatively early stage of development and need a lot more... Read Entire Article

## Reversing Pickles with r2pickledec

DevFeed: [Reversing Pickles with r2pickledec](<https://devfeed.tech/articles/reversing-pickles-with-r2pickledec-92033.md>)

Original publisher: [Read original article](<https://blog.doyensec.com/2023/06/01/r2pickledec.html>)

Published: 2023-05-31T22:00:00Z

Content type: tutorial

Language: en

Sources: [Doyensec](<https://devfeed.tech/sources/doyensec.md>)

Topics: [code analysis](<https://devfeed.tech/topics/code-analysis.md>), [Data serialization](<https://devfeed.tech/topics/data-serialization.md>), [Tool](<https://devfeed.tech/topics/tool.md>), [Python](<https://devfeed.tech/topics/python.md>), [Assembly](<https://devfeed.tech/topics/assembly.md>)

Tags: [auditing](<https://devfeed.tech/tags/auditing.md>), [automation](<https://devfeed.tech/tags/automation.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [doyensec](<https://devfeed.tech/tags/doyensec.md>), [doyensecurity](<https://devfeed.tech/tags/doyensecurity.md>), [exploit](<https://devfeed.tech/tags/exploit.md>), [hacking](<https://devfeed.tech/tags/hacking.md>), [infosec](<https://devfeed.tech/tags/infosec.md>), [obfuscation](<https://devfeed.tech/tags/obfuscation.md>), [offensive](<https://devfeed.tech/tags/offensive.md>), [pentest](<https://devfeed.tech/tags/pentest.md>), [pentester](<https://devfeed.tech/tags/pentester.md>), [protocol](<https://devfeed.tech/tags/protocol.md>), [python](<https://devfeed.tech/tags/python.md>), [r2](<https://devfeed.tech/tags/r2.md>), [remote-code-execution](<https://devfeed.tech/tags/remote-code-execution.md>), [reverse-engineering](<https://devfeed.tech/tags/reverse-engineering.md>), [reversing](<https://devfeed.tech/tags/reversing.md>), [security](<https://devfeed.tech/tags/security.md>), [serialization](<https://devfeed.tech/tags/serialization.md>), [stack](<https://devfeed.tech/tags/stack.md>), [stream](<https://devfeed.tech/tags/stream.md>), [tool](<https://devfeed.tech/tags/tool.md>), [vulnerability](<https://devfeed.tech/tags/vulnerability.md>)

### AI overview

r2pickledec decompiles Python pickles through Radare2, supporting instructions through protocol 5. The article explains that pickle instructions mostly manipulate a stack, with a memo for retrieving earlier values, and warns that unpickling untrusted data can lead to remote code execution. In its example, the decompiler reveals a serialized API object's requests session and an auth tuple containing credentials, then locates and patches the object's base URL. Radare2 flags help identify and rename variables; the plugin's JSON AST includes offsets that can support scripted searches and edits with r2pipe. The author says packaged Radare2 versions may be old but should work for this use, and suggests installing from source if bugs occur.

### Source excerpt

R2pickledec is the first pickle decompiler to support all instructions up to protocol 5 (the current). In this post we will go over what Python pickles are, how they work and how to reverse them with Radare2 and r2pickledec. An upcoming blog post will go even deeper into pickles and share some advanced obfuscation techniques. What are pickles? Pickles are the built-in serialization algorithm in Python. They can turn any Python object into a byte stream so it may be stored on disk or sent over a network. Pickles are notoriously dangerous. You should never unpickle data from an untrusted source. Doing so will likely result in remote code execution. Please refer to the documentation for more details. Pickle Basics Pickles are implemented as a very simple assembly language. There are only 68 instructions and they mostly operate on a stack. The instruction names are pretty easy to understand. For example, the instruction empty_dict will push an empty dictionary onto the stack. The stack only allows access to the top item, or items in some cases. If you want to grab something else, you must use the memo. The memo is implemented as a dictionary with positive integer indexes. You will often see memoize instructions. Naively, the memoize instruction will copy the item at the top of the stack into the next index in the memo. Then, if that item is needed later, a binget n can be used to get the object at index n. To learn more about pickles, I recommend playing with some pickles. Enable descriptions in Radare2 with e asm.describe = true to get short descriptions of each instruction. Decompile simple pickles that you build yourself, and see if you can understand the instructions. Installing Radare2 and r2pickledec For reversing pickles, our tool of choice is Radare2 (r2 for short). Package managers tend to ship really old r2 versions. In this case it's probably fine, I added the pickle arch to r2 a long time ago. But if you run into any bugs I suggest installing from source. In

## Choosing between with() and run()

DevFeed: [Choosing between with() and run()](<https://devfeed.tech/articles/choosing-between-with-and-run-25032.md>)

Original publisher: [Read original article](<https://typealias.com/guides/choosing-between-with-and-run/>)

Author: author@typealias.com (Dave Leeds)

Published: 2017-09-14T01:23:30Z

Content type: comparison

Language: en

Sources: [Dave Leeds on Kotlin - typealias.com](<https://devfeed.tech/sources/dave-leeds-on-kotlin-typealias-com.md>)

Topics: [scope function](<https://devfeed.tech/topics/scope-function.md>)

Tags: [bytecode](<https://devfeed.tech/tags/bytecode.md>), [decompiler](<https://devfeed.tech/tags/decompiler.md>), [extension-function](<https://devfeed.tech/tags/extension-function.md>), [intellij](<https://devfeed.tech/tags/intellij.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [library](<https://devfeed.tech/tags/library.md>), [nulls](<https://devfeed.tech/tags/nulls.md>), [programming](<https://devfeed.tech/tags/programming.md>), [readability](<https://devfeed.tech/tags/readability.md>), [receiver](<https://devfeed.tech/tags/receiver.md>), [run](<https://devfeed.tech/tags/run.md>), [safe-call-operator](<https://devfeed.tech/tags/safe-call-operator.md>), [scope-functions](<https://devfeed.tech/tags/scope-functions.md>), [with](<https://devfeed.tech/tags/with.md>)

### AI overview

Kotlin's `with()` and receiver `run()` both expose the object as `this` inside the block and return the block's result; the excerpt says they compile almost identically. The key practical difference shown is that extension `run()` can be called with a safe-call (`?.`), so a null receiver skips the block and yields null. Passing a nullable value to `with()` still executes its block, so it does not provide the same null interception. The excerpt begins a readability discussion but cuts off before stating its conclusion.

### Source excerpt

In Kotlin's standard library, the Standard.kt file contains a number of scope functions that put a receiver object into a new scope as either this or as an argument (e.g., it). The with() function tends to be a bit of an outlier. The others are all extension functions, so they're invoked on an object. with(), on the other hand, takes its receiver (the object that it's operating upon) as an argument.