Rizin
unix-like reverse engineering framework and cli tools
|
Go to the source code of this file.
Macros | |
#define | RO_META (1 << 0) |
#define | MAX_CLASS_NAME_LEN 256 |
#define | FAST_DATA_MASK 0x00007ffffffffff8UL |
#define | METHOD_LIST_FLAG_IS_SMALL 0x80000000 |
#define | METHOD_LIST_FLAG_IS_PREOPT 0x3 |
#define | METHOD_LIST_ENTSIZE_FLAG_MASK 0xffff0003 |
#define | RO_DATA_PTR(x) ((x)&FAST_DATA_MASK) |
#define FAST_DATA_MASK 0x00007ffffffffff8UL |
Definition at line 12 of file mach0_classes.c.
#define MAX_CLASS_NAME_LEN 256 |
Definition at line 9 of file mach0_classes.c.
#define METHOD_LIST_ENTSIZE_FLAG_MASK 0xffff0003 |
Definition at line 19 of file mach0_classes.c.
#define METHOD_LIST_FLAG_IS_PREOPT 0x3 |
Definition at line 18 of file mach0_classes.c.
#define METHOD_LIST_FLAG_IS_SMALL 0x80000000 |
Definition at line 17 of file mach0_classes.c.
#define RO_DATA_PTR | ( | x | ) | ((x)&FAST_DATA_MASK) |
Definition at line 21 of file mach0_classes.c.
#define RO_META (1 << 0) |
Definition at line 8 of file mach0_classes.c.
|
static |
Definition at line 178 of file mach0_classes.c.
References rz_bin_symbol_t::classname, rz_bin_symbol_t::name, read_name(), and strdup().
Referenced by get_method_list_t().
|
static |
Definition at line 873 of file mach0_classes.c.
References free(), len, off, rz_str_ndup(), rz_str_newf(), s, skip(), skipnum(), and strdup().
Referenced by get_category_t(), get_class_name(), and get_class_ro_t().
RZ_API void MACH0_() get_category_t | ( | mach0_ut | p, |
RzBinFile * | bf, | ||
RzBuffer * | buf, | ||
RzBinClass * | klass, | ||
RzSkipList * | relocs, | ||
objc_cache_opt_info * | oi | ||
) |
Definition at line 1445 of file mach0_classes.c.
References reloc_t::addr, bits(), c, demangle_classname(), found, get_method_list_t(), get_objc_property_list(), get_protocol_list_t(), i, len, mach0_ut, NULL, p, r, read_ptr_va(), read_str(), relocs(), RO_DATA_PTR, rz_buf_read_at(), RZ_FREE, RZ_LOG_ERROR, rz_read_ble(), rz_return_if_fail, rz_skiplist_find(), rz_str_get_null(), rz_str_newf(), rz_str_startswith(), sc, and va2pa().
Referenced by classes(), and parse_categories().
Definition at line 911 of file mach0_classes.c.
References rz_bin_info_t::big_endian, rz_bin_object_t::bin_obj, demangle_classname(), free(), if(), rz_bin_object_t::info, len, mach0_ut, malloc(), MAX_CLASS_NAME_LEN, NULL, rz_bin_file_t::o, p, r, rz_buf_read_at(), RZ_LOG_ERROR, RZ_MIN, rz_read_ble(), sc, rz_bin_file_t::size, strdup(), ut64(), and va2pa().
Referenced by get_class_t().
|
static |
Definition at line 1006 of file mach0_classes.c.
References rz_bin_info_t::big_endian, rz_bin_object_t::bin_obj, demangle_classname(), free(), get_ivar_list_t(), get_method_list_t(), get_objc_property_list(), get_protocol_list_t(), i, if(), rz_bin_object_t::info, len, mach0_ut, malloc(), MAX_CLASS_NAME_LEN, rz_bin_class_t::name, NULL, rz_bin_file_t::o, p, r, RO_META, rz_buf_read_at(), RZ_LOG_ERROR, RZ_MIN, rz_read_ble(), s, sdb_fmt(), sdb_num_set(), sdb_set(), rz_bin_file_t::size, strdup(), ut64(), and va2pa().
Referenced by get_class_t().
RZ_API void MACH0_() get_class_t | ( | mach0_ut | p, |
RzBinFile * | bf, | ||
RzBuffer * | buf, | ||
RzBinClass * | klass, | ||
bool | dupe, | ||
RzSkipList * | relocs, | ||
objc_cache_opt_info * | oi | ||
) |
Definition at line 1127 of file mach0_classes.c.
References reloc_t::addr, c, found, get_class_name(), get_class_ro_t(), get_isa_value(), i, len, MACH0_(), mach0_ut, p, r, relocs(), RO_DATA_PTR, rz_buf_read_at(), RZ_LOG_ERROR, RZ_LOG_INFO, rz_read_ble(), rz_skiplist_find(), rz_str_startswith(), sc, strdup(), autogen_x86imm::tmp, ut64(), and va2pa().
Referenced by classes(), and parse_classes().
|
static |
Definition at line 1122 of file mach0_classes.c.
Referenced by get_class_t().
|
static |
Definition at line 192 of file mach0_classes.c.
References rz_bin_info_t::big_endian, rz_bin_object_t::bin_obj, calloc(), error(), rz_bin_class_t::fields, i, if(), rz_bin_object_t::info, len, MACH0_(), mach0_ut, malloc(), MAX_CLASS_NAME_LEN, memset(), name, rz_bin_class_t::name, rz_bin_field_t::name, NULL, rz_bin_file_t::o, rz_bin_field_t::offset, p, r, rz_bin_field_free(), rz_buf_read_at(), RZ_FREE, rz_list_append(), rz_list_prepend(), rz_list_sort(), RZ_LOG_ERROR, RZ_MIN, RZ_NEW0, rz_read_ble(), rz_str_newf(), rz_bin_file_t::size, rz_bin_field_t::size, sort_by_offset(), strdup(), type, rz_bin_field_t::type, va2pa(), and rz_bin_field_t::vaddr.
Referenced by get_class_ro_t().
|
static |
Definition at line 516 of file mach0_classes.c.
References rz_bin_info_t::big_endian, rz_bin_object_t::bin_obj, copy_sym_name_with_namespace(), error(), free(), i, if(), rz_bin_object_t::info, is_thumb(), len, regress::m, MACH0_(), mach0_ut, malloc(), MAX_CLASS_NAME_LEN, memset(), rz_bin_symbol_t::method_flags, METHOD_LIST_ENTSIZE_FLAG_MASK, METHOD_LIST_FLAG_IS_PREOPT, METHOD_LIST_FLAG_IS_SMALL, rz_bin_class_t::methods, name, NULL, rz_bin_file_t::o, p, r, rz_bin_symbol_t::rtype, RZ_BIN_METH_CLASS, RZ_BIN_TYPE_FUNC_STR, RZ_BIN_TYPE_METH_STR, rz_buf_read_at(), RZ_FREE, rz_list_append(), RZ_LOG_ERROR, RZ_MIN, RZ_NEW0, rz_read_ble(), objc_cache_opt_info::sel_string_base, rz_bin_file_t::size, st32, ST32_MAX, st64, strdup(), autogen_x86imm::tmp, rz_bin_symbol_t::type, va2pa(), and rz_bin_symbol_t::vaddr.
Referenced by get_category_t(), get_class_ro_t(), and get_protocol_list_t().
|
static |
Definition at line 375 of file mach0_classes.c.
References rz_bin_info_t::big_endian, rz_bin_object_t::bin_obj, calloc(), error(), rz_bin_class_t::fields, if(), rz_bin_object_t::info, len, MACH0_(), mach0_ut, malloc(), MAX_CLASS_NAME_LEN, memset(), rz_bin_class_t::name, NULL, rz_bin_file_t::o, p, r, rz_buf_read_at(), RZ_FREE, rz_list_append(), RZ_LOG_ERROR, RZ_MIN, RZ_NEW0, rz_read_ble(), rz_str_newf(), rz_bin_file_t::size, strdup(), and va2pa().
Referenced by get_category_t(), and get_class_ro_t().
|
static |
Definition at line 717 of file mach0_classes.c.
References rz_bin_info_t::big_endian, rz_bin_object_t::bin_obj, get_method_list_t(), i, if(), rz_bin_object_t::info, len, MACH0_(), mach0_ut, malloc(), MAX_CLASS_NAME_LEN, memset(), rz_bin_class_t::name, NULL, rz_bin_file_t::o, p, pc, pl, r, rz_buf_read_at(), RZ_FREE, RZ_LOG_ERROR, RZ_MIN, rz_read_ble(), rz_str_newf(), rz_bin_file_t::size, strdup(), and va2pa().
Referenced by get_category_t(), and get_class_ro_t().
Definition at line 121 of file mach0_classes.c.
References rz_bin_object_t::bin_obj, if(), and rz_bin_file_t::o.
Referenced by add_sub(), adr(), arg(), assemble(), bl(), get_method_list_t(), il_unconditional(), ldr(), and tbb().
struct MACH0_ | ( | SCategory | ) |
struct MACH0_ | ( | SClass | ) |
Definition at line 1 of file mach0_classes.c.
struct MACH0_ | ( | SClassRoT | ) |
Definition at line 1 of file mach0_classes.c.
struct MACH0_ | ( | SIVar | ) |
struct MACH0_ | ( | SIVarList | ) |
Definition at line 1 of file mach0_classes.c.
struct MACH0_ | ( | SMethod | ) |
Definition at line 1 of file mach0_classes.c.
struct MACH0_ | ( | SMethodList | ) |
Definition at line 1 of file mach0_classes.c.
Referenced by get_class_t(), get_ivar_list_t(), get_method_list_t(), get_objc_property_list(), get_protocol_list_t(), parse_categories(), and parse_classes().
struct MACH0_ | ( | SObjcProperty | ) |
Definition at line 1 of file mach0_classes.c.
struct MACH0_ | ( | SObjcPropertyList | ) |
Definition at line 1 of file mach0_classes.c.
struct MACH0_ | ( | SProtocol | ) |
Definition at line 1 of file mach0_classes.c.
struct MACH0_ | ( | SProtocolList | ) |
Definition at line 1 of file mach0_classes.c.
|
static |
Definition at line 1368 of file mach0_classes.c.
References rz_bin_object_t::bin_obj, error(), rz_bin_class_t::fields, get_category_t(), get_sections(), i, MACH0_(), mach0_ut, rz_bin_class_t::methods, rz_bin_class_t::name, NULL, p, read_ptr_pa(), relocs(), rz_bin_class_free(), RZ_FREE, rz_list_append(), rz_list_free(), rz_list_new(), rz_list_newf(), RZ_LOG_ERROR, RZ_NEW0, rz_return_val_if_fail, sections(), and ut64().
Referenced by parse_classes().
RZ_API RzList* MACH0_() parse_classes | ( | RzBinFile * | bf, |
objc_cache_opt_info * | oi | ||
) |
Definition at line 1243 of file mach0_classes.c.
References rz_bin_class_t::fields, get_class_t(), get_relocs(), get_sections(), i, len, MACH0_(), mach0_ut, rz_bin_class_t::methods, needs_rebasing_and_stripping(), new_rebasing_and_stripping_buf(), NULL, p, parse_categories(), PFMT64d, relocs(), rz_bin_class_free(), rz_buf_free(), rz_buf_read_at(), RZ_FREE, rz_list_append(), rz_list_free(), rz_list_new(), rz_list_newf(), RZ_LOG_ERROR, RZ_NEW0, rz_read_ble(), rz_return_val_if_fail, rz_str_newf(), sections(), and ut64().
Referenced by classes().
Definition at line 1570 of file mach0_classes.c.
References rz_bin_info_t::big_endian, rz_bin_object_t::info, len, mach0_ut, rz_bin_file_t::o, out, p, rz_buf_read_at(), rz_read_ble(), and rz_return_val_if_fail.
Referenced by parse_categories(), and read_ptr_va().
Definition at line 1588 of file mach0_classes.c.
References mach0_ut, out, read_ptr_pa(), rz_return_val_if_fail, and va2pa().
Referenced by get_category_t().
|
static |
Definition at line 1598 of file mach0_classes.c.
References calloc(), len, mach0_ut, MAX_CLASS_NAME_LEN, name, NULL, p, rz_buf_read_at(), RZ_FREE, RZ_LOG_ERROR, RZ_MIN, rz_return_val_if_fail, and va2pa().
Referenced by get_category_t().
Definition at line 131 of file mach0_classes.c.
References addr, rz_bin_object_t::bin_obj, rz_bin_object_t::boffset, if(), mach0_ut, NULL, rz_bin_file_t::o, p, r, rz_bin_plugin_mach, rz_return_val_if_fail, and s.
Referenced by get_category_t(), get_class_name(), get_class_ro_t(), get_class_t(), get_ivar_list_t(), get_method_list_t(), get_objc_property_list(), get_protocol_list_t(), read_ptr_va(), and read_str().