Commit Graph

1686 Commits

Author SHA1 Message Date
pancake
1424bf9701 * Initial support for 'jb' opcode in x86.nz
- hello.r now is broken because of this use
  - Ignore prefixed '$' in numeric values for r_egg
* Apply @capi_x's patch fixing a bug in 'wb' and rsc/msdn
2011-08-11 17:41:24 +02:00
pancake
c53a78bd88 * Add ragg2 -F (-f native)
- Uses pe on w32, mach0 on osx and elf everywhere
* Apply msdn rsc2 script fixes from capi_x
* Remove comments from ragg2/t/hello.r
2011-08-10 15:42:54 +02:00
pancake
b3cefac08b * Make while() and .var0-= statements work in r_egg lang
- Added support for 'add|sub [reg+delta],n' opcodes in x86.nz
* Add emit_init() function pointer to fix entrypoint issues
  - ebp has no valid value defined on entrypoints
2011-08-10 11:24:15 +02:00
pancake
168d38fc44 * Add rax2 -x to calculate string hash
* Use trim to avoid noisy chars in symbol names for egg/lang
* Properly handle osx/w32 os strings in r_egg
* Make string construction works in r_egg
* Initial work on while() constructs
2011-08-09 11:06:50 +02:00
pancake
06e98dadb1 * Add -k flag to ragg2 - select kernel
- ATM only support for linux and osx
  - Do not show asm when -f is passed
  - Added 3 test programs for osx/linux in ragg2
* Add support for 'lea' opcode in x86.nz
  - Support more 'mov [off], reg' opcodes
  - Lot of new test cases in test.nz
* Fix some segfaults and parsing bugs in egg/lang

--HG--
rename : binr/ragg2/exithello.r => binr/ragg2/t/exithello.r
2011-08-09 02:03:12 +02:00
pancake
1f48797bfb * Fix test reg, reg; mov reg, [reg] ; mov reg, [reg+off] in x86.nz
* First hello world working with ragg2 on linux-x86-32
  - Named exithello.r .. run cd binr/ragg2 ; make test
2011-08-09 00:10:12 +02:00
pancake
1733e6d8a9 * Use r_bin from ragg2 to create ELF/PE/MACH0 bins 2011-08-08 15:00:42 +02:00
pancake
429a475ac0 * Deprecate rarc2 and rarc2-tool
- Replaced by ragg2 - the new r_egg based tool for r2
* Add r_egg_assemble as a 2nd step for compilation
* Fix memory leak in r_egg_free
* Add support for 'cmp' and more 'test' variants for x86.nz
  - Ignore 'dword ptr' string
  - More test cases
* Fix SCSIZE issue in rasc2 -s

--HG--
rename : binr/rarc2/Makefile => binr/old.rarc2/Makefile
rename : binr/rarc2/README => binr/old.rarc2/README
rename : binr/rarc2/config.def.h => binr/old.rarc2/config.def.h
rename : binr/rarc2/config.h => binr/old.rarc2/config.h
rename : binr/rarc2/emit_arm.c => binr/old.rarc2/emit_arm.c
rename : binr/rarc2/emit_x64.c => binr/old.rarc2/emit_x64.c
rename : binr/rarc2/emit_x86.c => binr/old.rarc2/emit_x86.c
rename : binr/rarc2/i/libc.r => binr/old.rarc2/i/libc.r
rename : binr/rarc2/i/socket.r => binr/old.rarc2/i/socket.r
rename : binr/rarc2/osxtest.r => binr/old.rarc2/osxtest.r
rename : binr/rarc2/out.c => binr/old.rarc2/out.c
rename : binr/rarc2/rarc2-tool => binr/old.rarc2/rarc2-tool
rename : binr/rarc2/rarc2.c => binr/old.rarc2/rarc2.c
rename : binr/rarc2/rarc2.h => binr/old.rarc2/rarc2.h
rename : binr/rarc2/t/Makefile => binr/old.rarc2/t/Makefile
rename : binr/rarc2/t/argv.r => binr/old.rarc2/t/argv.r
rename : binr/rarc2/t/bytedump.r => binr/old.rarc2/t/bytedump.r
rename : binr/rarc2/t/data.r => binr/old.rarc2/t/data.r
rename : binr/rarc2/t/dump.r => binr/old.rarc2/t/dump.r
rename : binr/rarc2/t/hello.r => binr/old.rarc2/t/hello.r
rename : binr/rarc2/t/hi.r => binr/old.rarc2/t/hi.r
rename : binr/rarc2/t/if.r => binr/old.rarc2/t/if.r
rename : binr/rarc2/t/inline.r => binr/old.rarc2/t/inline.r
rename : binr/rarc2/t/input.r => binr/old.rarc2/t/input.r
rename : binr/rarc2/t/loop.r => binr/old.rarc2/t/loop.r
rename : binr/rarc2/t/ptr.r => binr/old.rarc2/t/ptr.r
rename : binr/rarc2/t/rawsys.r => binr/old.rarc2/t/rawsys.r
rename : binr/rarc2/t/rawsys64.r => binr/old.rarc2/t/rawsys64.r
rename : binr/rarc2/t/regs.r => binr/old.rarc2/t/regs.r
rename : binr/rarc2/t/ret.r => binr/old.rarc2/t/ret.r
rename : binr/rarc2/t/room.r => binr/old.rarc2/t/room.r
rename : binr/rarc2/t/segfault.r => binr/old.rarc2/t/segfault.r
rename : binr/rarc2/t/shell.r => binr/old.rarc2/t/shell.r
rename : binr/rarc2/t/sub.r => binr/old.rarc2/t/sub.r
rename : binr/rarc2/t/syscall.r => binr/old.rarc2/t/syscall.r
rename : binr/rarc2/test.r => binr/old.rarc2/test.r
rename : libr/egg/t/syscall.r => binr/ragg2/syscall.r
2011-08-08 02:07:26 +02:00
pancake
d99fbd7680 * Fix make mrproper
* Initialize {code,data}_offset to 0
2011-08-08 00:54:00 +02:00
pancake
df8fb6cc21 * Store last .text/.data address in RAsmCode->{code,data}_offset
* Lot of fixups in x86.nz for better 64bit support
  - More opcodes are now supported (mov [base+delta], etc..)
