Commit Graph

206 Commits

Author SHA1 Message Date
pancake
bcf7d46e36 Fix #1726 - ESIL brainfuck is back (and fix io.maps test case) - Thanks @trndr 2014-11-23 22:44:38 +01:00
pancake
9a0d62da22 Finally remove the void*debug pointer from RIOPlugin (use bool isdbg) 2014-11-21 11:36:51 +01:00
pancake
b736119a4a Colorize S=, Add anal.gp and better op.refs for mips and x86
- Add anal.gp to make mips.cs code analysis happy
- S= honors scr.color
- Fixed x86(capstone,udis) memrefs for mov/cmp
2014-11-07 03:48:27 +01:00
pancake
8c43eddaa2 Honor io.va and scr.width in S= 2014-11-06 03:02:38 +01:00
pancake
1eccc191e0 Fix the r2 -d oo issue with more referer fields 2014-11-04 10:30:28 +01:00
pancake
3c6ae9ed33 Add r_io->referer 2014-11-03 10:47:02 +01:00
condret
c8c276f2cd add r_io_map_list 2014-10-22 11:04:37 +02:00
condret
43e8d3ab0e add r_io_reopen 2014-10-20 13:34:04 +02:00
condret
051de62f9e add r_io_desc_list (possibly useful for bughunting) 2014-10-17 18:31:59 +02:00
pancake
da866539ee Fix 'oo' bug (sync rcorefile and riofile lists), Better 'ob' 2014-10-17 00:04:52 +02:00
pancake
42232354a7 Add 'ai' - address info, Enhace 'ad' (support patterns and sequences)
- ai shows: exec,read,write,flag,func,stack,heap,reg
- Add r_reg_regset_get()
- Implement r2.cmdj in r2.js
2014-10-15 02:24:22 +02:00
pancake
67acee60f9 Better 'wc' command and cache/history capabilities 2014-10-07 02:52:47 +02:00
condret
ab4a5c9632 deprecate RCoreFile->uri 2014-09-25 18:18:07 +02:00
pancake
196cfd0534 Initial major cleanup of the RAnal module 2014-09-22 01:39:24 +02:00
pancake
4c4173769b Revert "Fixing the issue where file size exceeds size of an integer":
3adb00621b
e2afa84443
0761955fdb
17cc18fad0
135c62fb5d
2014-09-20 15:33:59 +02:00
condret
977c3834a2 add r_io_is_valid_offset and r_core_is_valid_offset 2014-09-18 21:28:02 +02:00
deeso
3adb00621b Fixing the issue where file size exceeds size of an integer 2014-09-17 23:53:25 +02:00
condret
f4a1b0a3bd fix #1366 and make r_io_close keeping the current desc if it does not get close 2014-09-16 23:12:37 +02:00
condret
9ea7df3b67 implement r_io_mwrite // yum yum copy-pasta 2014-09-11 18:35:09 +02:00
condret
7ce6922491 rename r_io_open -> r_io_open_nomap and add a new r_io_open that creates a map at 0x0 2014-09-06 23:08:16 +02:00
condret
4ebeeff986 add r_io_open_at 2014-09-05 16:53:51 +02:00
pancake
30ca7913c6 Initial import of the io.gzip plugin 2014-09-05 14:47:35 +02:00
condret
aa318b4216 extend the io api and fix a bug in vio 2014-09-04 15:49:34 +02:00
condret
63718ae9c6 implement r_io_pwrite and vio debug define 2014-09-04 00:41:07 +02:00
pancake
3cfeec1d4e Fix r2 -B .. sets bin.laddr and honors va=2 2014-08-25 03:45:11 +02:00
pancake
8b74f1ffcf Merge Rarun2 into RSocket and use it from dbg.profile in Core 2014-07-09 02:24:31 +02:00
pancake
377b5bb2fe Clean a huge list of warnings 2014-06-25 02:07:38 +02:00
condret
129646d925 Refactor the new io-read-api (disabled by default) 2014-06-14 00:07:16 +02:00
condret
6b1efd8ecd Add R_ERROR and fix RIOSection.get_{first,in}_{vaddr,paddr}{_range} 2014-06-11 17:42:42 +02:00
pancake
84e1bc6eb5 Some fixes for the latest rsearch changes 2014-06-04 22:18:02 +02:00
condret
0f9495400d add io->autofd 2014-06-03 17:06:56 +02:00
condret
b75ea56f6c make r_io_desc_seek more reasonable in usage 2014-06-02 15:31:06 +02:00
condret
eafafa574e try to fix r_io_desc_seek 2014-06-02 00:54:32 +02:00
pancake
5e33a8a282 Initial huge refactoring of r_io still work in progress 2014-05-28 04:34:12 +02:00
pancake
7751882675 Add io.raw which is set when debugger mode is enabled 2014-05-25 02:23:33 +02:00
deeso
ccc3794eeb Fixed the 0xff io bug 2014-05-22 02:17:09 -05:00
pancake
c6a73d3074 Fix loading sections from fatmach0 bins 2014-05-16 03:48:57 +02:00
deeso
1fbc7f2168 Added load_bytes, Pushed curplugin down to RBinObj, Reworking the RBinFIle loading to accomodate RBinObj reworked how all bins are loaded. Needed to hack IO to make
this work with rbinfiles and rbinobjects.

