Commit Graph

346 Commits

Author SHA1 Message Date
radare
7060103292
Improve RBuffer api, start to refactor rbin to use more rbuf ##bin (#12495)
- Added a new rule in the DEVELOPERS.md file
2018-12-17 11:54:46 +01:00
dav1901
5b644dcb74 Minor cleanups/fixes (#12478) 2018-12-14 00:17:50 +01:00
dav1901
a6b44e03fe Fix warnings (#12309) 2018-11-25 01:46:57 +01:00
Riccardo Schirone
300844fa51 Introduce RBinArchOptions to avoid creating fake RBinFile/Objects ##bin 2018-11-22 15:14:37 +01:00
David CARLIER
3d830a3832 Couple of leak fixes 2018-11-15 16:34:11 +01:00
Riccardo Schirone
79edcb32f5
Make sure only one RBinObject is created for each RBinFile (#12169) 2018-11-15 11:44:46 +01:00
Riccardo Schirone
90058945d2 Remove "referenced" from RBinObject and remove get_object ##refactoring 2018-11-13 13:05:18 +01:00
Riccardo Schirone
08e5b4aaad Refactoring RBin.open/close and RBinOptions ##bin
* r_bin_close should be r_bin_file_close
* moved bin/open.c into bin.c
* set BinFile id in r_bin_load_io
* use r_bin_open_io instead of r_bin_load_io
* also prefer RBinOptions instead of multiple arguments
* rename r_bin_load to r_bin_open and use RBinOptions
2018-11-07 17:22:41 +01:00
Riccardo Schirone
6115f00455
remove r_bin_load_io2 and rename MODE defines ##refactor
PR #11888 

* bin: no need for 2 r_bin_load_io APIs
* bin: remove io-related unused functions
* r_bin.h: remove some old comments
* r_bin.h: group together related APIs
* extract print/set modes in r_types, to remove dups in r_bin and r_core
* clang-format-diff: fix ternary operator indent for pancake
2018-10-24 16:54:57 +02:00
Riccardo Schirone
64d16fc506 Some code cleanup and asserts in RBin ##refactor
* libr/bin: no need to allocate RBinOptions on the heap
* bin: start using r_return_* around, that's just the beginning
* bin: remove io_owned since it's not used anywhere
* io: make r_io_bind return nothing
* bin: remove unused functions and simplify r_bin_load_io
r_bin_load_io was calling r_bin_load_io2 with UT64_MAX as sz parameter,
but r_bin_load_io2 just returns false if (st64)sz is less than 0, so
that call is actually useless and can be removed.
* bin/bin: fix some preconditions
* bin/open: fix precondition to check for bin and filename too
2018-10-21 01:27:15 +02:00
radare
f7be81edbb
Fix instruments leaks (#11695)
* Fix a small memleak in the disasm reflines
* Fix huge args leaks in r_parse for arm
* Fix another memleak
* Fix memleak in VR
* Fix memleak related to bad use of r_list_join
* Fix warnings
* Fix two rlist related asserts
2018-10-01 19:57:33 +02:00
bannsec
8b6feae97b Memleak (#11688)
* Memleak

Guessing this is where the free should go... Ref #11687
2018-10-01 09:14:11 +02:00
David CARLIER
79871d4164 Fix #11671 (#11673)
Using macro for regex module too.
2018-09-27 11:16:44 -07:00
pancake
41ec949204 Fix #11112 - Rename {srwx,flags,perms} to perm. (-21 LOC)
Unify R_IO, R_BIN, R_BP, .. into R_PERM_* using 1 letter syntax
2018-09-22 11:31:45 +02:00
pancake
d34ada1a05 Minor fixes for mach0 signature parsing, fix crash in ae? and other null derefs 2018-09-18 11:06:00 +02:00
David CARLIER
acdb507945 core file: fix couple of leaks (#11571) 2018-09-18 13:16:44 +08:00
Neven Sajko
4a722e80d8 Add braces to if, else, for, while ... (#11504) 2018-09-13 10:17:26 +02:00
radare
4bb4a2ce30
Parse CodeSign blobs and compute sha1/sha256 in mach0 binaries (#11491)
- rabin2 -OC # wip requires proper refactoring and redesign
2018-09-12 16:03:36 +02:00
pancake
1875a7f4f0 Add error handling in ?x- 2018-09-02 15:58:13 +02:00
Neven Sajko
d8784641ee Add parentheses in macros where needed for safety (#11290) 2018-08-30 13:16:50 +02:00
Fangrui Song
08e6ed3b78 Fix some -Wincompatible-pointer-types-discards-qualifiers warnings (#10951) 2018-08-07 11:50:06 +02:00
Anton Kochkov
5b5667138c Fix UB and UAF 2018-08-07 13:00:06 +08:00
JohnPeng47
ab92677eda Add pemixed plugin 2018-08-06 01:22:11 +02:00
Khairul Kasmiran
943ebfebd5 Fixed typo in rabin2 usage help 2018-07-24 22:53:02 +08:00
Khairul Kasmiran
dfa196ddd2 Revert "End rabin2 json output with newline"
This reverts commit 40c68d9ec0.
2018-07-22 21:32:32 +08:00
Khairul Kasmiran
2d83bb2a26 entries->initfini for ieej/rabin2 -ee -j since former key is already used 2018-07-18 19:33:12 +02:00
Khairul Kasmiran
40c68d9ec0 End rabin2 json output with newline 2018-07-16 14:09:22 +02:00
Riccardo Schirone
7572f315ea
meson improvements (#10617)
* meson.build: fix meson build when not on git
* meson.build: make capstone a dependency
* meson.build: make r_magic library optional
* meson.build: capstone include is already in the dependency
* meson.build: use dependencies instead of manual linking + includes
* meson.build: add travis
* flag/meson.build: include sdb dependency
* travis-script: print messages based on install system
* io/meson.build: add sdb as dependency
* syscall/meson.build: missing sdb dependency
* {parse,config}/meson.build: add sdb dependency
* travis.yml: pass INSTALL_SYSTEM var to docker
* {bin/shlr}/meson.build: add sdb_dep to r2java and bin
* install meson and ninja-build in r2-travis docker
* travis.yml: allow meson build to fail for now
* anal/meson.build: add sdb and java dependencies
* egg/meson.build: add sdb dependency
* travis.yml: meson build env should be also in the includes list
* core/meson.build: add java dep
* meson.build: use dependencies also to create main r2 dependency
* rasm2/meson.build: replace link_with with dependencies
* rasm2/meson.build: add sdb as dependency
* meson.builds: convert link_with to dependencies and fix tabs
* travis-script: change meson install prefix and set PKG_CONFIG_PATH
* travis-script: add lib64 to LD_LIBRARY_PATH
2018-07-09 16:58:38 +02:00
Rene Laemmert
d11473201a Started changing bin_load to bin_open (#10221) 2018-06-20 16:19:22 +02:00
Khairul Kasmiran
09a6a26b16 Remove more trailing spaces 2018-06-19 10:42:01 +08:00
Florian Märkl
a5b3ff9486 Make izz more task-safe (#10373) 2018-06-17 15:12:54 +02:00
Khairul Kasmiran
b1a982cc24 Added -ee to rabin2 -g 2018-06-15 23:57:17 +02:00
Khairul Kasmiran
f472a9c1e1 Make equiv flags for rabin2 -g more future-proof 2018-06-14 17:55:44 +02:00
Khairul Kasmiran
a685f9303f Fix rabin2 -g help 2018-06-10 04:51:31 +02:00
Khairul Kasmiran
e2e9c993a3 Moved segments from iS/'rabin2 -S' to iSS/'rabin2 -SS' 2018-06-10 03:30:25 +02:00
radare
d461644977
Add --with-libr and deprecate --with-{nonpic,pic,merged} (#10212) 2018-05-28 17:14:49 +02:00
pancake
8a765610b3 Fix rabin2 eprintf regression 2018-05-28 11:52:07 +02:00
pancake
3d6efce76d Fix #10207 - Use r_cons_print instead of printf 2018-05-28 11:10:30 +02:00
pancake
5578d8d1ae Implement iO as a frontend for !rabin2 -O 2018-05-09 23:25:03 +02:00
Paul I
5180e0220f Add R2_PLUGINS, R2_EXTRAS, R2_BINDINGS macros (#9994) 2018-05-02 15:58:14 +02:00
Paul I
cc90ec6be5 [WIP] Move hardcoded paths to r_userconf.h (#9959)
* Move hardcoded paths to r_userconf.h

* Add R2_HOME_* macros

* Some cleanup
2018-04-28 10:02:55 +02:00
Paul I
bb4f61580e Cleanup meson files (#9424) 2018-02-20 09:33:19 +01:00
pancake
047d672898 Hide crashes when dlopen on unix in rabin2 -Q 2018-02-18 03:49:19 +01:00
Rafael Rivera
3031324be3 Initial e dbg.symstore support (#9338) 2018-02-09 11:34:09 +01:00
sivaramaaa
74a5b55925 Honor *q in izzz 2018-01-12 10:02:22 +01:00
pancake
b27326e891 Kill RCoreFile from rabin2 2018-01-10 13:53:53 +01:00
pancake
7f40f36c3a Initial draft implementation of the loader plugins for RBin 2018-01-07 21:54:41 +01:00
pancake
0a1181515d Make constructor/destructors available only via rabin2 -ee (and iee in r2) 2017-10-30 18:31:01 +01:00
pancake
de86371355 PDB_SERVER is now RABIN2_PDBSERVER 2017-10-30 12:46:33 +01:00
condret
e2d096f411 small beautification 2017-08-27 20:22:58 +00:00