MCPcopy Index your code
hub / github.com/angr/angr

github.com/angr/angr @v9.2.222 sqlite

repository ↗ · DeepWiki ↗ · release v9.2.222 ↗
18,014 symbols 70,078 edges 1,521 files 4,188 documented · 23%
README

angr

Latest Release Python Version PyPI Statistics License

angr is a platform-agnostic binary analysis framework. It is brought to you by the Computer Security Lab at UC Santa Barbara, SEFCOM at Arizona State University, their associated CTF team, Shellphish, the open source community, and @rhelmot.

Project Links

Homepage: https://angr.io

Project repository: https://github.com/angr/angr

Documentation: https://docs.angr.io

API Documentation: https://docs.angr.io/en/latest/api.html

What is angr?

angr is a suite of Python 3 libraries that let you load a binary and do a lot of cool things to it:

  • Disassembly and intermediate-representation lifting
  • Program instrumentation
  • Symbolic execution
  • Control-flow analysis
  • Data-dependency analysis
  • Value-set analysis (VSA)
  • Decompilation

The most common angr operation is loading a binary: p = angr.Project('/bin/bash') If you do this in an enhanced REPL like IPython, you can use tab-autocomplete to browse the top-level-accessible methods and their docstrings.

The short version of "how to install angr" is mkvirtualenv --python=$(which python3) angr && python -m pip install angr.

Example

angr does a lot of binary analysis stuff. To get you started, here's a simple example of using symbolic execution to get a flag in a CTF challenge.

import angr

project = angr.Project("angr-doc/examples/defcamp_r100/r100", auto_load_libs=False)

@project.hook(0x400844)
def print_flag(state):
    print("FLAG SHOULD BE:", state.posix.dumps(0))
    project.terminate_execution()

project.execute()

Quick Start

Core symbols most depended-on inside this repo

join
called by 1334
angr/analyses/typehoon/simple_solver.py
add
called by 1039
angr/utils/orderedset.py
debug
called by 945
angr/sim_manager.py
eval
called by 593
angr/state_plugins/solver.py
next_atom
called by 554
angr/ailment/manager.py
get
called by 477
angr/analyses/stack_pointer_tracker.py
_expr
called by 429
angr/analyses/calling_convention/fact_collector.py
prep
called by 374
angr/analyses/analysis.py

Shape

Method 14,279
Class 2,760
Function 966
Route 9

Languages

Python100%

Modules by API surface

angr/sim_type.py331 symbols
angr/analyses/decompiler/structured_codegen/rust.py319 symbols
angr/analyses/decompiler/structured_codegen/c.py302 symbols
angr/ailment/expression.py297 symbols
angr/engines/light/engine.py278 symbols
tests/analyses/decompiler/test_decompiler.py233 symbols
angr/calling_conventions.py220 symbols
angr/engines/pcode/behavior.py151 symbols
angr/analyses/cfg/cfg_fast.py146 symbols
angr/rust/sim_type.py137 symbols
angr/ailment/statement.py131 symbols
angr/knowledge_plugins/cfg/spilling_cfg.py129 symbols

Dependencies from manifests, versioned

GitPython
angr-data0.1.0 · 1×
archinfo9.2.222 · 1×
cachetools
capstone5.0.6 · 1×
cffi1.14.0 · 1×
claripy9.2.222 · 1×
cle9.2.222 · 1×
cxxheaderparser
lmdb2.1.1 · 1×
mulpyplexer
platformdirs

For agents

$ claude mcp add angr \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact