Skip to content

Commit

Permalink
Integrate support for FLIRT signatures
Browse files Browse the repository at this point in the history
  • Loading branch information
jroimartin committed Mar 13, 2017
1 parent 37da8b4 commit 5743f37
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
17 changes: 17 additions & 0 deletions libr/core/cmd_zign.c
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,23 @@ static int zignFlirt(void *data, const char *input) {
RCore *core = (RCore *) data;

switch (*input) {
case 'd':
if (input[1] != ' ') {
eprintf ("usage: zfd filename\n");
return false;
}
r_sign_flirt_dump (core->anal, input + 2);
break;
case 's':
if(input[1] != ' ') {
eprintf ("usage: zfs filename\n");
return false;
}
r_sign_flirt_scan (core->anal, input + 2);
break;
case 'z':
eprintf ("TODO\n");
break;
case '?':
{
const char *help_msg[] = {
Expand Down
4 changes: 4 additions & 0 deletions libr/include/r_sign.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@ R_API int r_sign_search_update(RAnal *a, RSignSearch *ss, ut64 *at, const ut8 *b

R_API RSignItem *r_sign_item_dup(RSignItem *it);
R_API void r_sign_item_free(void *_item);

R_API int r_sign_is_flirt(RBuffer *buf);
R_API void r_sign_flirt_dump(const RAnal *anal, const char *flirt_file);
R_API void r_sign_flirt_scan(const RAnal *anal, const char *flirt_file);
#endif

#ifdef __cplusplus
Expand Down

0 comments on commit 5743f37

Please sign in to comment.