* Make r_egg hello world work with x86.nz.
  - fixed some bugs in the rarc2 language parser
  - egg/t/test aims to be rarc2 replacement
  - rarc2 lang code seems to compile fine now,
  - r_egg now depends on r_syscall
* Fix null pointer in RNum
2011-08-08 00:46:04 +02:00
pancake
9c2397a994 * Use x86.nz in egg for rarc2
- Adds support for 64bit eggs
2011-08-07 03:53:41 +02:00
pancake
08e37c7a2b * Pass lot of more opcode assembler tests for x86.nz plugin 2011-08-07 03:31:27 +02:00
pancake
e812ab57f1 * Add capi's shellcode for x86-64 OSX (tested on Lion)
- fork+wait+execve(/bin/sh)
2011-08-07 01:47:17 +02:00
earada
677fe55587 * Fix some memleaks 2011-08-06 20:44:59 +02:00
pancake
094c4eb8bd * Added support for lot of opcodes in x86.nz asm plugin
- Added t/test.nz script to ensure assembler works
2011-08-06 01:33:47 +02:00
pancake
839f71e937 * Initial import of the asm.x86.nz plugin
- Very few instructions can be assembled
  - Aims to assemble code with no zeros
* Added xorencoder.asm test file
2011-08-05 00:34:45 +02:00
earada
475a57aa48 * Add rap metainfo support
* Fix memleak at r_fs (Thanks @ajaragoneses)
* Add directory dump support at r_fs shell
2011-08-04 21:28:07 +02:00
pancake
63917198b6 * Check empty optind arg to -d 2011-08-04 12:22:24 +02:00
pancake
1e060082a4 * Remove debug printf 2011-08-04 00:34:39 +02:00
pancake
82b93ffa88 * Rewrite buggy bash r_str_sub and rename as r_str_replace
- Fixes segfault in OSX
  - Fixes r_asm with .equ stuff
