Commit Graph

2031 Commits

Author SHA1 Message Date
pancake
57c68c752c
Fix #16389 - r2r -qv and r2 -v to show version and quiet versions (#16472) ##tools 2020-04-08 13:56:52 +02:00
Florian Märkl
6d633a96a9
Run Fuzz Tests with r2r (#16456) 2020-04-07 13:27:19 +02:00
Florian Märkl
5c31876093
R2R for Windows (#16410) ##test 2020-04-06 17:40:46 +02:00
Florian Märkl
0ab6296238
Add Timeout to R2R.c (#16371) ##test 2020-04-02 19:16:49 +02:00
radare
5a1df188f6
Build fixes to make emscripten builds happy (#16406) ##build 2020-04-02 17:52:03 +02:00
pancake
a87fdf66ee Fix duplicated function signatures in RCore spotted by Emscripten 2020-04-02 15:53:31 +02:00
Florian Märkl
73983b3759
Fix a leak in r2r (#16402) 2020-04-02 12:35:02 +02:00
Anton Kochkov
80690c3b57 Remove wrongly committed r2r binary 2020-04-01 11:43:14 +08:00
radare
6379317f57
Add LZMA-BE magic signatures ##search 2020-03-31 21:17:02 +02:00
pancake
12a925c685 Fix warnings and solve the Gitlab CI 2020-03-31 17:06:40 +02:00
pancake
304bc367de Initial support for test categories and fix the windows build ##test 2020-03-31 15:58:49 +02:00
pancake
2c40d164b5 r2r new flags: -n to not run -v for version, add manpage ##tests 2020-03-31 15:58:49 +02:00
pancake
66d3ece161 Fix windows build 2020-03-31 15:58:49 +02:00
Paul I
044947c885
r2r: handle CRLF in readline() (#16378) 2020-03-31 15:39:44 +02:00
kuqadk3
ad88c78944
Implement hex.offset config variable to hide address column from hex-dump (#16373) ##print 2020-03-31 14:44:23 +02:00
Florian Märkl
e3dd6674d6
Fix Log Mode in R2R (#16379) 2020-03-31 13:47:41 +02:00
Florian Märkl
e4581a68d3
Drop empty args in r2r (#16376) 2020-03-31 13:47:32 +02:00
Florian Märkl
31f0e46f96
Add Log Mode to R2R (#16368) 2020-03-31 02:29:27 +02:00
Florian Märkl
9c8c8889f8
Check harder if jq works in R2R (#16370) 2020-03-31 02:25:02 +02:00
radare
202269c620
Autodetect dbdir in r2r.c (#16365) ##test 2020-03-30 23:32:38 +02:00
pancake
cfc1c663c3 Fix parameters order when running r2 tests 2020-03-30 15:00:26 +02:00
pancake
e4781c7820 Show execution time in r2r 2020-03-30 15:00:26 +02:00
Florian Märkl
2a9d7e9d44
Much more R2R (#16352)
* Add r2r to R2BINS
* Fix iSj. trailing newline
* Dedup default worker count in r2r
* Fix some more Tests
* Decide archos in r2r
* Add more args and run json tests with r2r
2020-03-29 21:04:51 +02:00
Florian Märkl
2c7ecc9736
Even more R2R (#16348)
* Fix r2r without FILE
* Fix many tests for r2r-c
* Pipe stdin in r2r to make isatty() return false
* Fix a leak in r2r
* Fix lock usage in RThread
* Always print stderr on failed tests
* Break broken zip tests
* Add -j arg to r2r
* Temporarily disable some tests that js and v don't parse
* Fix ar= trailing newline
2020-03-29 18:07:44 +02:00
Florian Märkl
141ae9d0a1
More R2R in C (#16338)
* Fix r2r coverities (Fix #16330)
* Fix SIGCHLD Handling in r2r
* Fix ARGS in r2r
* Make r2r fail on parse errors
* Support multiple files in r2r and print cmd
* Make r2r print exit status
2020-03-29 11:32:21 +02:00
radare
5e4cdaaa04
Always use r_getopt, do not depend on libc (not just on windows) ##core (#16325) 2020-03-27 17:06:40 +01:00
radare
9f35d62018
Improve noreturn and aesu times, show it in afi & afij ##anal (#16324)
* Fix fcn->is_noreturn cache and add tests
2020-03-27 06:15:47 +01:00
Florian Märkl
04e257bd47
R2R in C Enhancements (#16310) ##test
* Skip extras dirs in r2r by default
* Fix BROKEN loading in r2r
* Print actual diff in r2r-c
* Fix some tests for r2r-c
* Do not require stdout if not specified in r2r-c
* Address most review comments
2020-03-27 06:13:41 +01:00
radare
8758fa6b40
Remove the --without-r2r configure flag (#16300) 2020-03-25 21:41:26 +01:00
Florian Märkl
79fcf4fbff
Initial Implementation of R2R in C (#16216) ##test 2020-03-24 20:18:16 +01:00
pancake
1953d46950 'sign' as an alias for ios-sign and macos-sign ##build 2020-02-26 02:07:13 +01:00
pancake
d2b29db4c9 Remove globals from rax2 ##refactor 2020-02-17 16:52:28 +01:00
Anton Kochkov
e11b2a9145
Some Coverity defect fixes (#15626) 2019-12-13 11:25:19 -06:00
dok
34e4bd7291 Use sigaction instead of signal ##core 2019-11-06 12:41:36 +01:00
Florian Märkl
aad2a2c79e Link sdb fully into r_util in meson (#15338) ##build 2019-10-23 15:52:19 +02:00
pancake
f2d76b16cd Switch to travis-ci.com 2019-10-10 20:04:02 +02:00
pancake
c059b6e177 radare -> radareorg 2019-09-28 00:30:09 +02:00
Khairul Azhar Kasmiran
a8a42f149f Fix for r2pm when libdir is lib64/ (#15101) 2019-09-23 00:13:59 +02:00
Khairul Azhar Kasmiran
18ef593b2e Set rpath if non-Windows Meson shared ##build (#15051) 2019-09-22 10:49:54 +02:00
Khairul Azhar Kasmiran
0587b7f6d7 R2PM_TGZ: If 2nd param starts with /, assume it's root dir of archive (#15033) 2019-09-13 21:44:16 +02:00
Khairul Azhar Kasmiran
25fd8c6baf Ensure R2PM_BINDIR exists (#15032) 2019-09-13 18:29:33 +02:00
v45k0
c4fa10f628 Add info that r2pm -i is also used for pkg update (#14998)
It is confusing that `r2pm update` only updates the database
and the packages are not updated. Information about
how to update a specific package is missing.
When the user searches for information how to update a particular package,
e.g. using `r2pm -h`, the help provides information only how to
install a package.
2019-09-09 22:44:24 +02:00
pancake
72df7056f5 Use LTO for the Cydia build 2019-08-22 20:22:11 +02:00
pancake
5b87871294 Shrink the Cydia package from 512mb to only 64 ##build 2019-08-22 19:26:03 +02:00
pancake
8b37ac49b6 Add capstone dependency with the mk 2019-08-01 05:23:56 +02:00
radare
c93c094c40
Fix android-static ##build 2019-08-01 04:39:40 +02:00
radare
c816961571
Use RFlag.list() instead of .get() avoid false positives (#14735) 2019-08-01 04:38:56 +02:00
Ian Huang
8248039e55 r2pm: handle info and install arguments properly (#14693) 2019-07-30 04:20:28 +02:00
radare
56cdeee666
Added val op hints to let the user define jmptbl sizes ##anal 2019-07-07 18:51:21 +02:00
radare
dc0892a1a0
Towards emscripten build fix (update sdb) ##build 2019-07-07 16:52:41 +02:00
Florian Märkl
e19ca424f5 Fix Warnings 2019-06-21 12:18:32 +02:00
pancake
8926d2733b Fix r2pm -H output 2019-06-20 14:09:09 +02:00
pancake
69e13b5a51 Honor the 2nd arg of R2PM_TGZ with ZIP files ##r2pm 2019-06-20 13:48:56 +02:00
Anton Kochkov
b22d9f3065 Fix grammar across the code 2019-06-18 14:51:30 +08:00
radare
77c043c582
Implement r2p r2pipe commandline tool and !* as an alias for #!pipe (#14336) 2019-06-17 10:34:04 +02:00
pancake
75cd2b8d2b Add r2preload demo program 2019-05-28 23:15:59 +02:00
pancake
169baf362c Fix ios_sign 2019-05-13 12:43:50 +02:00
pancake
dce703d88b Fix static linking 2019-04-02 16:02:31 +02:00
pancake
4cae6b6558 Fix Android build and a lonely warning 2019-04-02 15:50:19 +02:00
pancake
3d0eb2eeee Fix makefile issue 2019-04-02 15:40:51 +02:00
radare
82416b0212
Create libr_main and make all binaries use it ##core
* Cleanup the use of getopt with our wrapper
2019-03-08 14:22:59 +01:00
Vasilij Schneidermann
e39c9424aa Make -x behave like /x unless mask is provided ##search 2019-03-05 20:28:31 +01:00
pancake
a3bb6132ba Implement rasm2 -x to output in hex dwords ##asm
$ rasm2 -x 'nop;nop;mov eax, 33;push ebx;int 0x80;nop;mov rbx,48484;nop'
	0x21b89090 0x53000000 0x489080cd 0xbd64c3c7 0x00900000

As suggested in https://twitter.com/travisgoodspeed/status/1101966927688318978
2019-03-03 02:51:55 +01:00
Riccardo Schirone
afae8b6e34
Prerelease travis release (#13189)
* Add additional tests for release/prereleases
* Test different plugins configurations
* Add some libraries to docker image
* Disable SYS_CAPSTONE for now because there is only 3.0.5
* Fix html magic file to respect libmagic's format too

< can be used with string so it should be escaped if we want to match
the exact string "<html>"

* Use plugin License when printing rasm2 plugins in JSON format
* Build with system capstone, but do not run tests because they would fail
* Fix tiny plugins file to use xtr_fatmach0 instead of just fatmach0
* Use clang to compile with ASAN
* Use b_lundef=false
* Just test if different plugins configuration build, no r2r
* Use sys openssl as well
2019-02-28 16:58:09 +01:00
David CARLIER
88b8bb7f3a Few code changes, possible errors. (#13192) 2019-02-25 11:28:28 +01:00
GustavoLCR
55cd22731e Fix path with spaces problem in windows (#13144) 2019-02-18 18:31:12 +01:00
radare
73f76a99b2
Make RCons.is_interactive() into the RConsContext and improve loading projects in tasks ##cons (#13132) 2019-02-18 06:20:01 +01:00
GustavoLCR
a795cd647c Do not escape path to Windows file (#13108) 2019-02-15 18:22:48 +01:00
David CARLIER
14c134d97a Little cleanup before release (#13115) 2019-02-15 18:12:44 +01:00
David CARLIER
58ba3a663d Various little code fixes. (#13075) 2019-02-14 10:40:38 +01:00
Florian Märkl
fb2682a16f Disable (with warning) -t and deobfuscate -n variable ##main 2019-02-12 18:13:45 +01:00
pancake
1936f2d047 Update plugins.nogpl.cfg and fix a couple of warnings 2019-02-11 12:18:23 +01:00
Deepak Chethan
99ecf7950b Use pj api in rasm2 2019-02-10 23:37:27 +01:00
pancake
92e4256c19 Change -T behaviour and rename iF into it ##bin 2019-02-10 02:30:07 +01:00
David CARLIER
cebf7f6938 Compute hashes only with a new r2 flag ##bin 2019-02-10 02:11:25 +01:00
Rahul Sangwan
39dea00faa Update ragg2 man page ##ragg2 2019-02-10 01:28:35 +01:00
Rahul Sangwan
be654b89d3 Unescape chars when using rax2 -S
this commit resolve second part of #12862 (#12985)
2019-02-08 16:37:42 +01:00
Deepak Chethan
7e5f4e47a5 Added the append string feature for ragg2 ##ragg2 2019-02-06 17:07:43 +01:00
pancake
75354b4587 Fix warnings 2019-02-05 00:35:01 +01:00
GustavoLCR
c1d0e59d4d Fix rabin2 extract path for Windows ##bin 2019-02-04 15:55:06 -06:00
pancake
0939198515 Use pj in rasm2.c and add pj_f for float 2019-02-04 16:40:57 +01:00
pancake
0daae3d9af Remove R_ASM_BUFSIZE, all buffers are now dynamic ##asm 2019-02-04 00:23:40 +01:00
pancake
00fb2f4607 Remove global variables in rasm2.c ##refactoring 2019-02-04 00:22:49 +01:00
Riccardo Schirone
e5b4d9294c Use RSpaces in RFlag ##refactor 2019-02-03 09:06:45 -06:00
David CARLIER
5d698c76ae Display file hashes into rabin via new mode ##bin 2019-02-01 17:11:31 -06:00
Deepak Chethan
f087bcfbb0 Removed duplicated -q flag in ragg2's usage message (#12964) 2019-01-31 10:55:17 -06:00
Maijin
f9d4ab6f65
Add Certificates in rabin2 ##enhancement (#12900) 2019-01-24 17:22:53 +01:00
David CARLIER
3cff12a7c0 Add iF to show file hash and related refactoring ##bin 2019-01-24 17:34:00 +08:00
Khairul Azhar Kasmiran
01d5dfe306 Fix rafind2 -S for UTF8 chars > U+00ff (#12866)
* Fix rafind2 -S for UTF8 chars > U+00ff

* Use '< 1' instead of '== 0'

* Remove unnecessary else

* Add a 0
2019-01-22 09:43:10 +01:00
Maijin
8f94d413cd Standardize version using blob_version ##refactor 2019-01-12 22:22:43 +01:00
Maijin
c45e3d4123
Change eprintf to printf in rarun2
Change eprintf to printf in rarun2
2019-01-12 12:29:39 +01:00
David CARLIER
de40266908 Add basic auth to the webserver ##sync 2019-01-10 10:51:51 +01:00
radare
d1d9404907
Implement /s, /s* to search for sections depending on entropy ##search 2019-01-03 15:22:26 +01:00
David CARLIER
2eb706029c Few code/cleanups mem leaks potential (#12591) 2018-12-31 00:21:47 +01:00
dav1901
d05a119081 Fix few minor leaks (#12584) 2018-12-30 01:37:14 +01:00
GustavoLCR
7530895d0a Fix a few clang scan-build bugs (#12562)
* Removed unnecessary variable from libr/core/disasm.c
* Removed not necessary assignment in libr/core/casm.c
* Removed not used assignment in libr/bin/dwarf.c
* Rem. duplicate declaration and not used values
* Fixed potential memory leak in java/class.c
* Fixed potential memory leak in ragg2
* Removed unnecessary variable in visual.c
* Another potential memory leak in class.c
* Removed not used value assignment
* Fixed memory leak in dwarf.c
* Removed not needed assignments
* Remove more not used assignments
* Refactored where bin_sections gets arch & bits for clarity
* Removed more assignments that are not used
* Rem. more unused assignments
* Surround assignment with paranthesis
2018-12-26 12:54:12 +01:00
r4dix10
ad4013932d Issue #10780 -o for octal string to character (#12561) 2018-12-25 23:24:41 +01:00
dav1901
303a57bb85 Minor code cleanups/fixes (#12519) 2018-12-20 11:50:29 +01:00
iamahuman
a54dbe914b Support r2core.js for Emscripten >=v1.37.24 (#12502)
* Support r2core.js for Emscripten >=v1.37.24

cwrap needs to be exported explicitly via EXTRA_EXPORTED_RUNTIME_METHODS
+ allocate larger memory, allow for growth and no aborting malloc

* wasm_asm was wrongly also included in anal.wasm

This causes link errors where duplicate symbols aren't allowed.

* supply wasm plugin to suppress meta arch warning

r2 core initializes itself for the current architecture until one is
explicitly specified (e.g. loading a binary).  Since asm.wasm and
arch.wasm isn't supplied by default, r2 when built for WebAssembly
emits some ugly warnings when loading.  Besides, those modules
(incl. bin.wasm) aren't that large.

* r2core: Make it possible to know when init is done
2018-12-17 11:55:44 +01:00
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
ede39f120c Fix few build compiler warnings (#12490) 2018-12-16 14:54:40 +01:00
dav1901
5b644dcb74 Minor cleanups/fixes (#12478) 2018-12-14 00:17:50 +01:00
dav1901
97b94b3f94 Fix more clang warnings (#12458) 2018-12-12 12:22:36 +01:00
David CARLIER
384fe0f903 Silencing/fixing clang warnings. (#12430) 2018-12-10 00:04:21 +01:00
pancake
64f2e25c3a Fix #12405 - Handle ^C in radiff2 -x 2018-12-05 12:41:44 +01:00
dav1901
ab17935659 Fix clang warnings (#12413) 2018-12-05 12:35:37 +01:00
pancake
0cbd616e3b Fix posix shell regrssion in r2pm -s 2018-12-05 12:26:00 +01:00
radare
a3d181a8a0
Fixes spotted by clang-analyzer (#12391) 2018-12-04 10:45:46 +01:00
David CARLIER
138ca20e27 Couple of mem leak fixes. (#12355) 2018-11-29 17:04:24 +01:00
David CARLIER
d5a42c5c0c Fix use after free in radare2. (#12332)
We need the path a little bit longer.
2018-11-26 22:13:32 +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
lzutao
50320592a6 Fix #12060 and #12072 - Rewrite r_num_abs and r_num_units ##core
r_num_abs:

- Make r_num_abs static inline
- Use unsigned long long type when defining TB macro
- Use st64 instead of long long

r_num_units:

- Add len argument for buf in r_num_units
- Add PB and EB for r_num_units
- Always display one number after decimal point

  * This change simplifies the code
- Use long double type as assigning from ut64 to double cause data loss

r_num_tail_base:

- Use isxdigit (fast) instead of isHexDigit (slower)
- Rename nth to get_nth_nibble

Update all functions to use with new r_num_units:

- Remove side effect when using in other functions like cb_printf

* Trim trailing .0 when input is power of 2
2018-11-14 23:35:44 +01:00
Christopher Hewitt
451c76c71d Open radare2 project after loading plugins and keep the -e flags ##projects 2018-11-14 22:31:02 +01:00
pancake
701ecb2835 More include fixes 2018-11-14 13:12:34 +01:00
Artem Zinenko
4a2bc97a35 Fix #11918 - Moved r_print.h into r_util/r_print.h 2018-11-14 10:54:22 +01:00
Riccardo Schirone
f77ecfb357 Upgrade SDB and use the new HtPP, HtUP, HtUU ##refactoring
* sdb-sync: update to commit ea05ca8808605daa683a2b35f143e24c3a70f0c9
2018-11-14 10:47:28 +01:00
Riccardo Schirone
90058945d2 Remove "referenced" from RBinObject and remove get_object ##refactoring 2018-11-13 13:05:18 +01:00
Paweł Łukasik
22ff13e069 Add dbg.verbose variable to show more info when debugging ##debug 2018-11-13 02:10:21 +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
radare
71053f17e9
Move trie, mixed, slist into Sdb's Attic, and DES from util to crypto ##refactor 2018-11-07 17:18:14 +01:00
pancake
3e98d0f778 Fix #11237 - Handle -@ in rasm2 as an alias for -o 2018-10-31 11:45:50 +01:00
a1ext
4e8e7de7b4 Fix unicode path issues in Windows ##windows 2018-10-30 01:04:47 +01:00
David CARLIER
4597224d7d Fix r2agent segfault. (#11950)
Since it s based on reference counting, it is safe to make sure the context is initialised.
2018-10-26 13:21:12 +02:00
Sajjad Pourali
503844ac77 Fix MacOS Mojave User Debugging Problem ##build 2018-10-25 23:42:47 +02:00
Maijin
337dd0d909
Remove Sf command ##refactoring 2018-10-25 21:20:16 +02: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
pancake
9f896002ba Fix macos-sign 2018-10-22 20:03:39 +02:00
pancake
f60ca729fb Just add -static in linux 2018-10-22 19:57:45 +02:00
pancake
a6a6d34718 Add -static for the binaries when --with-libr ##build 2018-10-22 15:16:52 +02:00
pancake
f97aded52a Statically link the binaries when using --with-libr 2018-10-22 15:10:29 +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
pancake
fd0ab00b14 Fix static blob build for android and disable libuv ##build 2018-10-20 20:10:17 +02:00
pancake
a33fc03725 Fix visual panels glitch and handle 's' in zoom mode ##visual
* And remove dead code
2018-10-20 02:12:30 +02:00
radare
9beda2f60f
Allow multiple packages as arguments for r2pm -i,-c,-ci ##tools (#11843) 2018-10-18 10:10:35 +02:00
pancake
2142a8a992 Fix build 2018-10-15 20:48:24 +02:00
pancake
de525b09d8 Add missing r_hash dependency for rafind2 2018-10-15 20:47:41 +02:00
radare
c8356abb03
Add zign hash using sha256 (#11822) 2018-10-15 19:13:18 +02:00
Riccardo Schirone
6c462b3ecc rafind2: avoid memleaks (#11817) 2018-10-15 16:18:51 +02:00
bannsec
e56d3de4ab Fix memleaks in ragg2 (#11788) 2018-10-12 12:18:22 +02:00
Riccardo Schirone
ab4578a546
remove random warnings when compiling (#11767)
* remove random warnings when compiling

* debug_native: provide r_debug_handle_signals on windows
2018-10-08 13:21:50 +02:00
pancake
c4395fd8ee Fix #10290 - Support R2_ and without prefix in r2 -H 2018-10-08 00:43:40 +02:00
pancake
b151764ffe Support tar and fix clean in r2pm 2018-10-07 00:18:26 +02:00
David CARLIER
036db696d1 Fix couple of leaks. (#11716) 2018-10-02 15:24:27 +02:00
David CARLIER
da3d1bb4cc Fixing few leaks. (#11707) 2018-10-02 00:21:29 +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
4188860216 Memory Leak (no path free) in rasm2 (#11703)
Small memory leak in rasm2.
2018-10-01 09:29:03 +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
798ef9519e Detect error when something fails in binr/ 2018-09-22 11:31:45 +02:00
radare
478dd2377a
Fix #11566 - Regression in r2 = introduced by threading and siol (#11598)
Still not perfect because stdin works, but the tty size/configuration
is not correct when reopening.
2018-09-21 00:13:19 +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
morbith-dqtz
5c6b976343 linux_heap_glibc: refactor (#11541) 2018-09-17 02:00:39 +02: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
f90b534a4d Fix several bugs introduced during r2con 2018-09-10 16:33:29 +02:00
Adrian Pistol
fe6f9badb5 radare2: Try to detect color support and set scr.color accordingly. (#11420) 2018-09-07 16:29:35 +02:00
radare
6ef364521f
Fix #11370 - rahash2 showing the same checksum when passing multiple files (#11372) 2018-09-04 01:28:13 +02:00
pancake
f1dc368018 Fix #11383 - Invalid initial block contents when opening with no file 2018-09-04 01:16:13 +02:00
Neven Sajko
b0436220dc libr/cons: Do proper signal handling, use pselect (#11376)
Fixes async-signal-safety and changing errno within the signal handler
for SIGWINCH, which can cause crashes and maybe security issues.

For async-signal-safety make the signal handler just set a flag, which
is checked for while waiting for input (pselect).

SIGWINCH is blocked process-wide, except in pselect.
2018-09-03 23:46:13 +02:00
Riccardo Schirone
be8ece36a7 io: make r_io_map_new always update skyline
keep a "private" version, named io_map_new, which can be called by the
io module for performance reasons (e.g. loading many maps, you don't
want to sync the status every time when you can do that only one time at
the end of the batch insertion).
2018-09-03 11:18:10 +02:00
pancake
1875a7f4f0 Add error handling in ?x- 2018-09-02 15:58:13 +02:00
Fangrui Song
f538120c04 Fix memleak (#11338) 2018-09-01 10:43:48 +02:00
pancake
bb6212da45 Fix 2 minor gcc8 warnings 2018-08-31 17:56:37 +02:00
Neven Sajko
d8784641ee Add parentheses in macros where needed for safety (#11290) 2018-08-30 13:16:50 +02:00
Neven Sajko
44ecf2f01b Do not hardcode 9 for SIGKILL (#11299)
Changes 9 with SIGKILL as 'kill' operand.
2018-08-29 18:18:14 +02:00
pancake
ff08c059da Kill the isThumb checks (s110-arm-16 half converted) 2018-08-26 23:08:44 +02:00
morbith-dqtz
e09306ab99 Make glibc tcache parsing if checked by a config flag, no more preprocessor (#11266) 2018-08-26 22:50:30 +02:00
Paul I
0ba26fb3d6 Add R2_GLOBAL_RC (#11258) 2018-08-26 14:09:32 +02:00
kij
10265a0507 Remove 2 bashisms, unsure about the last. (#11189) 2018-08-24 15:57:18 +02:00
radare
44627091d3
Fix memleaks in radare2.c (#11221) 2018-08-24 00:20:08 +02:00
Florian Märkl
2883398942 Fix #11081 - Transient Tasks (#11214)
* Make r_th_free() not kill the thread
* Transient Tasks
* Add transient info to & list output
* Use refcounting for Tasks
2018-08-23 13:49:28 +02:00
pancake
6d05365f30 Make RAsmOp use RStrBuf instead of fixed-size buffers
* Seems to work, but there are many things to improve and fix
* Fixed some bugs (overflow, sandbox bypass, ..)
* Exposes some memleaks and bad api usages.
* Refactor all the things! \o/
* Fix z80, tms320 disasm and x86.as
* Care about memleaks
* Support meson
* And fix more tests related to pda and pdj and m68k
2018-08-22 11:43:05 +02:00
kij
10786e5549 r2pm OCD fixes, search list aligned with column 2018-08-21 23:44:19 +02:00
radare
586bf7fc15
ragg2 *.c shows stderr and fix clang cflags (-Os makes non-pic code 🤦) (#11122) 2018-08-18 03:41:24 +02:00
David CARLIER
d77f8a2bce Fix leak for arch value form env var. (#11091) 2018-08-15 10:25:25 +02:00
Rafael Rivera
4634a817c4 Create cons context before col diffing (fixes #11059) (#11060) 2018-08-13 03:12:27 +02:00
Florian Märkl
404e4a1b74 Prompt on exit to kill tasks (#11054) 2018-08-12 13:27:45 +02:00
pancake
042f5271ba Bring back the old -w that implies R_IO_CREAT 2018-08-11 20:44:28 +02:00
pancake
d55bb122f3 Kill r_io_creat and make it into R_IO_CREAT, honor -ww 2018-08-11 20:44:28 +02:00
pancake
456de668b7 Fix #10947 - open without va when creating a new file 2018-08-11 20:44:28 +02:00
pancake
aa0581ab81 Use more r2 -H and less hardcoded paths in r2pm 2018-08-08 17:09:03 +02:00
pancake
b32a675371 Show R2PM_ variable values in r2pm -h 2018-08-08 16:51:19 +02:00
Maijin
b60a25b914 Add more R2_ prefix for some var 2018-08-07 22:14:54 +02:00
Maijin
b3d081abcd Add some R2_ prefix for some var 2018-08-07 22:01:59 +02:00
Arnaud Lefebvre
d934934efc r2pm: install r2pm in bindir instead of $PREFIX/bin (#10976) 2018-08-07 14:29:51 +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
Maijin
6eda76e0f8
Fix #1361 (#10889) 2018-08-01 22:27:19 +02:00
pancake
bb8f2b0773 Fix #10865 - hang_03 - skip invalid sections when marking data words 2018-08-01 00:57:36 +01:00
Khairul Azhar Kasmiran
d42b734a84
rax2: add new output mode for Fx (#10840)
* rax2: add new output mode for Fx

* Reversed order of tests
2018-07-29 11:04:52 +08:00
Tyler Lambert
8255f2a96c Verify input is not in hex before interpreting as float (#10821)
* verify input is not in hex before interpreting as float

* check for "0x" prefix before converting to float
2018-07-28 13:18:13 +08: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
pancake
20b95e4bb4 Fix asan issue related to the hashbang launch 2018-07-19 17:25:44 +02:00
Anton Kochkov
6e73443942 Try to fix MSVC build 2018-07-19 18:09:19 +08:00
pancake
b21035349d Fix - - - behaviour 2018-07-19 11:41:27 +02: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
Paul I
9cb663cbdb Fix r2 -H MAGICPATH 2018-07-17 23:19:21 +02:00
Riccardo Schirone
c932d1abff
meson fixes (#10743)
* r2pm/meson.build: install r2pm
* meson.build: use system libraries when available
* travis: add fedora-sys to the list of things to test
* bin_nso.c: still include lz4.c when not on meson
* Dockerfile.travis: add required system dependencies to dockerfile
* meson.build: split zip_dep in libzip and zlib dependencies
* shlr/meson.build: zip needs zlib
2018-07-17 23:01:40 +02:00
pancake
7463546f13 Fix android build 2018-07-16 17:49:15 +02:00
Khairul Kasmiran
40c68d9ec0 End rabin2 json output with newline 2018-07-16 14:09:22 +02:00
pancake
2c85194e7a Fix some warnings 2018-07-14 10:45:55 +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
Khairul Kasmiran
41ba85c57f Removed trailing spaces of ragg2.c 2018-07-07 23:53:30 +08:00
Khairul Kasmiran
d8048db0d9 Remove unneeded trailing spaces 2018-07-07 23:19:37 +08:00
Khairul Kasmiran
ff00596385 Removed trailing space 2018-07-06 23:26:33 +08:00
Tomasz Gorochowik
3c15e4348d rafind2: print heading (filename) before matches
The headings are enabled by default when searching multiple files or a
directory.

The headings can be disabled with the quiet mode (-q).
2018-06-30 19:37:52 +02:00
Tomasz Gorochowik
e17cc1c6ae Implement rafind2 recursive search ability 2018-06-30 19:37:52 +02:00
Florian Märkl
5e35ad898b RConsContext (#10450)
* Add RConsContext
* Swap cons in tasks using RConsContext
* Create cons context for background tasks
* Move event_interrupt to RConsContext
* Fix breaking main cons from signal
* Make r_print_is_interrupted() use callback
2018-06-23 12:10:13 +02:00
pancake
df0aadb89f Fix sys/ios-cydia.sh for iOS11/electra jailbreak 2018-06-21 02:41:14 +02:00
pancake
e482321196 Add platform-application entitlement for iOS11 2018-06-21 01:01:24 +02:00
Rene Laemmert
d11473201a Started changing bin_load to bin_open (#10221) 2018-06-20 16:19:22 +02:00
Florian Märkl
2202d14067 Timeout socket accept using select (#10415) 2018-06-20 11:20:55 +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
Florian Märkl
6730a93e9c Sleep during prompt
Sleep during prompt for Windows
2018-06-17 11:34:03 +02:00
Florian Märkl
f449ae66f5 Fix Command History and Quit 2018-06-17 11:34:03 +02:00
Florian Märkl
88fa23e53a Add r_core_cmd_task_sync() 2018-06-17 11:34:03 +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
pancake
c52c7bace3 Fix #10300 - Link issues --with-sysmagic 2018-06-11 03:36:45 +02:00
bannsec
f6fd192234 Fixing docker build bug by tweaking the r2pm script (#10268)
* Fixing docker build bug
* Moving mkdir -p into r2pm
* Changing to use r2 -H
* Using ":" and quotes
2018-06-10 21:03:34 +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
pancake
cfe152b0fc Fix possible null derefs in file.sha1/path 2018-06-06 17:46:56 +02:00
sivaramaaa
e5bbaffbfe Refactor code to change R_ANAL_OP_MASK_ALL to appropriate value 2018-05-31 19:05:54 +02:00
Khairul Azhar Kasmiran
7befed4463 R_SYS_DEVNULL: null device name (#10233) 2018-05-31 16:32:58 +02:00
pancake
cbeff990a1 Fix last covs 2018-05-30 12:41:57 +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
Sebastien Marie
3822f1446e avoid cp -a: it isn't POSIX defined and don't exist on openbsd (#10133)
replace it by the most similar arguments: cp -PRp
(not copied elements are context,links,xattr)
2018-05-20 00:29:53 +02:00
ddast
7706f2d778 Fix hexdump output of radiff2 (#10111)
radiff2 showed wrong output when filesize was not a multiple of the
width.
2018-05-18 10:41:29 +02:00
Paolo Monti
b32dd4ca9f Fix #2639, added support for javascript byte arrays in rax2 -F (#10065) 2018-05-11 10:58:16 +02:00
radare
9e08da0fa6
Improve build of libr.a and libr.dylib, fix and improve sys/ios-sdk.sh (#10046)
- Update spp and force hidden visibility
- Use R_API wisely
- RSys.prefix returns const things
- Use -install_name on Apple
- Fix merged lib visibility linking on Linux
- Use OSTYPE instead of BUILD_OS
- Honor crosscompiler-objcopy and support android like linux
- Add extra missing archives
- Fix for android
- Upgrade spp and sdb
- Skip libr. from symstall
- Add --enable-merged configure option
- Use --enable-merged on ios-sdk
- Upgrade sdb again for js0n
- Kill sys/ios-shell.sh
- Msvc dynamic build fix
2018-05-09 23:31:52 +02:00
pancake
5578d8d1ae Implement iO as a frontend for !rabin2 -O 2018-05-09 23:25:03 +02:00
Paul I
e33200ac45 Fix pathes for r2pm (#10044)
Add more variables to r2 -H
2018-05-08 02:21:08 +02:00
Paolo Monti
cf91e24448 Removal of dead code for rax2 -P (#10016) 2018-05-06 17:26:16 +02:00
Paolo Monti
6c4131bbaf Fix #9986, implemented rax2 -i functionality, to mimic xxd -i (#10009) 2018-05-05 00:57:11 +02:00
Gromimousse
78ce646cf6 Ragg2-cc is now completely erased from r2 (merged into ragg2) (#9996) 2018-05-02 20:34:30 +02:00
Paul I
5180e0220f Add R2_PLUGINS, R2_EXTRAS, R2_BINDINGS macros (#9994) 2018-05-02 15:58:14 +02:00
radare
000e725b15
Use system diff in graphdiff nodes if possible and improve graphviz style (#9988)
$ radiff2 -g sym._call -A  b c | dot -Tpng > a.png

- we need disasmdiff native in r2, as well as more inter-core commands
2018-04-30 02:47:51 +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
pancake
a24eb639e0 Make Travis Green 2018-04-25 12:30:57 +02:00