ROSE
0.11.109.0
|
Facilities for detecting variables in binaries.
Classes | |
class | BaseVariable |
Describes a local or global variable. More... | |
class | GlobalVariable |
Description of a global variable. More... | |
class | StackFrame |
Information about a stack frame. More... | |
class | StackVariable |
Description of a local stack variable within a function. More... | |
class | VariableFinder |
Analysis to find variable locations. More... | |
Typedefs | |
using | VariableFinderPtr = Sawyer::SharedPointer< VariableFinder > |
Reference counting pointer. More... | |
typedef Sawyer::Container::Set< rose_addr_t > | AddressSet |
Set of addresses. More... | |
typedef std::map< int64_t, AddressSet > | OffsetToAddresses |
Mapping from stack offsets to address sets. More... | |
typedef std::map< rose_addr_t, AddressSet > | AddressToAddresses |
Mapping from addresses to address sets. More... | |
typedef Sawyer::Container::Interval< int64_t > | OffsetInterval |
Interval of signed offsets. More... | |
using | StackVariables = Sawyer::Container::IntervalMap< OffsetInterval, StackVariable > |
Collection of local variables organized by frame offsets. More... | |
typedef Sawyer::Container::IntervalMap< AddressInterval, GlobalVariable > | GlobalVariables |
Maps virtual addresses to global variables. More... | |
Functions | |
void | initDiagnostics () |
Initialize diagnostic output. More... | |
std::string | offsetStr (int64_t offset) |
Format a stack offset as a string. More... | |
std::string | sizeStr (uint64_t size) |
Format size as a string. More... | |
void | print (const StackVariables &, const Partitioner2::Partitioner &, std::ostream &out, const std::string &prefix="") |
Print info about multiple local variables. More... | |
void | print (const GlobalVariables &, const Partitioner2::Partitioner &, std::ostream &out, const std::string &prefix="") |
Print info about multiple global variables. More... | |
Variables | |
Sawyer::Message::Facility | mlog |
Diagnostic facility. More... | |
using Rose::BinaryAnalysis::Variables::VariableFinderPtr = typedef Sawyer::SharedPointer<VariableFinder> |
Reference counting pointer.
Definition at line 135 of file BinaryAnalysis/BasicTypes.h.
typedef Sawyer::Container::Set<rose_addr_t> Rose::BinaryAnalysis::Variables::AddressSet |
Set of addresses.
Definition at line 30 of file Variables.h.
typedef std::map<int64_t , AddressSet> Rose::BinaryAnalysis::Variables::OffsetToAddresses |
Mapping from stack offsets to address sets.
Definition at line 33 of file Variables.h.
typedef std::map<rose_addr_t , AddressSet > Rose::BinaryAnalysis::Variables::AddressToAddresses |
Mapping from addresses to address sets.
Definition at line 36 of file Variables.h.
Interval of signed offsets.
Definition at line 39 of file Variables.h.
using Rose::BinaryAnalysis::Variables::StackVariables = typedef Sawyer::Container::IntervalMap<OffsetInterval, StackVariable> |
Collection of local variables organized by frame offsets.
Definition at line 267 of file Variables.h.
typedef Sawyer::Container::IntervalMap<AddressInterval, GlobalVariable> Rose::BinaryAnalysis::Variables::GlobalVariables |
Maps virtual addresses to global variables.
The global variable will be represented in the map at all addresses that the global variable could occupy. E.g., if global variable "g1" starts at 0x4000 and can be up to 1k 4-byte integers, then a record will exist in the map at all addresses from 0x4000 (inclusive) to 0x4100 (exclusive).
Definition at line 352 of file Variables.h.
void Rose::BinaryAnalysis::Variables::initDiagnostics | ( | ) |
Initialize diagnostic output.
This is called automatically when ROSE is initialized.
std::string Rose::BinaryAnalysis::Variables::offsetStr | ( | int64_t | offset | ) |
Format a stack offset as a string.
std::string Rose::BinaryAnalysis::Variables::sizeStr | ( | uint64_t | size | ) |
Format size as a string.
void Rose::BinaryAnalysis::Variables::print | ( | const StackVariables & | , |
const Partitioner2::Partitioner & | , | ||
std::ostream & | out, | ||
const std::string & | prefix = "" |
||
) |
Print info about multiple local variables.
This output includes such things as the function to which they belong and the defining instructions. The output is multi-line, intended for debugging.
void Rose::BinaryAnalysis::Variables::print | ( | const GlobalVariables & | , |
const Partitioner2::Partitioner & | , | ||
std::ostream & | out, | ||
const std::string & | prefix = "" |
||
) |
Print info about multiple global variables.
This output includes such things as their addresses, sizes, and the defining instructions. The output is multi-line, intended for debugging.
Sawyer::Message::Facility Rose::BinaryAnalysis::Variables::mlog |
Diagnostic facility.