Conflicts:
	libr/bin/bin.c
	libr/bin/p/bin_te.c
2014-05-13 21:54:18 -05:00
deeso
3adcb54f17 Overhauled how files are loaded. Now *all* files use an IO plugin the default one is mmap'ed 2014-05-01 20:13:57 -05:00
pancake
b49195f2df Fix lot of warnings 2014-04-28 11:53:22 +02:00
deeso
d5908941fb Steps toward fixing the reopen of a file being debugged 2014-04-24 18:21:40 -05:00
deeso
c6a7faad77 fixed the bug with the insane fuzz command 2014-04-22 23:06:00 -05:00
Adam Pridgen
8d994160b0 Java CP String rewriting works, add R_NEW0 to RIODesc macro 2014-03-27 14:08:56 -05:00
pancake
2397c956c9 Use R2_ as unique header guard prefix 2014-03-27 16:34:17 +01:00
pancake
d3af1ea077 Fix #723 - header guards conforming to C standards 2014-03-27 02:32:26 +01:00
Adam Pridgen
09fa5cf10c Added extend to io support, now files can be extended, b00y4! 2014-03-24 22:57:36 -05:00
pancake
90264229c9 Add Vo, fixes in $sys in RAsm, new io.self plugin, initial work on preloaded r2 2014-02-10 03:31:12 +01:00
Adam Pridgen
e6fe3354d9 Fixing coverity issues for io_zip, hanging caused by infinite loop in disasm.c,
and io map collisions (which adds file.loadalign, file.loadmethod (append or fail),
and file.suppresswarnings.
2014-01-25 23:48:22 -06:00
Adam Pridgen
70e832b35e Adding the option to open more than one file via a plugin. Now all the files in a zip can be loaded using zipall:// uri. 2014-01-23 21:51:39 -06:00
Adam Pridgen
415a77dca0 Java can now load multiple bins into radare space, and analyse the different bins.
See libr/bin/p.bin_java.c libr/anal/p/anal_java.c for the hacky details.
Fixed the coverity issue.
2014-01-12 17:36:47 -06:00
Adam Pridgen
bc2ee1f869 Improved plugin analysis allowing plugin developers to define custom
analysis algorithms.
Java analysis plugin is re-written to leverage this capability.
Added some new R_ANAL types, and some of the respective operations and strings.
Updated io-component files to get file size and info
2014-01-03 00:28:46 +01:00
pancake
a03dd04c42 Fix r_sys_pid_to_path for FreeBSD (thanks vsp) 2013-12-11 12:32:15 +01:00
pancake
bbe6e8c8a2 Add license to RBin, RDebug and RIO plugins 2013-12-10 04:19:04 +01:00
pancake
21c3e01ff5 Fix #389 - Fix segfault in ptrace://-1 2013-11-26 16:16:06 +01:00
pancake
a6f4dbca47 Fix #384 - Dupped filedescriptors 2013-11-23 02:44:06 +01:00
pancake
58870cff95 Fix r_io_desc_new macro. It was breaking support for multiple files 2013-11-19 03:02:26 +01:00
pancake
7112a7ded0 Fix r_io_desc_new issue 2013-11-15 00:04:17 +01:00
Adam Pridgen
532f420ffa Added fixes to load bins from IO Plugins and Fixed filename extraction so that IO Plugin names are respected instead of extracting then out of the URIs 2013-11-12 04:46:28 +01:00
pancake
497cb0e2e1 Fix #57 - 'is' does not work for attached process 2013-11-04 03:30:46 +01:00
pancake
e173008266 Fixes on io maps and fd descs 2013-10-11 03:11:15 +02:00
pancake
2cbce80f2f Add __cplusplus extern "C" boilerplate everywhere 2013-06-18 12:09:23 +02:00
pancake
bc0104563b Initial support for runtime versioned libraries
- This check will ensure you are running the latest r2 version.
2013-06-14 02:51:33 +02:00
pancake
96accbd14b Begin r_io review. Fix r_socket_http query for xpcshell's httpd.js
- Added libr/io/README in order to documentate the api
- Some minor refactoring and code cleanup in libr/io
- Fix hexdump title
2013-05-31 02:09:45 +02:00
pancake
189e5553cc Initial 8051 disasm and ihex:// io plugin 2013-04-09 20:05:36 +02:00
pancake
8f4d23a5ce Initial implementation of io.map plugin 2013-03-12 01:50:55 +01:00
pancake
60a951e9b1 New io.buffer cache system and refactorized RHashTable
Implement io.buffer for fast IO (work in progress)
Rewrite util/cache.c and use it form io/buffer.c
Refactor util/ht.c and util/ht64.c to reuse code
Various minor fixes in RIO api
cache.c must be rewritten into r_buf for
2013-01-12 04:29:45 +01:00
pancake
35808e31f8 Add io.zeromap to toggle old buggy mode doublemapping file to 0
Add http.maxsize to define the maximum file size to be uploaded
Add http.upget config var (not yet implemented)
2013-01-03 01:43:23 +01:00
pancake
475372ec2c Fix archbits in overlap mem, fixes for ad, pd and segmented addressing
Fix invalid wide string identification in 'ad' command
Temporal blocksize syntax ':' has changed to '!'
  - x @ 1024!33
Fix overlapped IO sections handling
Add support for segmented address in temporal seek
Fix disassemlby to print more lines than blocksize
2012-12-06 00:55:22 +01:00
pancake
7a0da18725 Add r_bin.rar plugin, per-section arch/bits, fix in S=
Add Sa to set/get per-section arch and bits configuration
Cache io->section and core->io->section to speed up the Sa
Update r_sys_arch*
Add dummy plugin in asm/rar
Fix lines of S=
2012-11-30 01:06:30 +01:00
pancake
1e52015eee Add px[QW], fix segmented io and handle ! pipes
Handle `!` with r_core_cmd_str_pipe
Fix 'afl' output
Add help for 'px' command
Add pxQ and pxW to show one word per line
Fix segmented io with maps and sections
Some test cases got fixed
Add test-r_anal.py
2012-10-25 12:55:28 +02:00
pancake
73a7b77306 Add 'omr' to relocate maps and rm libr/README 2012-10-25 09:48:45 +02:00
pancake
16e0c555e5 Add 'oo+' and 'o+' commands to reopen in read-write 2012-10-22 10:12:13 +02:00
pancake
3861772e6d Initial implementation of r_io.zip plugin
Allows to: r2 zip://foo.apk//classes.dex
Honor LDFLAGS in r_bin
Fix filename issue in r_io_redirect
Add testing on-activate event in r2w2
2012-09-07 03:26:38 +02:00
Anton Kochkov
e075a18b56 Types cleanups 2012-07-22 12:01:39 +04:00
pancake
41a230ddf7 Add p=?, rax2 suports negative values and more
- Support negative integer values in rax2
  - Fix column selection draw in r_print_hexdump
  - Implement p=p and p=e commants
  - Disallow visual insert if file is readonly
  - Similar to pZ, but
  - Honor -w flag to create file if possible
  - Use new r_io_create() api
  - Add scr.sparse to show hexdump in sparse mode
2012-07-06 02:17:44 +02:00
pancake
30354fefc8 * Implemented 'afe' and 'Sr' commands
* Show strings referenced by relative LEAs
* Fix ascii art in hexdump columns
* Unset cursor when quiting visual mod
2012-06-14 10:01:16 +02:00
pancake
33c914de7a * Visual keystrokes for dcu and dcr with cursor mode and sS
* Fix dcr (continue until ret)
* Add /x key:msk (':' separator)
2012-05-30 11:14:41 +02:00
pancake
637e8c92e5 * Fix MZ check() (fixes PE64+ id in r_bin)
* Add io->bits into RIO class
* OSX r_io debug now honors io->bits
  $ r2 -b 32 ls  # debug 32bit ls
  $ r2 -b 64 ls  # debug 64bit ls
2012-05-30 01:35:41 +02:00
pancake
beac4bbc24 * More fixes in the code analysis loops
* Properly detect end of functions in visual
* Apply rudi_s patches for cache
* Show push flag information if available as a comment
* Clear screen after quiting Visual
* Remove unused function
2012-02-16 01:26:50 +01:00
pancake
5fc05667d6 * Apply rudi_s patches
- libr/core/cmd.c: # ignores the complete line.
  - libr/io/undo.c: Improve seek undo/redo.
2012-02-15 11:13:05 +01:00
pancake
227c985a08 * Added 'om' command to create, destroy and list IO maps
* Upgrade configure script to acr 0.8.8
  - Use proper --libdir LDFLAGS for OSX
  - Honor CPPFLAGS
* Fix help msg of 'yt' command
* Use RList in r_io (rudi_s)
* Fix HOME/END keys in xrvt-unicode
* Add dummy install-cxx target in r2-bindings
2012-02-07 01:51:56 +01:00
pancake
f03e8674db * Fix -n help message as reported by rudi_s
* Oops fix build again
2012-02-03 16:23:14 +01:00
pancake
49b45b64ac * Fix undo and redo commands
* Fix some manpages typos reported by lintian
* Asm testcase now forces x86 arch and 32 bits
2011-12-05 08:27:16 +01:00
pancake
2646161b77 * Apply @earada's patch fixing undo/redo seek 2011-12-04 21:09:16 +01:00
earada
242f9c56d8 * RIOUndo now uses r_list API
* List mount points in radare commands use new syntax
* asm.bits triggers syscall_setup
* Fix null pointer dereference in RCore.bin_load
2011-11-15 23:26:45 +01:00
pancake
85f5829be6 * Make oxfoo1m3 crackme load correctly
- Do not find strings in binaries with no data sections
  - Add program header section underlaying the rest of sections
* Do not newline when gotoxy'ng
  - visual mode is now smarter
* New ? commands
  - ?p = show physical address
  - ?S = show section name for given address
* Initial refactoring in r_io to make section overlaps happy
  - Those changes are experimental and can lead to problems
  - Do not iterate prev
  - Do not sort by offset
2011-10-25 20:30:05 +02:00
pancake
bb904490dc * r2 -D now accepts a dbg.backend (dh) argument
- Fix segfault when accessing null r.file->fd->data
* Initial first working steps of the brainfuck debugger
* Add missing io.w32 plugin (untested)
  - Plugins that doesn't work on current platform are not listed
2011-10-08 12:10:30 +02:00
pancake
9efe88a9ce * Fix offbyone in asm.brainbuck bug
* Fix some segfaults and issues in r_magic
* Use the libr/socket/http library
* Added r_io_http plugin
* Magic search is extremely slow
2011-10-07 01:16:45 +02:00
pancake
12816468f6 * Refactoring of the TODO tasks
* Add dummy 'dca' command. needs to be implemented
* Reload all symbol information when io.va changes
* Only print jumpkey references in visual mode
* Reduce the autoblocksize in visual for disassembly
2011-09-03 03:10:01 +02:00
earada
f950675a7b * Add SSL support to rap protocol (raps://) 2011-08-16 02:55:46 +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
ca5e38d239 * Fix w32 and w64 build (r_fs/grub issue)
* Dont quit rax2 when reading from stdin until 'q' or ^D
* Minor fix in fortunes
2011-07-13 13:59:55 +02:00
pancake
814d220ac6 * Implement 'Cl' command to set sourceline comments
* Fix, implement and install rsc2
  - Added rsc2 srcline script
2011-05-25 15:43:54 +02:00
pancake
3f2677ab7f * Added initial untested support for native gdb debugger mode
- r2 -d gdb://<host>:<port>
  - register maps not yet implemented
  - some basic step/continue should work in cfg.debug=true
  - gdbwrap instance is shared between RIO and RDebug
* RDebug is now arch-sensitive
  - Plugins describe which architectures and register sizes are supported
  - Native debugger is restricted to local CPU
  - Remote debugger (GDB) arch can be specified with -e asm.arch=arm
* Fix some random warnings
* Move R_ASM_ARCH into R_SYS_ARCH
  - Helper functions to translate id to string and string to id
    are now in util/sys.c (r_util)
  - Move all R_SYS_* from r_util to r_types
    - Endianness, OS, CPU and regsize is now 'global'
2011-05-06 00:59:10 +02:00
earada
8d8faea38b * Use RList int io_sections
* Fix core_server return value
2011-04-19 14:43:48 +02:00
pancake
a16f3f27b4 * Implement S- command (remove sections)
- by index, offset or all (*)
* Fix block_read() issue with io.va
2011-04-19 00:59:16 +02:00
earada
450764d0c6 * Some fixes in the rap protocol 2011-04-17 20:58:32 +02:00
pancake
4fad96ecbb * Make r2-swig happy without valaswig
* Add r_io_raise() and use it in the 'o' command
  - Allow to raise the file handle priority
2011-02-16 09:29:09 +01:00
pancake
f950dcb33c * Add RIOMap in r_core_file_open
- RCore.file_open() now accepts one more arg for offset
  - Fix RIO api issues related to RIOMap and opening multiple files
  - Fix infinite loop and simplify design
  - Added test case to ensure it does not breaks
* Fix build of r_lang in OSX (thanks @capri_x)
* Remove debugging printfs
* io.ffio is now true by default
2011-02-12 01:52:41 +01:00
pancake
7bb5b2d46d * Many bugfixes in RIOMap handling and 'o' command
* Added util/bitmap (hashmap of bits)
2011-02-07 09:46:01 +01:00