2011-08-04 00:33:04 +02:00
pancake
aad2e91d96 * Initial import of asm.x86.as plugin
- Uses OSX/GNU/BSD 'as' assembler
2011-08-03 21:01:56 +02:00
pancake
860e608d23 * Fix build.. :( 2011-07-27 17:41:35 +02:00
pancake
dc93b16f7b * Minor work on egg and rasc 2011-07-27 10:30:23 +02:00
pancake
deced01103 * Fix build of rasc2 2011-07-27 01:41:35 +02:00
pancake
7595fe8aa3 * Add missing r_egg.h
* Fix r_egg for ARM
2011-07-27 01:29:22 +02:00
pancake
26a070f5aa * Initial import of r_egg api
- Implements rarc2 as a library
  - Supports x86-32/64 and arm
  - WIP inline-egg like api
* Add radiff2 -x to dump two column output
2011-07-27 01:16:18 +02:00
pancake
8e5fa68ec5 * Fix build for osx 10.7 (with openssl) 2011-07-26 16:27:21 +02:00
pancake
259d14940e * Implement R_SEARCH_DELTAKEY
- Accessible with /d search command
* Code cleanup in TinyPE
* Implement rasc2 -o
2011-07-26 09:34:10 +02:00
pancake
dd8e7430dc * Initial implementation of the PE creation support for rabin2 -c
- Creates a Tiny PE executable for w32 (100 bytes)
2011-07-26 01:13:51 +02:00
pancake
041751e029 * Added osxtest.r and adapt rarc2-tool to support rasm2 and rabin2 -c
- rarc2-tool can now create tiny executables!
* Fix segmentation fault in bad use of r_bin_create api
2011-07-26 00:30:45 +02:00
pancake
a6b94842f3 * Add universal rop shellcode for osx-x86-64 in rasc2
- https://github.com/pakt/exp-dev/tree/master/osx.dyld.rop
2011-07-25 23:54:37 +02:00
pancake
d2cf5e4425 * Import chmod() from sbase as r_file_chmod()
- Support recursive chmod
  - Handles string-based octal/expression formats
  - Used by rabin2 -c to chmod +x the created binary
2011-07-25 23:42:39 +02:00
pancake
a173eedcaf * Added support for ELF32-linux-x86 binaries for rabin2 -c
- Allow to create tiny elf binaries (only text section)
  $ rabin2 -a x86_32 -c elf:31c040bb2a000000cd80 a.out
* Added api for 16 and 64 uint write in RBuffer
2011-07-25 23:20:49 +02:00
pancake
8d06dd2f02 * Initial implementation of rabin2 -c
- Allow to create tiny binaries with r_bin
  - ATM only MACH0 format for x86-32 is supported
  $ ./rabin2 -a x86_32 -c mach0:31c040682a00000081ec04000000cd80 a.out
* Rename r_bin_set_arch{idx} to r_bin_select{idx}
  - New API r_bin_create and r_bin_use_arch()
2011-07-25 21:10:25 +02:00
earada
1c1a307edc * Support sockets in FreeBSD's 'dd' command 2011-07-25 20:17:19 +02:00
pancake
fde9168bd4 * Remove linking dependencies in radiff2 as reported by Debian
* Use -v instead of -V in rasm2 too
2011-07-25 12:22:55 +02:00
earada
25b590e21f * Implemented 'dd' command for UNIX and FreeBSD 2011-07-25 04:49:54 +02:00
earada
bff20dd916 * Add 8/16/32 bits register definitions in linux/x86_64
* Fix r_syscall_reg, to show syscall params correctly
2011-07-22 13:33:43 +02:00
pancake
9f35e4fd33 * Theorical build fix for OpenBSD/arm/sparc64 2011-07-22 11:29:58 +02:00
pancake
5292c61a48 * Handle syscall name/number resolution in 'asl' and 'dcs' commands
- Thanks @pof for noticing! :D
2011-07-21 19:17:15 +02:00
pancake
6072a57548 * Release 0.8.1 -- butterybiscuitbase
* Fix FreeBSD-amd64 and GNU/kFreeBSD debugger
2011-07-21 01:11:25 +02:00
pancake
1503b4955c * Enforce the use of BSD tar 2011-07-21 00:50:16 +02:00
pancake
a5bafc9257 * Some minor work on mips64 debugger
* r2-bindings configure help updated
2011-07-21 00:32:39 +02:00
pancake
8219630fcb * Update configure help and fix warning in debug_native 2011-07-20 23:55:05 +02:00
pancake
2d0fd88d3d * Fix debugger build in {Open|Net}BSD 2011-07-20 23:25:39 +02:00
pancake
79b581f597 * Avoid ^C in gitpush 2011-07-20 21:43:45 +02:00
pancake
627871eac2 * Fix build for GNU/kFreeBSD 2011-07-20 17:34:00 -04:00
pancake
553ac83d91 * Added __KFBSD__ define and enable new proc/maps for GNU/kFreeBSD
* Do not install rsc2 stuff
2011-07-20 19:26:07 +02:00
earada
af3f41765a * FreeBSD debug maps now uses sysctl api
* Fix some BSD build warnings
2011-07-20 17:58:50 +02:00
earada
f7146bd0ef * Fix (Free|Net)BSD native debug and register definition
* Fix build on FreeBSD (Thanks capi_x)
2011-07-19 20:01:47 +02:00