Commit Graph

960 Commits

Author SHA1 Message Date
Nibble
a7d6fc0cc7 * Detect bin sizes in dyld cache plugin 2010-10-01 13:22:37 +02:00
Nibble
48dd408e45 * Merge
* Minor fixes in r_bin
2010-10-01 11:58:11 +02:00
pancake
8081f02601 * Fix uninitialized variable in rabin2
* Fix null pointer handling in rbin when no xtr plugin found
* Initial draft code for the x86 debug registers implementation
* Fix avr* command
2010-10-01 11:10:59 +02:00
Nibble
41bd2fd0ea * rabin2
- Show filesize in '-x' output
  - Select "sub-bin" using '-a arch_bits' and '-n filename'
* r_bin
  - Add argument "name" to r_bin_set_arch
2010-10-01 10:09:50 +02:00
Nibble
4b558bec3b * rabin2 -x uses filename.arch_bits as output file
* store full path in dyld cache filenames
2010-10-01 08:12:43 +02:00
Nibble
987d8599f9 * Initial implementation of the RBin extractor for dyld cache
* Add bin_xtr_dyldcache to plugins.def.cfg
* Show bin name in the output of 'rabin2 -A'
* Minor fix in rabin_list_archs() in rabin2
2010-10-01 04:26:52 +02:00
Nibble
e02c81ddf1 * r_core
- Minor fixup in r_core_asm_strsearch
* vapi
  - Add asmsearch.vala
  - Some updates
2010-09-30 20:55:20 +02:00
Nibble
df9434b1ec * Make r_core_asm_strsearch more API-friendly
- return RList of RCoreAsmHit's
  - Add helpers for list handling
* Add type RCoreAsmHit
* Show hit code as comment with '/c', eg:
    [0x00402350]> "/c jmp e; ret"
    f hit0_0 @ 0x004078e8   # jmp eax; ret 0xffbc;
    f hit0_1 @ 0x00409416   # jmp ebx; ret 0x8b48;
    f hit0_2 @ 0x0040ded4   # jmp ecx; retf ;
* Update r_core vapi
2010-09-30 19:25:47 +02:00
Nibble
4369761655 * Fix typo in printf 2010-09-28 19:57:02 +02:00
Nibble
7d1303292e * r_anal
- Fix segfault in anal_x86_x86im (64bits)
  - always show analysis warnings
* r_core
  - Fix /a output
2010-09-28 18:52:46 +02:00
Nibble
697490a661 * r_core
- Implement 'ar' commands
  - Show XREFS in disassembly
* r_anal
  - Add r_anal_xref_get
2010-09-28 18:05:31 +02:00
Nibble
eb811bbf08 * r_core
- Deprecate ah and add anal.plugin
  - e anal.plugin=? list available plugins
  - Add the command 'ar' to handle refs/xrefs
  - Remove old CX and Cx stuff
  - Remove afg (done by af)
* r_anal (& r_meta)
  - Remove refs/xrefs stuff from r_meta
  - Handle refs from r_anal
  - Add r_anal_ref_{add, del}
* rabin2
  - Add 'e anal.plugin' to the output of rabin2 -Ir
2010-09-28 13:58:03 +02:00
pancake
3ef71b106a * Indentation fixes in rax2 as discused in chat
* Fix compilation of vapi/r_bin
* Some mods in test programs for swig/python
2010-09-26 03:18:04 +02:00
Nibble
0a09b20cc0 * rabin2
- Make -A output more verbose
  - Dump all archs with -x when no one is specified using -a
* cleanup TODO
2010-09-25 12:33:30 +02:00
Nibble
333fbbf55b * rabin2
- Set arch with 'rabin2 -a arch_bits filename'
  - Remove flag -B
  - Implement extract (-x)
2010-09-25 03:45:03 +02:00
Nibble
e5bc46da65 * Update r_anal with the changes introduced in r_bin 2010-09-24 21:30:33 +02:00
Nibble
483ab6160b Apply @earada's patch (thx!)
* Improving rax2
  - Support for many bases.
  - Add -s flag for transform byte to bin (ej: "48454c4c4f" to "HELLO")
  - Add -e flag for endian swap.
