class
Cradare2::Client
- Cradare2::Client
- Reference
- Object
Overview
The central client representing an open radare2 session.
Defined in:
cradare2/client.crcradare2/dsl/disasm.cr
Constructors
Instance Method Summary
-
#all_strings : Array(Model::StringItem)
Returns strings from the entire binary (izzj).
-
#analyze : DSL::Analysis
Access the Analysis DSL.
- #analyze(&block : DSL::Analysis -> ) : self
-
#close : Nil
Closes the radare2 session.
-
#closed? : Bool
Returns true if the session is closed.
-
#cmd(command : String) : String
Executes a command string in radare2 and returns the raw output string.
-
#cmdj(command : String, as type : T.class) : T forall T
Executes a command and deserializes the JSON string into the specified type
T. -
#cmdj(command : String) : JSON::Any
Executes a command and parses the returned JSON string as
JSON::Any. -
#crystal : CrystalHelper
Access the Crystal binary analysis and memory inspection helper.
- #crystal(&block : CrystalHelper -> ) : self
-
#current_offset : UInt64
Returns the current seek position / offset.
-
#debug : DSL::Debugger
Access the Debugger DSL.
- #debug(&block : DSL::Debugger -> ) : self
-
#demangle(symbol : String) : String
Demangles a symbol using radare2 and internal caching.
-
#disasm : DSL::Disassembly
Access the Disassembly DSL.
-
#exports : Array(Model::Export)
Returns exported symbols (iEj).
-
#exports_matching(pattern : Regex | String) : Array(Model::Export)
Filters exports matching a substring or regex pattern.
-
#find_function(name : String) : Model::Function | Nil
Finds a specific function by name.
-
#find_symbol(name : String) : Model::Symbol | Nil
Finds a specific symbol by name or display name.
-
#functions : Array(Model::Function)
Returns analyzed functions (aflj).
-
#functions_matching(pattern : Regex | String) : Array(Model::Function)
Filters functions matching a substring or regex pattern.
-
#imports : Array(Model::Import)
Returns imported symbols (iij).
-
#imports_matching(pattern : Regex | String) : Array(Model::Import)
Filters imports matching a substring or regex pattern.
-
#info : Model::BinaryInfo
Returns binary metadata (ij).
-
#memory : DSL::Memory
Access the Memory DSL.
- #memory(&block : DSL::Memory -> ) : self
-
#quit : Nil
Alias for close.
-
#sections : Array(Model::Section)
Returns binary sections (iSj).
-
#security : Model::SecurityInfo
Evaluates binary security mitigations (ASLR, DEP/NX, Stack Canary, Relocations).
-
#seek(target : UInt64 | Int32 | Int64 | String) : self
Seeks to the specified target address or symbol (s
). -
#strings : Array(Model::StringItem)
Returns strings in data sections (izj).
-
#strings_matching(query : String) : Array(Model::StringItem)
Filters strings matching a substring.
-
#symbols : Array(Model::Symbol)
Returns all symbols in the binary (isj).
-
#symbols_matching(pattern : Regex | String) : Array(Model::Symbol)
Filters symbols matching a substring or regex pattern.
- #transport : Transport::Base
-
#xrefs_from(address : UInt64 | Int32 | Int64 | String) : Array(Model::Xref)
Returns cross-references originating from the specified address or symbol (axfj @
). -
#xrefs_to(address : UInt64 | Int32 | Int64 | String) : Array(Model::Xref)
Returns cross-references targeting the specified address or symbol (axtj @
).
Constructor Detail
Instance Method Detail
Executes a command string in radare2 and returns the raw output string.
Executes a command and deserializes the JSON string into the specified type T.
Executes a command and parses the returned JSON string as JSON::Any.
Filters exports matching a substring or regex pattern.
Finds a specific symbol by name or display name.
Filters functions matching a substring or regex pattern.
Filters imports matching a substring or regex pattern.
Evaluates binary security mitigations (ASLR, DEP/NX, Stack Canary, Relocations).
Seeks to the specified target address or symbol (s
Filters strings matching a substring.
Filters symbols matching a substring or regex pattern.
Returns cross-references originating from the specified address or symbol (axfj @
Returns cross-references targeting the specified address or symbol (axtj @