Rizin
unix-like reverse engineering framework and cli tools
cmd_info.c
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: 2009-2020 pancake <pancake@nopcode.org>
2 // SPDX-License-Identifier: LGPL-3.0-only
3 
4 #include <string.h>
5 #include <rz_bin.h>
6 #include <rz_config.h>
7 #include <rz_cons.h>
8 #include <rz_core.h>
9 #include <rz_demangler.h>
10 #include "../bin/pdb/pdb_downloader.h"
11 #include "../core_private.h"
12 
13 static int bin_is_executable(RzBinObject *obj) {
14  RzListIter *it;
15  RzBinSection *sec;
16  if (obj) {
17  if (obj->info && obj->info->arch) {
18  return true;
19  }
20  rz_list_foreach (obj->sections, it, sec) {
21  if (sec->perm & RZ_PERM_X) {
22  return true;
23  }
24  }
25  }
26  return false;
27 }
28 
29 static bool is_equal_file_hashes(RzList *lfile_hashes, RzList *rfile_hashes, bool *equal) {
30  rz_return_val_if_fail(lfile_hashes, false);
31  rz_return_val_if_fail(rfile_hashes, false);
32  rz_return_val_if_fail(equal, false);
33 
34  *equal = true;
35  RzBinFileHash *fh_l, *fh_r;
36  RzListIter *hiter_l, *hiter_r;
37  rz_list_foreach (lfile_hashes, hiter_l, fh_l) {
38  rz_list_foreach (rfile_hashes, hiter_r, fh_r) {
39  if (strcmp(fh_l->type, fh_r->type)) {
40  continue;
41  }
42  if (!!strcmp(fh_l->hex, fh_r->hex)) {
43  *equal = false;
44  return true;
45  }
46  }
47  }
48  return true;
49 }
50 
51 static bool source_file_collect_cb(void *user, const void *k, const void *v) {
52  RzPVector *r = user;
53  char *f = strdup(k);
54  if (f) {
56  }
57  return true;
58 }
59 
60 typedef enum {
65 
67  RzBinFile *binfile = core->bin->cur;
68  if (!binfile || !binfile->o) {
69  rz_cons_printf("No file loaded.\n");
70  return false;
71  }
72  RzBinSourceLineInfo *li = binfile->o->lines;
73  if (!li) {
74  rz_cons_printf("No source info available.\n");
75  return true;
76  }
77  switch (type) {
79  // collect all filenames uniquely
80  HtPP *files = ht_pp_new0();
81  if (!files) {
82  return false;
83  }
84  for (size_t i = 0; i < li->samples_count; i++) {
86  if (!s->line || !s->file) {
87  continue;
88  }
89  ht_pp_insert(files, s->file, NULL);
90  }
91  // sort them alphabetically
92  RzPVector sorter;
93  rz_pvector_init(&sorter, free);
94  ht_pp_foreach(files, source_file_collect_cb, &sorter);
95  rz_pvector_sort(&sorter, (RzPVectorComparator)strcmp);
96  ht_pp_free(files);
97  // print them!
98  if (state->mode == RZ_OUTPUT_MODE_JSON) {
99  pj_a(state->d.pj);
100  void **it;
101  rz_pvector_foreach (&sorter, it) {
102  pj_s(state->d.pj, *it);
103  }
104  pj_end(state->d.pj);
105  } else {
106  rz_cons_printf("[Source file]\n");
107  void **it;
108  rz_pvector_foreach (&sorter, it) {
109  const char *file = *it;
110  rz_cons_printf("%s\n", file);
111  }
112  }
113  rz_pvector_fini(&sorter);
114  break;
115  }
118  break;
124  }
126  break;
127  }
128  return true;
129 }
130 
131 RZ_IPI int rz_cmd_info_kuery(void *data, const char *input) {
132  RzCore *core = (RzCore *)data;
133  RzBinObject *o = rz_bin_cur_object(core->bin);
134  Sdb *db = o ? o->kv : NULL;
135  switch (input[0]) {
136  case 'v':
137  if (db) {
138  char *o = sdb_querys(db, NULL, 0, input + 2);
139  if (o && *o) {
140  rz_cons_print(o);
141  }
142  free(o);
143  }
144  break;
145  case '*':
147  break;
148  case '.':
149  case ' ':
150  if (db) {
151  char *o = sdb_querys(db, NULL, 0, input + 1);
152  if (o && *o) {
153  rz_cons_print(o);
154  }
155  free(o);
156  }
157  break;
158  case '\0':
159  if (db) {
160  char *o = sdb_querys(db, NULL, 0, "*");
161  if (o && *o) {
162  rz_cons_print(o);
163  }
164  free(o);
165  }
166  break;
167  case '?':
168  default:
169  eprintf("Usage: ik [sdb-query]\n");
170  eprintf("Usage: ik* # load all header information\n");
171  return 1;
172  }
173  return 0;
174 }
175 
176 #define GET_CHECK_CUR_BINFILE(core) \
177  RzBinFile *bf = rz_bin_cur(core->bin); \
178  if (!bf) { \
179  RZ_LOG_ERROR("No binary object currently selected.\n"); \
180  return RZ_CMD_STATUS_ERROR; \
181  }
182 
185 }
186 
188  GET_CHECK_CUR_BINFILE(core);
189  ut32 mask = RZ_CORE_BIN_ACC_INFO;
190  mask |= RZ_CORE_BIN_ACC_IMPORTS;
191  mask |= RZ_CORE_BIN_ACC_ENTRIES;
192  mask |= RZ_CORE_BIN_ACC_EXPORTS;
193  mask |= RZ_CORE_BIN_ACC_CLASSES;
194  mask |= RZ_CORE_BIN_ACC_SYMBOLS;
195  mask |= RZ_CORE_BIN_ACC_SECTIONS;
196  mask |= RZ_CORE_BIN_ACC_MEM;
197  mask |= RZ_CORE_BIN_ACC_STRINGS;
198  if (state->mode == RZ_OUTPUT_MODE_JSON) {
199  pj_o(state->d.pj);
200  }
201  bool res = rz_core_bin_print(core, bf, mask, NULL, state, NULL);
202  if (state->mode == RZ_OUTPUT_MODE_JSON) {
203  pj_end(state->d.pj);
204  }
205  return res ? RZ_CMD_STATUS_OK : RZ_CMD_STATUS_ERROR;
206 }
207 
209  GET_CHECK_CUR_BINFILE(core);
210  return bool2status(rz_core_bin_entries_print(core, bf, state));
211 }
212 
214  GET_CHECK_CUR_BINFILE(core);
215  return bool2status(rz_core_bin_initfini_print(core, bf, state));
216 }
217 
219  GET_CHECK_CUR_BINFILE(core);
220  return bool2status(rz_core_bin_exports_print(core, bf, state, NULL));
221 }
222 
224  GET_CHECK_CUR_BINFILE(core);
226 }
227 
229  GET_CHECK_CUR_BINFILE(core);
230  return bool2status(rz_core_bin_symbols_print(core, bf, state, NULL));
231 }
232 
234  GET_CHECK_CUR_BINFILE(core);
236 }
237 
239  GET_CHECK_CUR_BINFILE(core);
240  return bool2status(rz_core_bin_imports_print(core, bf, state, NULL));
241 }
242 
244  GET_CHECK_CUR_BINFILE(core);
245  return bool2status(rz_core_bin_libs_print(core, bf, state));
246 }
247 
249  GET_CHECK_CUR_BINFILE(core);
250  return bool2status(rz_core_bin_main_print(core, bf, state));
251 }
252 
254  GET_CHECK_CUR_BINFILE(core);
255  return bool2status(rz_core_bin_relocs_print(core, bf, state));
256 }
257 
259  GET_CHECK_CUR_BINFILE(core);
260  RzList *hashes = rz_list_new_from_array((const void **)argv + 1, argc - 1);
261  if (!hashes) {
262  return RZ_CMD_STATUS_ERROR;
263  }
264  bool res = rz_core_bin_sections_print(core, bf, state, NULL, hashes);
265  rz_list_free(hashes);
266  return bool2status(res);
267 }
268 
270  GET_CHECK_CUR_BINFILE(core);
271  RzList *hashes = rz_list_new_from_array((const void **)argv + 1, argc - 1);
272  if (!hashes) {
273  return RZ_CMD_STATUS_ERROR;
274  }
275  bool res = rz_core_bin_cur_section_print(core, bf, state, hashes);
276  rz_list_free(hashes);
277  return bool2status(res);
278 }
279 
282  RzBinObject *o = rz_bin_cur_object(core->bin);
283  if (!o) {
284  RZ_LOG_ERROR("No binary object at current address\n");
285  return RZ_CMD_STATUS_ERROR;
286  }
287 
289  if (!sections) {
290  RZ_LOG_ERROR("Cannot retrieve sections\n");
291  return RZ_CMD_STATUS_ERROR;
292  }
293 
294  int cols = rz_cons_get_size(NULL);
296  if (!list) {
297  goto sections_err;
298  }
299 
300  RzListIter *iter;
302  rz_list_foreach (sections, iter, section) {
303  char humansz[8];
304  RzInterval pitv = (RzInterval){ section->paddr, section->size };
305  RzInterval vitv = (RzInterval){ section->vaddr, section->vsize };
306 
307  rz_num_units(humansz, sizeof(humansz), section->size);
308  RzListInfo *info = rz_listinfo_new(section->name, pitv, vitv, section->perm, humansz);
309  if (!info) {
310  RZ_LOG_ERROR("Cannot print section bars\n");
311  goto list_err;
312  }
314  }
315  RzTable *table = rz_core_table(core);
316  if (!table) {
317  RZ_LOG_ERROR("Cannot print section bars\n");
318  goto list_err;
319  }
320  rz_table_visual_list(table, list, core->offset, -1, cols, core->io->va);
321 
322  char *s = rz_table_tostring(table);
323  if (!s) {
324  RZ_LOG_ERROR("Cannot print section bars\n");
325  goto table_err;
326  }
327  rz_cons_printf("%s\n", s);
328  free(s);
329  res = RZ_CMD_STATUS_OK;
330 
331 table_err:
332  rz_table_free(table);
333 list_err:
335 sections_err:
337  return res;
338 }
339 
341  GET_CHECK_CUR_BINFILE(core);
342  RzList *hashes = rz_list_new_from_array((const void **)argv + 1, argc - 1);
343  if (!hashes) {
344  return RZ_CMD_STATUS_ERROR;
345  }
346  bool res = rz_core_bin_segments_print(core, bf, state, NULL, hashes);
347  rz_list_free(hashes);
348  return bool2status(res);
349 }
350 
352  GET_CHECK_CUR_BINFILE(core);
353  RzList *hashes = rz_list_new_from_array((const void **)argv + 1, argc - 1);
354  if (!hashes) {
355  return RZ_CMD_STATUS_ERROR;
356  }
357  bool res = rz_core_bin_cur_segment_print(core, bf, state, hashes);
358  rz_list_free(hashes);
359  return bool2status(res);
360 }
361 
363  GET_CHECK_CUR_BINFILE(core);
364  return bool2status(rz_core_bin_strings_print(core, bf, state));
365 }
366 
368  RzBinFile *bf = rz_bin_cur(core->bin);
370 }
371 
373  char *strpurge = core->bin->strpurge;
374  char tmp[2048];
375  rz_config_set(core->config, "bin.str.purge", rz_strf(tmp, "%s%s0x%" PFMT64x, strpurge ? strpurge : "", strpurge && *strpurge ? "," : "", core->offset));
376  return RZ_CMD_STATUS_OK;
377 }
378 
380  if (!core->file) {
381  return RZ_CMD_STATUS_ERROR;
382  }
383  if (state->mode == RZ_OUTPUT_MODE_JSON) {
384  pj_o(state->d.pj);
385  pj_k(state->d.pj, "core");
386  }
387  RzBinFile *bf = rz_bin_cur(core->bin);
388  bool res = rz_core_file_info_print(core, bf, state);
389  if (bf && bin_is_executable(bf->o)) {
390  if (state->mode == RZ_OUTPUT_MODE_JSON) {
391  pj_k(state->d.pj, "bin");
392  }
393  rz_core_bin_info_print(core, bf, state);
394  }
395  if (state->mode == RZ_OUTPUT_MODE_JSON) {
396  pj_end(state->d.pj);
397  }
398  return bool2status(res);
399 }
400 
402  GET_CHECK_CUR_BINFILE(core);
403  return bool2status(rz_core_bin_classes_print(core, bf, state));
404 }
405 
407  GET_CHECK_CUR_BINFILE(core);
408  return bool2status(rz_core_bin_class_as_source_print(core, bf, argv[1]));
409 }
410 
412  GET_CHECK_CUR_BINFILE(core);
413  return bool2status(rz_core_bin_class_fields_print(core, bf, state, argv[1]));
414 }
415 
417  GET_CHECK_CUR_BINFILE(core);
418  return bool2status(rz_core_bin_class_methods_print(core, bf, state, argv[1]));
419 }
420 
422  GET_CHECK_CUR_BINFILE(core);
424 }
425 
427  GET_CHECK_CUR_BINFILE(core);
428  return bool2status(rz_core_bin_fields_print(core, bf, state));
429 }
430 
431 RZ_IPI RzCmdStatus rz_cmd_info_headers_handler(RzCore *core, int argc, const char **argv) {
432  GET_CHECK_CUR_BINFILE(core);
433  return bool2status(rz_core_bin_headers_print(core, bf));
434 }
435 
437  GET_CHECK_CUR_BINFILE(core);
438  return bool2status(rz_core_bin_info_print(core, bf, state));
439 }
440 
442  if (argc < 2) {
444  return RZ_CMD_STATUS_OK;
445  }
446 
447  const char *plugin_name = argv[1];
448  const RzBinPlugin *bp = rz_bin_plugin_get(core->bin, plugin_name);
449  if (bp) {
451  return RZ_CMD_STATUS_OK;
452  }
453 
454  const RzBinXtrPlugin *xbp = rz_bin_xtrplugin_get(core->bin, plugin_name);
455  if (xbp) {
457  return RZ_CMD_STATUS_OK;
458  }
459 
460  return RZ_CMD_STATUS_ERROR;
461 }
462 
464  GET_CHECK_CUR_BINFILE(core);
465  return bool2status(rz_core_bin_dwarf_print(core, bf, state));
466 }
467 
469  char *filename = argc > 1 ? strdup(argv[1]) : rz_core_bin_pdb_get_filename(core);
470  if (!filename) {
471  RZ_LOG_ERROR("Cannot find the right PDB file to load\n");
472  return RZ_CMD_STATUS_ERROR;
473  }
474  if (!rz_file_exists(filename)) {
475  RZ_LOG_ERROR("Cannot open file '%s'\n", filename);
476  free(filename);
477  return RZ_CMD_STATUS_ERROR;
478  }
479 
481  free(filename);
482  return status;
483 }
484 
486  char *filename = argc > 1 ? strdup(argv[1]) : rz_core_bin_pdb_get_filename(core);
487  if (!filename) {
488  RZ_LOG_ERROR("Cannot find the right PDB file to load\n");
489  return RZ_CMD_STATUS_ERROR;
490  }
491  if (!rz_file_exists(filename)) {
492  RZ_LOG_ERROR("Cannot open file '%s'\n", filename);
493  free(filename);
494  return RZ_CMD_STATUS_ERROR;
495  }
496  RzPdb *pdb = rz_core_pdb_load_info(core, filename);
497  if (!pdb) {
498  free(filename);
499  return false;
500  }
501  rz_core_pdb_info_print(core, core->analysis->typedb, pdb, state);
502  rz_bin_pdb_free(pdb);
503  free(filename);
504  return RZ_CMD_STATUS_OK;
505 }
506 
508  SPDBOptions pdbopts;
509  pdbopts.extract = rz_config_get_i(core->config, "pdb.extract");
510  pdbopts.symbol_store_path = rz_config_get(core->config, "pdb.symstore");
511  pdbopts.symbol_server = rz_config_get(core->config, "pdb.server");
512  if (state->mode == RZ_OUTPUT_MODE_JSON) {
513  pj_o(state->d.pj);
514  }
515  int r = rz_bin_pdb_download(core->bin, state->mode == RZ_OUTPUT_MODE_JSON ? state->d.pj : NULL, state->mode == RZ_OUTPUT_MODE_JSON, &pdbopts);
516  if (state->mode == RZ_OUTPUT_MODE_JSON) {
517  pj_end(state->d.pj);
518  }
519  if (r > 0 && state->mode != RZ_OUTPUT_MODE_JSON) {
520  RZ_LOG_ERROR("Error while downloading pdb file\n");
521  return RZ_CMD_STATUS_ERROR;
522  }
523  return RZ_CMD_STATUS_OK;
524 }
525 
526 RZ_IPI RzCmdStatus rz_cmd_pdb_extract_handler(RzCore *core, int argc, const char **argv) {
527  const char *file_cab = argv[1];
528  const char *output_dir = argv[2];
529  if (!rz_bin_pdb_extract_in_folder(file_cab, output_dir)) {
530  return RZ_CMD_STATUS_ERROR;
531  }
532  return RZ_CMD_STATUS_OK;
533 }
534 
535 static bool print_demangler_info(const RzDemanglerPlugin *plugin, void *user) {
536  if (!user) {
537  rz_cons_printf("%-6s %-8s %s\n", plugin->language, plugin->license, plugin->author);
538  return true;
539  }
541  switch (state->mode) {
543  rz_cons_println(plugin->language);
544  break;
545  case RZ_OUTPUT_MODE_JSON:
546  pj_o(state->d.pj);
547  pj_ks(state->d.pj, "language", plugin->language);
548  pj_ks(state->d.pj, "license", plugin->license);
549  pj_ks(state->d.pj, "author", plugin->author);
550  pj_end(state->d.pj);
551  break;
553  rz_table_add_rowf(state->d.t, "sss", plugin->language, plugin->license, plugin->author);
554  break;
555  default:
557  break;
558  }
559  return true;
560 }
561 
563  char **res = RZ_NEWS0(char *, rz_list_length(core->bin->demangler->plugins) + 1);
564  if (!res) {
565  return NULL;
566  }
567  const RzDemanglerPlugin *plugin;
568  RzListIter *it;
569  int i = 0;
570  rz_list_foreach (core->bin->demangler->plugins, it, plugin) {
571  res[i++] = strdup(plugin->language);
572  }
573  return res;
574 }
575 
577  char *output = NULL;
578  if (!rz_demangler_resolve(core->bin->demangler, argv[2], argv[1], &output)) {
579  rz_cons_printf("Language '%s' is unsupported\nList of supported languages:\n", argv[1]);
581  return RZ_CMD_STATUS_ERROR;
582  }
584  free(output);
585  return RZ_CMD_STATUS_OK;
586 }
587 
590  rz_cmd_state_output_set_columnsf(state, "sss", "language", "license", "author");
593  return RZ_CMD_STATUS_OK;
594 }
595 
597  GET_CHECK_CUR_BINFILE(core);
598  return bool2status(rz_core_bin_memory_print(core, bf, state));
599 }
600 
602  GET_CHECK_CUR_BINFILE(core);
603  RzList *hashes = rz_list_new_from_array((const void **)argv + 1, argc - 1);
604  if (!hashes) {
605  return RZ_CMD_STATUS_ERROR;
606  }
607  bool res = rz_core_bin_resources_print(core, bf, state, hashes);
608  rz_list_free(hashes);
609  return bool2status(res);
610 }
611 
613  ut64 limit = rz_config_get_i(core->config, "bin.hashlimit");
614  RzBinInfo *info = rz_bin_get_info(core->bin);
615  if (!info) {
616  eprintf("Cannot get bin info\n");
617  return RZ_CMD_STATUS_ERROR;
618  }
619 
620  GET_CHECK_CUR_BINFILE(core);
621 
622  RzList *new_hashes = rz_bin_file_compute_hashes(core->bin, bf, limit);
623  RzList *old_hashes = rz_bin_file_set_hashes(core->bin, new_hashes);
624  bool equal = true;
625  if (!rz_list_empty(new_hashes) && !rz_list_empty(old_hashes)) {
626  if (!is_equal_file_hashes(new_hashes, old_hashes, &equal)) {
627  eprintf("Cannot compare file hashes\n");
628  rz_list_free(old_hashes);
629  return RZ_CMD_STATUS_ERROR;
630  }
631  }
632  RzBinFileHash *fh_old, *fh_new;
633  RzListIter *hiter_old, *hiter_new;
634  switch (state->mode) {
635  case RZ_OUTPUT_MODE_JSON:
636  pj_o(state->d.pj);
637  rz_list_foreach (new_hashes, hiter_new, fh_new) {
638  pj_ks(state->d.pj, fh_new->type, fh_new->hex);
639  }
640  if (!equal) {
641  // print old hashes prefixed with `o` character like `omd5` and `isha1`
642  rz_list_foreach (old_hashes, hiter_old, fh_old) {
643  char *key = rz_str_newf("o%s", fh_old->type);
644  pj_ks(state->d.pj, key, fh_old->hex);
645  free(key);
646  }
647  }
648  pj_end(state->d.pj);
649  break;
651  if (!equal) {
652  eprintf("File has been modified.\n");
653  hiter_new = rz_list_iterator(new_hashes);
654  hiter_old = rz_list_iterator(old_hashes);
655  while (rz_list_iter_next(hiter_new) && rz_list_iter_next(hiter_old)) {
656  fh_new = (RzBinFileHash *)rz_list_iter_get(hiter_new);
657  fh_old = (RzBinFileHash *)rz_list_iter_get(hiter_old);
658  if (strcmp(fh_new->type, fh_old->type)) {
659  eprintf("Wrong file hashes structure");
660  }
661  if (!strcmp(fh_new->hex, fh_old->hex)) {
662  eprintf("= %s %s\n", fh_new->type, fh_new->hex); // output one line because hash remains same `= hashtype hashval`
663  } else {
664  // output diff-like two lines, one with old hash val `- hashtype hashval` and one with new `+ hashtype hashval`
665  eprintf("- %s %s\n+ %s %s\n",
666  fh_old->type, fh_old->hex,
667  fh_new->type, fh_new->hex);
668  }
669  }
670  } else { // hashes are equal
671  rz_list_foreach (new_hashes, hiter_new, fh_new) {
672  rz_cons_printf("%s %s\n", fh_new->type, fh_new->hex);
673  }
674  }
675  break;
676  default:
678  break;
679  }
680  rz_list_free(old_hashes);
681  return RZ_CMD_STATUS_OK;
682 }
683 
685  GET_CHECK_CUR_BINFILE(core);
686  return bool2status(rz_core_bin_versions_print(core, bf, state));
687 }
688 
690  GET_CHECK_CUR_BINFILE(core);
691  return bool2status(rz_core_bin_trycatch_print(core, bf, state));
692 }
693 
696 }
697 
700 }
701 
704 }
705 
707  GET_CHECK_CUR_BINFILE(core);
708  if (state->mode == RZ_OUTPUT_MODE_JSON) {
709  pj_o(state->d.pj);
710  pj_k(state->d.pj, "size");
711  }
712  bool res = rz_core_bin_size_print(core, bf, state);
713  if (state->mode == RZ_OUTPUT_MODE_JSON) {
714  pj_end(state->d.pj);
715  }
716  return bool2status(res);
717 }
#define mask()
#define RZ_IPI
Definition: analysis_wasm.c:11
lzma_index ** i
Definition: index.h:629
RZ_API RZ_OWN RzList * rz_bin_file_set_hashes(RzBin *bin, RZ_OWN RzList *new_hashes)
Set file_hashes on current RzBinInfo.
Definition: bfile.c:488
RZ_API RZ_OWN RzList * rz_bin_file_compute_hashes(RzBin *bin, RzBinFile *bf, ut64 limit)
Definition: bfile.c:411
RZ_DEPRECATE RZ_API RZ_BORROW RzBinInfo * rz_bin_get_info(RzBin *bin)
Definition: bin.c:585
RZ_API RzBinObject * rz_bin_cur_object(RzBin *bin)
Definition: bin.c:900
RZ_API const RzBinPlugin * rz_bin_plugin_get(RZ_NONNULL RzBin *bin, RZ_NONNULL const char *name)
Get a RzBinPlugin by name.
Definition: bin.c:1197
RZ_API const RzBinXtrPlugin * rz_bin_xtrplugin_get(RZ_NONNULL RzBin *bin, RZ_NONNULL const char *name)
Get a RzBinXtrPlugin by name.
Definition: bin.c:1214
RZ_API RzBinFile * rz_bin_cur(RzBin *bin)
Definition: bin.c:895
RzBinInfo * info(RzBinFile *bf)
Definition: bin_ne.c:86
RzList * sections(RzBinFile *bf)
Definition: bin_ne.c:110
RZ_API RZ_OWN RzList * rz_bin_object_get_sections(RZ_NONNULL RzBinObject *obj)
Get list of RzBinSection representing only the sections of the binary object.
Definition: bobj.c:774
RZ_API bool rz_bin_pdb_extract_in_folder(RZ_NONNULL const char *file_cab, RZ_NONNULL const char *output_dir)
Extracts compressed PDB files into a folder.
Definition: cab_extract.c:209
RZ_API bool rz_core_bin_class_as_source_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, const char *class_name)
Definition: cbin.c:3773
RZ_IPI RzCmdStatus rz_core_bin_plugin_print(const RzBinPlugin *bp, RzCmdStateOutput *state)
Definition: cbin.c:4783
RZ_API bool rz_core_bin_exports_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, RzCoreBinFilter *filter)
Definition: cbin.c:2044
RZ_API void rz_core_bin_export_info(RzCore *core, int mode)
Definition: cbin.c:108
RZ_API bool rz_core_bin_headers_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf)
Definition: cbin.c:4122
RZ_API void rz_core_bin_print_source_line_info(RzCore *core, const RzBinSourceLineInfo *li, RzCmdStateOutput *state)
Definition: cbin.c:1811
RZ_API bool rz_core_bin_fields_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:4070
RZ_API bool rz_core_bin_entries_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:1907
RZ_API bool rz_core_bin_cur_symbol_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:2036
RZ_API bool rz_core_bin_memory_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:4955
RZ_API bool rz_core_bin_whole_strings_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:2917
RZ_API bool rz_core_bin_signatures_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:4038
RZ_API bool rz_core_bin_cur_export_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:2050
RZ_API bool rz_core_bin_libs_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:2163
RZ_API bool rz_core_bin_initfini_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:1901
RZ_API bool rz_core_bin_print(RzCore *core, RZ_NONNULL RzBinFile *bf, ut32 mask, RzCoreBinFilter *filter, RzCmdStateOutput *state, RzList *hashes)
Print (to RzCons or inside RzCmdStateOutput) the binary information specified in mask.
Definition: cbin.c:386
RZ_API bool rz_core_bin_size_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:5151
RZ_API bool rz_core_bin_relocs_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:2224
RZ_API bool rz_core_bin_resources_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, RZ_NULLABLE RzList *hashes)
Definition: cbin.c:5045
RZ_API void rz_core_bin_print_source_line_sample(RzCore *core, const RzBinSourceLineSample *s, RzCmdStateOutput *state)
Definition: cbin.c:1778
RZ_API bool rz_core_bin_archs_print(RZ_NONNULL RzBin *bin, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:5217
RZ_API bool rz_core_bin_info_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:3044
RZ_API bool rz_core_bin_segments_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, RzCoreBinFilter *filter, RzList *hashes)
Definition: cbin.c:2633
RZ_API RzCmdStatus rz_core_bin_plugins_print(RzBin *bin, RzCmdStateOutput *state)
Definition: cbin.c:4855
RZ_API bool rz_core_bin_cur_section_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, RzList *hashes)
Definition: cbin.c:2541
RZ_API bool rz_core_bin_strings_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:2853
RZ_API bool rz_core_bin_symbols_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, RzCoreBinFilter *filter)
Definition: cbin.c:2030
RZ_API bool rz_core_bin_classes_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:3939
RZ_API RZ_OWN char * rz_core_bin_pdb_get_filename(RZ_NONNULL RzCore *core)
Definition: cbin.c:4886
RZ_API bool rz_core_bin_dwarf_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:4880
RZ_API bool rz_core_bin_cur_segment_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, RzList *hashes)
Definition: cbin.c:2549
RZ_API bool rz_core_bin_class_fields_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, const char *class_name)
Definition: cbin.c:3814
RZ_IPI RzCmdStatus rz_core_binxtr_plugin_print(const RzBinXtrPlugin *bx, RzCmdStateOutput *state)
Definition: cbin.c:4823
RZ_API bool rz_core_file_info_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *binfile, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:2943
RZ_API bool rz_core_bin_sections_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, RzCoreBinFilter *filter, RzList *hashes)
Definition: cbin.c:2472
RZ_API bool rz_core_bin_imports_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, RzCoreBinFilter *filter)
Definition: cbin.c:2058
RZ_API bool rz_core_bin_pdb_load(RZ_NONNULL RzCore *core, RZ_NONNULL const char *filename)
Definition: cbin.c:5264
RZ_API bool rz_core_bin_versions_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:5084
RZ_API bool rz_core_bin_trycatch_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:5102
RZ_API bool rz_core_bin_main_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state)
Definition: cbin.c:2192
RZ_API bool rz_core_bin_class_methods_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzBinFile *bf, RZ_NONNULL RzCmdStateOutput *state, const char *class_name)
Definition: cbin.c:3881
RZ_API void rz_cmd_state_output_set_columnsf(RzCmdStateOutput *state, const char *fmt,...)
Specify the columns of the command output.
Definition: cmd_api.c:2589
RZ_API void rz_cmd_state_output_array_start(RzCmdStateOutput *state)
Mark the start of an array of elements in the output.
Definition: cmd_api.c:2558
RZ_API void rz_cmd_state_output_array_end(RzCmdStateOutput *state)
Mark the end of an array of elements in the output.
Definition: cmd_api.c:2572
RZ_IPI RzCmdStatus rz_cmd_info_whole_strings_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:367
RZ_IPI RzCmdStatus rz_cmd_info_exports_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:218
RZ_IPI RzCmdStatus rz_cmd_info_imports_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:238
RZ_IPI RzCmdStatus rz_cmd_info_symbols_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:228
RZ_IPI RzCmdStatus rz_cmd_info_dwarf_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:463
RZ_IPI RzCmdStatus rz_cmd_info_pdb_download_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:507
#define GET_CHECK_CUR_BINFILE(core)
Definition: cmd_info.c:176
RZ_IPI RzCmdStatus rz_cmd_info_class_fields_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:411
RZ_IPI RzCmdStatus rz_cmd_info_cur_symbol_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:233
RZ_IPI RzCmdStatus rz_cmd_pdb_extract_handler(RzCore *core, int argc, const char **argv)
Definition: cmd_info.c:526
RZ_IPI RzCmdStatus rz_cmd_info_guess_size_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:706
RZ_IPI RzCmdStatus rz_cmd_info_section_bars_handler(RzCore *core, int argc, const char **argv)
Definition: cmd_info.c:280
RZ_IPI RzCmdStatus rz_cmd_info_classes_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:401
RZ_IPI RzCmdStatus rz_cmd_info_main_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:248
RZ_IPI RzCmdStatus rz_cmd_info_binary_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:436
RZ_IPI RzCmdStatus rz_cmd_info_hashes_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:612
RZ_IPI RzCmdStatus rz_cmd_info_class_methods_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:416
static bool source_file_collect_cb(void *user, const void *k, const void *v)
Definition: cmd_info.c:51
RZ_IPI RzCmdStatus rz_cmd_info_signature_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:421
RZ_IPI RzCmdStatus rz_cmd_info_cur_section_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:269
RZ_IPI RzCmdStatus rz_cmd_info_demangle_handler(RzCore *core, int argc, const char **argv)
Definition: cmd_info.c:576
RZ_IPI RzCmdStatus rz_cmd_info_cur_export_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:223
static bool print_source_info(RzCore *core, PrintSourceInfoType type, RzCmdStateOutput *state)
Definition: cmd_info.c:66
RZ_IPI int rz_cmd_info_kuery(void *data, const char *input)
Definition: cmd_info.c:131
RZ_IPI RzCmdStatus rz_cmd_info_versions_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:684
RZ_IPI RzCmdStatus rz_cmd_info_libs_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:243
static bool is_equal_file_hashes(RzList *lfile_hashes, RzList *rfile_hashes, bool *equal)
Definition: cmd_info.c:29
PrintSourceInfoType
Definition: cmd_info.c:60
@ PRINT_SOURCE_INFO_LINES_ALL
Definition: cmd_info.c:61
@ PRINT_SOURCE_INFO_FILES
Definition: cmd_info.c:63
@ PRINT_SOURCE_INFO_LINES_HERE
Definition: cmd_info.c:62
RZ_IPI RzCmdStatus rz_cmd_info_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:379
static bool print_demangler_info(const RzDemanglerPlugin *plugin, void *user)
Definition: cmd_info.c:535
RZ_IPI RzCmdStatus rz_cmd_info_segments_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:340
RZ_IPI RzCmdStatus rz_cmd_info_fields_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:426
RZ_IPI RzCmdStatus rz_cmd_info_all_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:187
RZ_IPI RzCmdStatus rz_cmd_info_class_as_source_handler(RzCore *core, int argc, const char **argv)
Definition: cmd_info.c:406
static int bin_is_executable(RzBinObject *obj)
Definition: cmd_info.c:13
RZ_IPI RzCmdStatus rz_cmd_info_headers_handler(RzCore *core, int argc, const char **argv)
Definition: cmd_info.c:431
RZ_IPI RzCmdStatus rz_cmd_info_purge_string_handler(RzCore *core, int argc, const char **argv)
Definition: cmd_info.c:372
RZ_IPI RzCmdStatus rz_cmd_info_sections_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:258
RZ_IPI RzCmdStatus rz_cmd_info_source_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:702
RZ_IPI RzCmdStatus rz_cmd_info_pdb_show_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:485
RZ_IPI RzCmdStatus rz_cmd_info_resources_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:601
RZ_IPI RzCmdStatus rz_cmd_info_sourcelines_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:694
RZ_IPI char ** rz_cmd_info_demangle_lang_choices(RzCore *core)
Definition: cmd_info.c:562
RZ_IPI RzCmdStatus rz_cmd_info_strings_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:362
RZ_IPI RzCmdStatus rz_cmd_info_entryexits_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:213
RZ_IPI RzCmdStatus rz_cmd_info_cur_segment_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:351
RZ_IPI RzCmdStatus rz_cmd_info_archs_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:183
RZ_IPI RzCmdStatus rz_cmd_info_plugins_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:441
RZ_IPI RzCmdStatus rz_cmd_info_memory_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:596
RZ_IPI RzCmdStatus rz_cmd_info_trycatch_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:689
RZ_IPI RzCmdStatus rz_cmd_info_entry_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:208
RZ_IPI RzCmdStatus rz_cmd_info_pdb_load_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:468
RZ_IPI RzCmdStatus rz_cmd_info_demangle_list_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:588
RZ_IPI RzCmdStatus rz_cmd_info_relocs_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:253
RZ_IPI RzCmdStatus rz_cmd_info_sourcelines_here_handler(RzCore *core, int argc, const char **argv, RzCmdStateOutput *state)
Definition: cmd_info.c:698
RZ_API ut64 rz_config_get_i(RzConfig *cfg, RZ_NONNULL const char *name)
Definition: config.c:119
RZ_API RzConfigNode * rz_config_set(RzConfig *cfg, RZ_NONNULL const char *name, const char *value)
Definition: config.c:267
RZ_API RZ_BORROW const char * rz_config_get(RzConfig *cfg, RZ_NONNULL const char *name)
Definition: config.c:75
RZ_API int rz_cons_get_size(int *rows)
Definition: cons.c:1446
RZ_API int rz_cons_printf(const char *format,...)
Definition: cons.c:1202
RZ_API void rz_cons_println(const char *str)
Definition: cons.c:233
static RzCmdStatus bool2status(bool val)
Definition: core_private.h:208
RZ_API void rz_core_pdb_info_print(RZ_NONNULL RzCore *core, RZ_NONNULL RzTypeDB *db, RZ_NONNULL RzPdb *pdb, RZ_NONNULL RzCmdStateOutput *state)
Print parsed PDB file info.
Definition: cpdb.c:273
RZ_API RzPdb * rz_core_pdb_load_info(RZ_NONNULL RzCore *core, RZ_NONNULL const char *file)
Parse PDB file info and integrate with typedb.
Definition: cpdb.c:245
#define NULL
Definition: cris-opc.c:27
#define r
Definition: crypto_rc6.c:12
static static sync static getppid static getegid const char static filename char static len const char char static bufsiz static mask static vfork const void static prot static getpgrp const char static swapflags static arg static fd static protocol static who struct sockaddr static addrlen static backlog struct timeval struct timezone static tz const struct iovec static count static mode const void const struct sockaddr static tolen const char static pathname void static offset struct stat static buf void long static basep static whence static length const void static len key
Definition: sflib.h:118
RZ_API const RzBinSourceLineSample * rz_bin_source_line_info_get_next(const RzBinSourceLineInfo *sli, RZ_NONNULL const RzBinSourceLineSample *cur)
Definition: dbginfo.c:182
RZ_API const RzBinSourceLineSample * rz_bin_source_line_info_get_first_at(const RzBinSourceLineInfo *sli, ut64 addr)
Find the first sample that affects the given address. i.e. find the first sample with the highest add...
Definition: dbginfo.c:151
uint32_t ut32
const char * k
Definition: dsignal.c:11
const char * v
Definition: dsignal.c:12
checking print the parsed form of the magic use in n conjunction with m to debug a new magic file n before installing it n output MIME type special files
Definition: file_opts.h:46
RZ_API void Ht_() free(HtName_(Ht) *ht)
Definition: ht_inc.c:130
const char * filename
Definition: ioapi.h:137
RZ_API RzTable * rz_core_table(RzCore *core)
Definition: core.c:3449
RZ_API bool rz_demangler_resolve(RZ_NONNULL RzDemangler *dem, RZ_NULLABLE const char *symbol, RZ_NONNULL const char *language, RZ_NONNULL RZ_OWN char **output)
Resolves a symbol based on its language and return an output that needs to be freed.
Definition: demangler.c:187
RZ_API void rz_demangler_plugin_iterate(RZ_NONNULL RzDemangler *dem, RZ_NONNULL RzDemanglerIter iter, RZ_NULLABLE void *data)
Iterates over the plugin list.
Definition: demangler.c:127
static void list(RzEgg *egg)
Definition: rz-gg.c:52
RZ_API RZ_BORROW RzListIter * rz_list_iterator(const RzList *list)
returns the first RzList iterator int the list
Definition: list.c:51
RZ_API RZ_OWN RzList * rz_list_newf(RzListFree f)
Returns a new initialized RzList pointer and sets the free method.
Definition: list.c:248
RZ_API RZ_OWN RzList * rz_list_new_from_array(RZ_NONNULL const void **arr, size_t arr_size)
Allocates a new RzList and adds an array elements to it.
Definition: list.c:260
RZ_API ut32 rz_list_length(RZ_NONNULL const RzList *list)
Returns the length of the list.
Definition: list.c:109
RZ_API RZ_BORROW RzListIter * rz_list_append(RZ_NONNULL RzList *list, void *data)
Appends at the end of the list a new element.
Definition: list.c:288
RZ_API void rz_list_free(RZ_NONNULL RzList *list)
Empties the list and frees the list pointer.
Definition: list.c:137
RZ_API char * sdb_querys(Sdb *r, char *buf, size_t len, const char *_cmd)
Definition: query.c:164
static static fork const void static count static fd const char const char static newpath char char argv
Definition: sflib.h:40
return strdup("=SP r13\n" "=LR r14\n" "=PC r15\n" "=A0 r0\n" "=A1 r1\n" "=A2 r2\n" "=A3 r3\n" "=ZF zf\n" "=SF nf\n" "=OF vf\n" "=CF cf\n" "=SN or0\n" "gpr lr .32 56 0\n" "gpr pc .32 60 0\n" "gpr cpsr .32 64 0 ____tfiae_________________qvczn\n" "gpr or0 .32 68 0\n" "gpr tf .1 64.5 0 thumb\n" "gpr ef .1 64.9 0 endian\n" "gpr jf .1 64.24 0 java\n" "gpr qf .1 64.27 0 sticky_overflow\n" "gpr vf .1 64.28 0 overflow\n" "gpr cf .1 64.29 0 carry\n" "gpr zf .1 64.30 0 zero\n" "gpr nf .1 64.31 0 negative\n" "gpr itc .4 64.10 0 if_then_count\n" "gpr gef .4 64.16 0 great_or_equal\n" "gpr r0 .32 0 0\n" "gpr r1 .32 4 0\n" "gpr r2 .32 8 0\n" "gpr r3 .32 12 0\n" "gpr r4 .32 16 0\n" "gpr r5 .32 20 0\n" "gpr r6 .32 24 0\n" "gpr r7 .32 28 0\n" "gpr r8 .32 32 0\n" "gpr r9 .32 36 0\n" "gpr r10 .32 40 0\n" "gpr r11 .32 44 0\n" "gpr r12 .32 48 0\n" "gpr r13 .32 52 0\n" "gpr r14 .32 56 0\n" "gpr r15 .32 60 0\n" "gpr r16 .32 64 0\n" "gpr r17 .32 68 0\n")
static const char struct stat static buf struct stat static buf static vhangup int status
Definition: sflib.h:145
static uint32_t const uint8_t uint32_t uint32_t limit
Definition: memcmplen.h:45
int type
Definition: mipsasm.c:17
RZ_API void rz_bin_pdb_free(RzPdb *pdb)
Free PDB instance.
Definition: pdb.c:366
RZ_API int rz_bin_pdb_download(RZ_NONNULL RzBin *bin, RZ_NULLABLE PJ *pj, int isradjson, RZ_NONNULL SPDBOptions *options)
Download PDB file for currently opened RzBin file.
#define eprintf(x, y...)
Definition: rlcc.c:7
static RzSocket * s
Definition: rtr.c:28
#define rz_warn_if_reached()
Definition: rz_assert.h:29
#define rz_return_val_if_fail(expr, val)
Definition: rz_assert.h:108
enum rz_cmd_status_t RzCmdStatus
@ RZ_CMD_STATUS_OK
command handler exited in the right way
Definition: rz_cmd.h:24
@ RZ_CMD_STATUS_ERROR
command handler had issues while running (e.g. allocation error, etc.)
Definition: rz_cmd.h:26
bool(* RzDemanglerIter)(const RzDemanglerPlugin *plugin, void *data)
Definition: rz_demangler.h:27
RZ_API bool rz_file_exists(const char *str)
Definition: file.c:192
struct rz_interval_t RzInterval
void(* RzListFree)(void *ptr)
Definition: rz_list.h:11
#define RZ_LOG_ERROR(fmtstr,...)
Definition: rz_log.h:58
RZ_API char * rz_num_units(char *buf, size_t len, ut64 number)
Definition: unum.c:108
RZ_API PJ * pj_k(PJ *j, const char *k)
Definition: pj.c:104
RZ_API PJ * pj_end(PJ *j)
Definition: pj.c:87
RZ_API PJ * pj_o(PJ *j)
Definition: pj.c:75
RZ_API PJ * pj_s(PJ *j, const char *k)
Definition: pj.c:197
RZ_API PJ * pj_ks(PJ *j, const char *k, const char *v)
Definition: pj.c:170
RZ_API PJ * pj_a(PJ *j)
Definition: pj.c:81
RZ_API char * rz_str_newf(const char *fmt,...) RZ_PRINTF_CHECK(1
#define rz_strf(buf,...)
Convenience macro for local temporary strings.
Definition: rz_str.h:59
RZ_API void rz_table_visual_list(RzTable *table, RzList *list, ut64 seek, ut64 len, int width, bool va)
Definition: table.c:1205
RZ_API void rz_table_add_rowf(RzTable *t, const char *fmt,...)
Definition: table.c:316
RZ_API void rz_table_free(RzTable *t)
Definition: table.c:114
RZ_API char * rz_table_tostring(RzTable *t)
Definition: table.c:510
#define RZ_MODE_RIZINCMD
Definition: rz_types.h:26
#define RZ_PERM_X
Definition: rz_types.h:95
#define RZ_NEWS0(x, y)
Definition: rz_types.h:282
@ RZ_OUTPUT_MODE_TABLE
Definition: rz_types.h:46
@ RZ_OUTPUT_MODE_JSON
Definition: rz_types.h:40
@ RZ_OUTPUT_MODE_QUIET
Definition: rz_types.h:42
@ RZ_OUTPUT_MODE_STANDARD
Definition: rz_types.h:39
#define PFMT64x
Definition: rz_types.h:393
RZ_API void rz_pvector_sort(RzPVector *vec, RzPVectorComparator cmp)
Definition: vector.c:408
RZ_API void rz_pvector_init(RzPVector *vec, RzPVectorFree free)
Definition: vector.c:298
RZ_API void rz_pvector_fini(RzPVector *vec)
Definition: vector.c:331
static void ** rz_pvector_push(RzPVector *vec, void *x)
Definition: rz_vector.h:300
int(* RzPVectorComparator)(const void *a, const void *b)
Definition: rz_vector.h:40
#define rz_pvector_foreach(vec, it)
Definition: rz_vector.h:334
#define f(i)
Definition: sha256.c:46
const char * symbol_server
const char * symbol_store_path
Definition: gzappend.c:170
RzTypeDB * typedb
Definition: rz_analysis.h:602
const char * type
Definition: rz_bin.h:205
const char * hex
Definition: rz_bin.h:206
XX curplugin == o->plugin.
Definition: rz_bin.h:298
RzBinObject * o
Definition: rz_bin.h:305
char * arch
Definition: rz_bin.h:214
RzBinSourceLineInfo * lines
Definition: rz_bin.h:284
RzBinInfo * info
Definition: rz_bin.h:287
RZ_DEPRECATE RZ_BORROW Sdb * kv
deprecated, put info in C structures instead of this (holds a copy of another pointer....
Definition: rz_bin.h:291
RzList * sections
Definition: rz_bin.h:267
RzBinSourceLineSample * samples
All source line references for given adresses.
Definition: rz_bin.h:486
A single sample of source line info for a specific address.
Definition: rz_bin.h:441
char * strpurge
Definition: rz_bin.h:354
RzDemangler * demangler
Definition: rz_bin.h:364
RZ_DEPRECATE RzBinFile * cur
never use this in new code! Get a file from the binfiles list or track it yourself.
Definition: rz_bin.h:330
Represent the output state of a command handler.
Definition: rz_cmd.h:91
RzBin * bin
Definition: rz_core.h:298
ut64 offset
Definition: rz_core.h:301
RzAnalysis * analysis
Definition: rz_core.h:322
RzIO * io
Definition: rz_core.h:313
RzCoreFile * file
Definition: rz_core.h:314
RzConfig * config
Definition: rz_core.h:300
const char * language
demangler language
Definition: rz_demangler.h:17
const char * author
demangler author
Definition: rz_demangler.h:18
const char * license
demangler license
Definition: rz_demangler.h:19
RzList * plugins
Definition: rz_demangler.h:24
int va
Definition: rz_io.h:63
Definition: sdb.h:63
uint32_t size
Definition: dis.h:43
RZ_API RzListInfo * rz_listinfo_new(const char *name, RzInterval pitv, RzInterval vitv, int perm, const char *extra)
Definition: visual.c:4020
RZ_API void rz_listinfo_free(RzListInfo *info)
Definition: visual.c:4032
ut64(WINAPI *w32_GetEnabledXStateFeatures)()
static bool input(void *ud, zip_uint8_t *data, zip_uint64_t length)
diff_output_t output
Definition: zipcmp.c:237