* New r_num_to_bits converts nums into binary representation.
2010-09-24 21:25:23 +02:00
Nibble
793dae395d * Massive refactoring of r_bin
- Add support for fatbins (currently only fatmach0)
  - Minimize creation of r_buffers
* rabin2
  - Add flag -A for listing archs
  - Add flags -a and -B for selecting arch
  - In the next commit -A and -B will be removed and -a will work
    with the following format:
    [-a arch bits] for selecting arch
	[-a] for listing them

--HG--
rename : libr/bin/p/bin_fatmach0.c => libr/bin/p/bin_xtr_fatmach0.c
2010-09-24 21:23:13 +02:00
pancake
d71fcd2708 * Do not show color prompt in windows
* Fix build on w32
* Finish the symgraph script
2010-09-24 19:04:33 +02:00
pancake
124786c1ac * Added 'drd' command to show only modified regs
* Added r_list_foreach_prev()
* Add RSyscallPort to handle Hardware I/O ports
* Remove libr/TODO and refactor /TODO
* Link with 'ld' in rarc2-tool for nasm
2010-09-24 16:45:56 +02:00
pancake
54677585c2 * Added support for 'nasm' in rarc2 (-n) 2010-09-24 06:10:20 +02:00
pancake
eb6dbb2245 * Initial draft implementation of hardware breakpoints
- use specific ptrace() calls in linux/freebsd to change regs
  - hwbp are not yet working, just basic DRX get/set
  - generic interface to handle hw bps in x86-32/64
  - needs to import DR# handling code from r1
2010-09-24 05:41:54 +02:00
pancake
84dd63b743 * Add 'bf' command to change block size based on flag size
- Added help in 'b?'
* Added support for bit-collection registers
  - eflags is now displayed as a string
  - debug/p/debug_native.c needs a correct x86 flag string
* Fix segfault when listing empty register sets
2010-09-24 04:09:39 +02:00
pancake
46aa9f5f7e * Implement stacked register storage
- Add support for register diffing
  - Colorize modified registers are step/cont
  - Add command 'dro' to show old register values
  - requires make clean
2010-09-23 20:42:35 +02:00
Nibble
cbdfff3dda * Minor fixup in anal_x86_x86im
- swapped dst src in *_MM_RG
2010-09-23 13:56:08 +02:00
Nibble
69d08e1514 * Huge refactoring of x86_x86im using r_anal_value
- next step is integrate it in the analysis engine and deprecate old stuff
* Add field "imm" (immediate value) to RAnalValue
2010-09-23 13:25:46 +02:00
pancake
022e6c96f0 * Add pt command for print times (Thanks @earada for the patch)
- pt prints times in unix format
  - ptd prints times in dos format
  - ptn prints times in ntfs format
* Add cfg.datefmt in global config to define the format output of 'pt'
2010-09-23 12:59:54 +02:00
Nibble
49dceaaffd * More work on anal_x86_x86im refactoring 2010-09-22 18:31:15 +02:00
pancake
b339189b5f * Added r_reg_arena_set and r_reg_cmp in order to implement regdiffing
* Added R_DBG_REASON enums
2010-09-20 14:02:45 +02:00
pancake
1356a9bdd1 * Highlight destination offset when cursor on jmp/call in visual
* Show call decompilations under the opcode as a comment
* Rename RRegister as RReg
  - Deprecate r_reg_init and use r_reg_new
  - Rewrite the list.h dependency in r_reg in order to use r_list
  - Fix some memory leaks
* Implement push/pop methods in RReg class
  - add test case using it
  - will be used for register diffing and tracing
2010-09-18 02:51:17 +02:00
pancake
90a2b9f84a * Initial support for multiple arguments in rarc2 for ARM
- Some more fixes in the ARM emitter backend
  - Single quoted strings are now supported, not filtered
  - Fix math opcode names for ARM
  - Added support for /**/ and // comments
* Fix makefile for test programs in rarc2/t
  - Added simple hello world for tests in rarc2/t
2010-09-16 20:44:22 +02:00
Nibble
441456767a * Fix define types in r_types_base.h
- now swig assigns const types correctly in go bindings
  - simplify fixgoswig.sh while the patch I've done for
    swig adding iterators support is not commited
