This file is indexed.

/usr/include/libr/r_cmd.h is in libradare2-dev 0.9.6-3.1ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
#ifndef _INCLUDE_R_CMD_H_
#define _INCLUDE_R_CMD_H_

#include <r_types.h>
#include <r_util.h>
#include "list.h"

#ifdef __cplusplus
extern "C" {
#endif

R_LIB_VERSION_HEADER(r_cmd);

#define MACRO_LIMIT 1024
#define MACRO_LABELS 20
#define R_CMD_MAXLEN 4096

#define r_cmd_callback(x) int (*x)(void *data, const char *input)
#define r_cmd_nullcallback(x) int (*x)(void *data);

typedef struct r_cmd_macro_label_t {
	char name[80];
	char *ptr;
} RCmdMacroLabel;

typedef struct r_cmd_macro_item_t {
	char *name;
	char *args;
	char *code;
	int codelen;
	int nargs;
} RCmdMacroItem;

typedef struct r_cmd_macro_t {
	int counter;
	ut64 *brk_value;
	ut64 _brk_value;
	int brk;
	int (*cmd)(void *user, const char *cmd);
	PrintfCallback printf;
	void *user;
	RNum *num;
	int labels_n;
	RCmdMacroLabel labels[MACRO_LABELS];
	RList *macros;
} RCmdMacro;

typedef int (*RCmdCallback)(void *user, const char *cmd);

typedef struct r_cmd_item_t {
	char cmd[64];
	char desc[128];
	r_cmd_callback (callback);
} RCmdItem;

typedef struct r_cmd_long_item_t {
	char cmd[64]; /* long command */
	int cmd_len;
	char cmd_short[32]; /* short command */
	char desc[128];
} RCmdLongItem;

typedef struct r_cmd_alias_t {
	int count;
	char **keys;
	char **values;
} RCmdAlias;

typedef struct r_cmd_t {
	void *data;
	r_cmd_nullcallback (nullcallback);
	RCmdItem *cmds[UT8_MAX];
	RCmdMacro macro;
	RList *lcmds;
	RList *plist;
	RCmdAlias aliases;
} RCmd;

typedef struct r_cmd_plugin_t {
	char *name;
	char *desc;
	RCmdCallback call;
} RCmdPlugin;

#ifdef R_API
R_API RCmd *r_cmd_new();
R_API RCmd *r_cmd_free(RCmd *cmd);
R_API int r_cmd_set_data(RCmd *cmd, void *data);
R_API int r_cmd_add(RCmd *cmd, const char *command, const char *desc, r_cmd_callback(callback));
R_API int r_cmd_add_long(RCmd *cmd, const char *longcmd, const char *shortcmd, const char *desc);
R_API int r_cmd_del(RCmd *cmd, const char *command);
R_API int r_cmd_call(RCmd *cmd, const char *command);
R_API int r_cmd_call_long(RCmd *cmd, const char *input);
R_API char **r_cmd_args(RCmd *cmd, int *argc);

R_API int r_cmd_plugin_init(RCmd *cmd);
R_API int r_cmd_plugin_add(RCmd *cmd, RCmdPlugin *plugin);
R_API int r_cmd_plugin_check(RCmd *cmd, const char *a0);

/* plugins */
extern struct r_cmd_plugin_t r_cmd_plugin_dummy;

/* r_cmd_macro */
R_API void r_cmd_macro_init(RCmdMacro *mac);
R_API int r_cmd_macro_add(RCmdMacro *mac, const char *name);
R_API int r_cmd_macro_rm(RCmdMacro *mac, const char *_name);
R_API void r_cmd_macro_list(RCmdMacro *mac);
R_API int r_cmd_macro_call(RCmdMacro *mac, const char *name);
R_API int r_cmd_macro_break(RCmdMacro *mac, const char *value);

R_API int r_cmd_alias_del (RCmd *cmd, const char *k);
R_API char **r_cmd_alias_keys(RCmd *cmd, int *sz);
R_API int r_cmd_alias_set (RCmd *cmd, const char *k, const char *v);
R_API char *r_cmd_alias_get (RCmd *cmd, const char *k);
R_API void r_cmd_alias_free (RCmd *cmd);

#ifdef __cplusplus
}
#endif

#endif
#endif