42 const char *input_file =
NULL;
43 const char *output_file =
NULL;
53 size_t complexity = 0;
69 RZ_LOG_ERROR(
"rz-sign: cannot combine option -%c with previous options\n",
c);
74 output_file = opt.
arg;
78 RZ_LOG_ERROR(
"rz-sign: cannot combine option -%c with previous options\n",
c);
83 output_file = opt.
arg;
87 RZ_LOG_ERROR(
"rz-sign: cannot combine option -%c with previous options\n",
c);
96 RZ_LOG_ERROR(
"rz-sign: cannot add evaluable config variable '%s' to RzList\n", opt.
arg);
117 if (opt.
ind >= argc) {
127 RZ_LOG_ERROR(
"rz-sign: Invalid analysis complexity (too many -a defined, max -aa)\n");
147 RZ_LOG_ERROR(
"rz-sign: Could not open file %s\n", input_file);
162 rz_list_foreach (evars, it,
config) {
176 rz_cons_printf(
"rz-sign: %s was converted to %s.\n", input_file, output_file);
186 rz_cons_printf(
"rz-sign: written %u signatures to %s.\n", n_nodes, output_file);
195 RZ_LOG_ERROR(
"rz-sign: missing option, please set -c or -d or -o\n");
RZ_API int rz_core_bin_update_arch_bits(RzCore *r)
RZ_API RZ_BORROW RzCoreFile * rz_core_file_open(RZ_NONNULL RzCore *r, RZ_NONNULL const char *file, int flags, ut64 loadaddr)
Tries to open the file as is, otherwise tries as is a compilation of files.
RZ_API bool rz_core_bin_load(RZ_NONNULL RzCore *r, RZ_NULLABLE const char *filenameuri, ut64 baddr)
RZ_API bool rz_config_eval(RZ_NONNULL RzConfig *cfg, RZ_NONNULL const char *str)
Sets the configuration variable and its value passed as argument.
RZ_API RzConfigNode * rz_config_set_i(RzConfig *cfg, RZ_NONNULL const char *name, const ut64 i)
RZ_API RzConfigNode * rz_config_set_b(RzConfig *cfg, RZ_NONNULL const char *name, bool value)
RZ_API void rz_cons_set_interactive(bool x)
RZ_API int rz_cons_printf(const char *format,...)
RZ_API void rz_cons_flush(void)
RZ_API void rz_cons_reset(void)
RZ_API bool rz_core_flirt_convert_file(RZ_NONNULL RzCore *core, RZ_NONNULL const char *input_file, RZ_NONNULL const char *output_file)
converts a FLIRT file to the other format.
RZ_API bool rz_core_flirt_create_file(RZ_NONNULL RzCore *core, RZ_NONNULL const char *output_file, RZ_NULLABLE ut32 *written_nodes)
Generates a new FLIRT file from a given RzCore structure.
RZ_API bool rz_core_flirt_dump_file(RZ_NONNULL const char *flirt_file)
Dumps the contents of a FLIRT file.
RZ_API void Ht_() free(HtName_(Ht) *ht)
RZ_API void rz_core_free(RzCore *c)
RZ_API RzCore * rz_core_new(void)
static void rz_sign_show_help(void)
static void perform_analysis(RzCore *core, size_t complexity)
RZ_API RZ_OWN RzList * rz_list_newf(RzListFree f)
Returns a new initialized RzList pointer and sets the free method.
RZ_API RZ_BORROW RzListIter * rz_list_append(RZ_NONNULL RzList *list, void *data)
Appends at the end of the list a new element.
RZ_API void rz_list_free(RZ_NONNULL RzList *list)
Empties the list and frees the list pointer.
RZ_API int rz_core_loadlibs(RzCore *core, int where)
static static fork const void static count static fd const char const char static newpath char char argv
RZ_API void rz_getopt_init(RzGetopt *go, int argc, const char **argv, const char *ostr)
RZ_API int rz_getopt_next(RzGetopt *opt)
#define RZ_LOG_ERROR(fmtstr,...)
RZ_API int rz_main_version_print(const char *program)
RZ_API char * rz_str_new(const char *str)