2010-09-16 13:20:35 +02:00
Nibble
3b6a4a1475 * Add swig/go/fixgoswig.sh script
- Add iterators
  - Fix bug with ut64 consts
  - These issues must be fixed in swig
2010-09-15 19:25:14 +02:00
pancake
6072a14eef * Simplify and fix rarc2-tool script
* Add support for /**/ style comments in rarc2
* Fix libr2.a warning message
* Fix .string "" directive in rasm2
  - Now works like in GAS. escape chars are handled
  - and quotes are stripped
2010-09-15 13:10:10 +02:00
pancake
9b2d428d1b * Initial hello world for rarc2 in ARM with GAS working
- Few changes needed to work with rasm
* Cleanup some warnings
* Handle foo() as a function definition, so emit frame in rarc
2010-09-15 10:50:43 +02:00
pancake
1b1599c6df * Support for some push/pop arm opcodes with 2 regs
* More fixes for rarc2 on ARM
* Implement .fill directive in r_asm
* Added asm.profile in r_core
* Added r_str_bits as a helper to display register flags
2010-09-14 11:22:31 +02:00
pancake
a9f8d52e59 * Many fixes in ARM assembler and rarc2 support for ARM
- Still not yet usable, but
* Add .byte and .hex in r_asm as directives
* Add test case for r_word api
  - Fix r_word_count()
* Also handle .globl (and .global) to keep GAS compatibility
  - TODO: add .word .fill .align and others
2010-09-14 01:29:09 +02:00
Nibble
45daf51358 * Minor fixup in go Makefile
- Fix build for x86
  - Add support for arm
2010-09-13 21:16:25 +02:00
Nibble
609723eab7 * Make test-r_bin.go more generic
* Fix typo in swig/Makefile
2010-09-12 13:33:20 +02:00
Nibble
283a624136 * Minor fixup in swig/go/Makefile 2010-09-12 12:47:13 +02:00
Nibble
5733497a0b * Add bindings for go
* Add swig/go/test-r_bin.go for testing r_bin from go
* Fix build for r_bp and r_search bindings
* Rename enum VarType to VarClass in r_anal.vapi to avoid conflicts
* Add flag -R to rabin_cmd in r2 start up
2010-09-12 12:31:18 +02:00
pancake
f4ada2309f * Handle numeric values as radix=10 by default in ollyasm
- Fixes rarc ATT output format for x86
* Fix commandline flags parsing in rarc2
  - Honor intel syntax with ".intel_syntax noprefix" header
    - GAS can now compile att and intel syntax rarc2 output
* Handle .intel_syntax and .att_syntax directives in rasm2
2010-09-10 13:17:24 +02:00
Nibble
09f5ca50a6 * Minor fixup in r_bin_elf 2010-09-10 11:46:30 +02:00
Nibble
159165fa13 * Add vapi/t/reloc.vala
- Print address for each relocation entry
* Update r_bin.vapi
* Minor fixup in r_bin_elf_get_relocs()
* Update TODO
2010-09-10 11:32:49 +02:00
Nibble
5567da9538 * Add support for parsing relocs to r_bin
* Add flag -R to rabin2 to list relocs
* Implement reloc resolution in r_bin_elf for 32 & 64 bits
2010-09-10 11:11:38 +02:00
pancake
2d2131607c * Error on invalid hexpair strings in rasm2
* Fix assemble of str/ldr opcodes in ARM assembler
  - add more opcodes: nop, push, pop
2010-09-10 10:50:53 +02:00
Nibble
b344f96e21 * More work on r_bin_mach0
- Parse local symbols
  - Resolve non-lazy symbol pointers
  - Set import type to FUNC or OBJECT
  - Refactoring of get_imports
  - Add field type to r_bin_mach0_{import, symbol}
2010-09-10 01:17:55 +02:00
pancake
45c7167491 * Add r_sys_cmdf 2010-09-10 00:08:53 +02:00
pancake
76476e89ed * Many fixes and more opcodes supported for the ARM assembler 2010-09-09 23:54:56 +02:00
pancake
a7e77e78ee * More work on the arm assembler 2010-09-09 01:39:15 +02:00