Add RABIN2_VERBOSE env var to set bin.verbose=true in rabin2 ##tools

This commit is contained in:
pancake 2022-06-30 01:58:18 +02:00
parent 5d59f0e144
commit 0475e8c2de
2 changed files with 6 additions and 0 deletions

View File

@ -88,6 +88,7 @@ static int rabin_show_help(int v) {
" RABIN2_STRPURGE: e bin.str.purge # try to purge false positives\n"
" RABIN2_SYMSTORE: e pdb.symstore # path to downstream symbol store\n"
" RABIN2_SWIFTLIB: 1|0| # load Swift libsto demangle (default: true)\n"
" RABIN2_VERBOSE: e bin.verbose # show debugging messages from the parser\n"
);
}
return 1;
@ -634,6 +635,9 @@ R_API int r_main_rabin2(int argc, const char **argv) {
r_config_set (core.config, "bin.lang", tmp);
free (tmp);
}
if (r_sys_getenv_asbool ("RABIN2_VERBOSE")) {
r_config_set_b (core.config, "bin.verbose", true);
}
if ((tmp = r_sys_getenv ("RABIN2_DEMANGLE"))) {
r_config_set (core.config, "bin.demangle", tmp);
free (tmp);

View File

@ -152,6 +152,8 @@ RABIN2_STRFILTER same as r2 -e bin.str.filter for rabin2
RABIN2_STRPURGE same as r2 -e bin.str.purge for rabin2
.Pp
RABIN2_DEMANGLE_TRYLIB same as r2 -e bin.demangle.trylib=<bool> - try to dynamically load libraries to demangle
.Pp
RABIN2_VERBOSE same as r2 -e bin.verbose=true
.Sh EXAMPLES
.Pp
List symbols of a program