30 #include <epan/wmem/wmem.h> 36 #include "value_string.h" 39 #include "ftypes/ftypes.h" 41 #include "ws_symbol_export.h" 42 #include "ws_attributes.h" 44 #include "wsutil/plugins.h" 63 #define ITEM_LABEL_LENGTH 240 65 #define ITEM_LABEL_UNKNOWN_STR "Unknown" 70 #define VALS(x) (const struct _value_string*)(x) 73 #define VALS64(x) (const struct _val64_string*)(x) 76 #define VALS_EXT_PTR(x) (x) 79 #define TFS(x) (const struct true_false_string*)(x) 81 typedef void (*custom_fmt_func_t)(gchar *, guint32);
83 typedef void (*custom_fmt_func_64_t)(gchar *, guint64);
92 #define CF_FUNC(x) ((const void *) (gsize) (x)) 96 #define RVALS(x) (const struct _range_string*)(x) 99 #define FRAMENUM_TYPE(x) GINT_TO_POINTER(x) 116 WS_DLL_PUBLIC WS_NORETURN
120 #define REPORT_DISSECTOR_BUG(...) \ 121 proto_report_dissector_bug(__VA_ARGS__) 128 #define __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT(expression) \ 129 ; __analysis_assume(expression); 131 #define __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT(expression) 145 #define __DISSECTOR_ASSERT_STRINGIFY(s) # s 147 #define __DISSECTOR_ASSERT(expression, file, lineno) \ 148 (REPORT_DISSECTOR_BUG("%s:%u: failed assertion \"%s\"", \ 149 file, lineno, __DISSECTOR_ASSERT_STRINGIFY(expression))) 151 #define __DISSECTOR_ASSERT_HINT(expression, file, lineno, hint) \ 152 (REPORT_DISSECTOR_BUG("%s:%u: failed assertion \"%s\" (%s)", \ 153 file, lineno, __DISSECTOR_ASSERT_STRINGIFY(expression), hint)) 155 #define DISSECTOR_ASSERT(expression) \ 156 ((void) ((expression) ? (void)0 : \ 157 __DISSECTOR_ASSERT (expression, __FILE__, __LINE__))) \ 158 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT(expression) 167 #define DISSECTOR_ASSERT_HINT(expression, hint) \ 168 ((void) ((expression) ? (void)0 : \ 169 __DISSECTOR_ASSERT_HINT (expression, __FILE__, __LINE__, hint))) \ 170 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT(expression) 175 #define DISSECTOR_ASSERT(expression) \ 176 { if(!(expression)) _asm { int 3}; } 187 #define DISSECTOR_ASSERT_NOT_REACHED() \ 188 (REPORT_DISSECTOR_BUG("%s:%u: failed assertion \"DISSECTOR_ASSERT_NOT_REACHED\"", \ 210 #define __DISSECTOR_ASSERT_CMPINT(a, op, b, type, fmt) \ 211 (REPORT_DISSECTOR_BUG("%s:%u: failed assertion " #a " " #op " " #b " (" fmt " " #op " " fmt ")", \ 212 __FILE__, __LINE__, (type)a, (type)b)) 214 #define DISSECTOR_ASSERT_CMPINT(a, op, b) \ 215 ((void) ((a op b) ? (void)0 : \ 216 __DISSECTOR_ASSERT_CMPINT (a, op, b, gint64, "%" G_GINT64_MODIFIER "d"))) \ 217 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT(a op b) 224 #define DISSECTOR_ASSERT_CMPUINT(a, op, b) \ 225 ((void) ((a op b) ? (void)0 : \ 226 __DISSECTOR_ASSERT_CMPINT (a, op, b, guint64, "%" G_GINT64_MODIFIER "u"))) \ 227 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT(a op b) 232 #define DISSECTOR_ASSERT_CMPUINTHEX(a, op, b) \ 233 ((void) ((a op b) ? (void)0 : \ 234 __DISSECTOR_ASSERT_CMPINT (a, op, b, guint64, "0x%" G_GINT64_MODIFIER "X"))) \ 235 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT(a op b) 245 #define __DISSECTOR_ASSERT_FIELD_TYPE(hfinfo, t) \ 246 (REPORT_DISSECTOR_BUG("%s:%u: field %s is not of type "#t, \ 247 __FILE__, __LINE__, (hfinfo)->abbrev)) 249 #define DISSECTOR_ASSERT_FIELD_TYPE(hfinfo, t) \ 250 ((void) (((hfinfo)->type == t) ? (void)0 : \ 251 __DISSECTOR_ASSERT_FIELD_TYPE ((hfinfo), t))) \ 252 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT((hfinfo)->type == t) 254 #define DISSECTOR_ASSERT_FIELD_TYPE_IS_INTEGRAL(hfinfo) \ 255 ((void) ((IS_FT_INT((hfinfo)->type) || \ 256 IS_FT_UINT((hfinfo)->type)) ? (void)0 : \ 257 REPORT_DISSECTOR_BUG("%s:%u: field %s is not of type FT_CHAR or an FT_{U}INTn type", \ 258 __FILE__, __LINE__, (hfinfo)->abbrev))) \ 259 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT(IS_FT_INT((hfinfo)->type) || \ 260 IS_FT_UINT((hfinfo)->type)) 262 #define __DISSECTOR_ASSERT_FIELD_TYPE_IS_STRING(hfinfo) \ 263 (REPORT_DISSECTOR_BUG("%s:%u: field %s is not of type FT_STRING, FT_STRINGZ, or FT_STRINGZPAD", \ 264 __FILE__, __LINE__, (hfinfo)->abbrev)) 266 #define DISSECTOR_ASSERT_FIELD_TYPE_IS_STRING(hfinfo) \ 267 ((void) (((hfinfo)->type == FT_STRING || (hfinfo)->type == FT_STRINGZ || \ 268 (hfinfo)->type == FT_STRINGZPAD) ? (void)0 : \ 269 __DISSECTOR_ASSERT_FIELD_TYPE_IS_STRING ((hfinfo)))) \ 270 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT((hfinfo)->type == FT_STRING || \ 271 (hfinfo)->type == FT_STRINGZ || \ 272 (hfinfo)->type == FT_STRINGZPAD) 274 #define __DISSECTOR_ASSERT_FIELD_TYPE_IS_TIME(hfinfo) \ 275 (REPORT_DISSECTOR_BUG("%s:%u: field %s is not of type FT_ABSOLUTE_TIME or FT_RELATIVE_TIME", \ 276 __FILE__, __LINE__, (hfinfo)->abbrev)) 278 #define DISSECTOR_ASSERT_FIELD_TYPE_IS_TIME(hfinfo) \ 279 ((void) (((hfinfo)->type == FT_ABSOLUTE_TIME || \ 280 (hfinfo)->type == FT_RELATIVE_TIME) ? (void)0 : \ 281 __DISSECTOR_ASSERT_FIELD_TYPE_IS_TIME ((hfinfo)))) \ 282 __DISSECTOR_ASSERT_STATIC_ANALYSIS_HINT((hfinfo)->type == FT_ABSOLUTE_TIME || \ 283 (hfinfo)->type == FT_RELATIVE_TIME) 333 #define ENC_BIG_ENDIAN 0x00000000 334 #define ENC_LITTLE_ENDIAN 0x80000000 336 #if G_BYTE_ORDER == G_LITTLE_ENDIAN 337 #define ENC_HOST_ENDIAN ENC_LITTLE_ENDIAN 339 #define ENC_HOST_ENDIAN ENC_BIG_ENDIAN 392 #define ENC_TIME_TIMESPEC 0x00000000 393 #define ENC_TIME_NTP 0x00000002 394 #define ENC_TIME_TOD 0x00000004 395 #define ENC_TIME_RTPS 0x00000008 396 #define ENC_TIME_NTP_BASE_ZERO ENC_TIME_RTPS 397 #define ENC_TIME_TIMEVAL 0x00000010 398 #define ENC_TIME_SECS 0x00000012 399 #define ENC_TIME_MSECS 0x00000014 400 #define ENC_TIME_SECS_NTP 0x00000018 401 #define ENC_TIME_RFC_3971 0x00000020 402 #define ENC_TIME_MSEC_NTP 0x00000022 431 #define ENC_CHARENCODING_MASK 0x7FFFFFFE 432 #define ENC_ASCII 0x00000000 433 #define ENC_UTF_8 0x00000002 434 #define ENC_UTF_16 0x00000004 435 #define ENC_UCS_2 0x00000006 436 #define ENC_UCS_4 0x00000008 437 #define ENC_ISO_8859_1 0x0000000A 438 #define ENC_ISO_8859_2 0x0000000C 439 #define ENC_ISO_8859_3 0x0000000E 440 #define ENC_ISO_8859_4 0x00000010 441 #define ENC_ISO_8859_5 0x00000012 442 #define ENC_ISO_8859_6 0x00000014 443 #define ENC_ISO_8859_7 0x00000016 444 #define ENC_ISO_8859_8 0x00000018 445 #define ENC_ISO_8859_9 0x0000001A 446 #define ENC_ISO_8859_10 0x0000001C 447 #define ENC_ISO_8859_11 0x0000001E 449 #define ENC_ISO_8859_13 0x00000022 450 #define ENC_ISO_8859_14 0x00000024 451 #define ENC_ISO_8859_15 0x00000026 452 #define ENC_ISO_8859_16 0x00000028 453 #define ENC_WINDOWS_1250 0x0000002A 454 #define ENC_3GPP_TS_23_038_7BITS 0x0000002C 455 #define ENC_EBCDIC 0x0000002E 456 #define ENC_MAC_ROMAN 0x00000030 457 #define ENC_CP437 0x00000032 458 #define ENC_ASCII_7BITS 0x00000034 459 #define ENC_T61 0x00000036 460 #define ENC_EBCDIC_CP037 0x00000038 461 #define ENC_ZIGBEE 0x0000003A 483 #define ENC_NA 0x00000000 492 #define ENC_STR_NUM 0x01000000 494 #define ENC_STR_HEX 0x02000000 496 #define ENC_STRING 0x03000000 498 #define ENC_STR_MASK 0x0000FFFE 502 #define ENC_NUM_PREF 0x00200000 507 #define ENC_VARINT_PROTOBUF 0x00000002 512 #define ENC_VARINT_QUIC 0x00000004 518 #define ENC_SEP_NONE 0x00010000 519 #define ENC_SEP_COLON 0x00020000 520 #define ENC_SEP_DASH 0x00040000 521 #define ENC_SEP_DOT 0x00080000 522 #define ENC_SEP_SPACE 0x00100000 524 #define ENC_SEP_MASK 0x001F0000 530 #define ENC_ISO_8601_DATE 0x00010000 531 #define ENC_ISO_8601_TIME 0x00020000 532 #define ENC_ISO_8601_DATE_TIME 0x00030000 533 #define ENC_RFC_822 0x00040000 534 #define ENC_RFC_1123 0x00080000 536 #define ENC_STR_TIME_MASK 0x000F0000 544 #define FIELD_DISPLAY_E_MASK 0xFF 588 #define FIELD_DISPLAY(d) ((d) & FIELD_DISPLAY_E_MASK) 592 #define BASE_RANGE_STRING 0x0100 593 #define BASE_EXT_STRING 0x0200 594 #define BASE_VAL64_STRING 0x0400 595 #define BASE_ALLOW_ZERO 0x0800 596 #define BASE_UNIT_STRING 0x1000 597 #define BASE_NO_DISPLAY_VALUE 0x2000 599 #define BASE_PROTOCOL_INFO 0x4000 600 #define BASE_SPECIAL_VALS 0x8000 603 #define IS_BASE_DUAL(b) ((b)==BASE_DEC_HEX||(b)==BASE_HEX_DEC) 606 #define IS_BASE_PORT(b) (((b)==BASE_PT_UDP||(b)==BASE_PT_TCP||(b)==BASE_PT_DCCP||(b)==BASE_PT_SCTP)) 647 #define HFILL -1, 0, HF_REF_TYPE_NONE, -1, NULL 649 #define HFILL_INIT(hf) \ 650 (hf).hfinfo.id = -1; \ 651 (hf).hfinfo.parent = 0; \ 652 (hf).hfinfo.ref_type = HF_REF_TYPE_NONE; \ 653 (hf).hfinfo.same_name_prev_id = -1; \ 654 (hf).hfinfo.same_name_next = NULL; 677 gint appendix_length;
696 guint crumb_bit_offset;
697 guint8 crumb_bit_length;
710 #define FI_HIDDEN 0x00000001 713 #define FI_GENERATED 0x00000002 715 #define FI_URL 0x00000004 718 #define FI_LITTLE_ENDIAN 0x00000008 720 #define FI_BIG_ENDIAN 0x00000010 722 #define FI_BITS_OFFSET(n) (((n) & 7) << 5) 725 #define FI_BITS_SIZE(n) (((n) & 63) << 8) 727 #define FI_VARINT 0x00004000 730 #define FI_GET_FLAG(fi, flag) ((fi) ? ((fi)->flags & (flag)) : 0) 732 #define FI_SET_FLAG(fi, flag) \ 735 (fi)->flags = (fi)->flags | (flag); \ 738 #define FI_RESET_FLAG(fi, flag) \ 741 (fi)->flags = (fi)->flags & ~(flag); \ 744 #define FI_GET_BITS_OFFSET(fi) (FI_GET_FLAG(fi, FI_BITS_OFFSET(7)) >> 5) 745 #define FI_GET_BITS_SIZE(fi) (FI_GET_FLAG(fi, FI_BITS_SIZE(63)) >> 8) 750 GHashTable *interesting_hfids;
752 gboolean fake_protocols;
781 #define PI_SEVERITY_MASK 0x00F00000 783 #define PI_COMMENT 0x00100000 785 #define PI_CHAT 0x00200000 787 #define PI_NOTE 0x00400000 789 #define PI_WARN 0x00600000 791 #define PI_ERROR 0x00800000 795 #define PI_GROUP_MASK 0xFF000000 797 #define PI_CHECKSUM 0x01000000 799 #define PI_SEQUENCE 0x02000000 801 #define PI_RESPONSE_CODE 0x03000000 803 #define PI_REQUEST_CODE 0x04000000 805 #define PI_UNDECODED 0x05000000 807 #define PI_REASSEMBLE 0x06000000 809 #define PI_MALFORMED 0x07000000 811 #define PI_DEBUG 0x08000000 813 #define PI_PROTOCOL 0x09000000 815 #define PI_SECURITY 0x0a000000 817 #define PI_COMMENTS_GROUP 0x0b000000 819 #define PI_DECRYPTION 0x0c000000 821 #define PI_ASSUMPTION 0x0d000000 823 #define PI_DEPRECATED 0x0e000000 830 #define PROTO_ITEM_IS_HIDDEN(proto_item) \ 831 ((proto_item) ? FI_GET_FLAG(PITEM_FINFO(proto_item), FI_HIDDEN) : 0) 834 #define PROTO_ITEM_SET_HIDDEN(proto_item) \ 837 FI_SET_FLAG(PITEM_FINFO(proto_item), FI_HIDDEN); \ 840 #define PROTO_ITEM_SET_VISIBLE(proto_item) \ 843 FI_RESET_FLAG(PITEM_FINFO(proto_item), FI_HIDDEN); \ 847 #define PROTO_ITEM_IS_GENERATED(proto_item) \ 848 ((proto_item) ? FI_GET_FLAG(PITEM_FINFO(proto_item), FI_GENERATED) : 0) 850 #define PROTO_ITEM_SET_GENERATED(proto_item) \ 853 FI_SET_FLAG(PITEM_FINFO(proto_item), FI_GENERATED); \ 856 #define PROTO_ITEM_IS_URL(proto_item) \ 857 ((proto_item) ? FI_GET_FLAG(PITEM_FINFO(proto_item), FI_URL) : 0) 859 #define PROTO_ITEM_SET_URL(proto_item) \ 862 FI_SET_FLAG(PITEM_FINFO(proto_item), FI_URL); \ 865 typedef void (*proto_tree_foreach_func)(
proto_node *, gpointer);
866 typedef gboolean (*proto_tree_traverse_func)(proto_node *, gpointer);
868 extern gboolean proto_tree_traverse_post_order(proto_tree *tree,
869 proto_tree_traverse_func func, gpointer data);
871 WS_DLL_PUBLIC
void proto_tree_children_foreach(proto_tree *tree,
872 proto_tree_foreach_func func, gpointer data);
875 #define PNODE_FINFO(proto_node) ((proto_node)->finfo) 878 #define PITEM_FINFO(proto_item) PNODE_FINFO(proto_item) 881 #define PTREE_FINFO(proto_tree) PNODE_FINFO(proto_tree) 884 #define PTREE_DATA(proto_tree) ((proto_tree)->tree_data) 887 #define PNODE_POOL(proto_node) ((proto_node)->tree_data->pinfo->pool) 891 void (*register_protoinfo)(void);
892 void (*register_handoff)(void);
896 WS_DLL_PUBLIC
void proto_register_plugin(
const proto_plugin *
plugin);
900 void proto_init(GSList *register_all_protocols_list, GSList *register_all_handoffs_list,
901 register_cb cb,
void *client_data);
926 WS_DLL_PUBLIC proto_tree*
proto_item_add_subtree(proto_item *ti,
const gint idx) G_GNUC_WARN_UNUSED_RESULT;
994 void proto_tree_reset(proto_tree *tree);
1007 WS_DLL_PUBLIC gboolean
1042 WS_DLL_PUBLIC
void proto_tree_move_item(proto_tree *tree, proto_item *fixed_item, proto_item *item_to_move);
1062 WS_DLL_PUBLIC proto_item *
1064 const gint start, gint length,
const guint encoding);
1066 WS_DLL_PUBLIC proto_item *
1067 proto_tree_add_item(proto_tree *tree,
int hfindex,
tvbuff_t *tvb,
1068 const gint start, gint length,
const guint encoding);
1082 WS_DLL_PUBLIC proto_item *
1084 const gint start, gint length,
const guint encoding, gint *lenretval);
1086 WS_DLL_PUBLIC proto_item *
1087 proto_tree_add_item_ret_length(proto_tree *tree,
int hfindex,
tvbuff_t *tvb,
1088 const gint start, gint length,
1089 const guint encoding, gint *lenretval);
1122 WS_DLL_PUBLIC proto_item *
1124 const gint start, gint length,
const guint encoding, gint32 *retval);
1126 WS_DLL_PUBLIC proto_item *
1127 proto_tree_add_item_ret_uint(proto_tree *tree,
int hfindex,
tvbuff_t *tvb,
1128 const gint start, gint length,
const guint encoding, guint32 *retval);
1130 WS_DLL_PUBLIC proto_item *
1131 proto_tree_add_item_ret_uint64(proto_tree *tree,
int hfindex,
tvbuff_t *tvb,
1132 const gint start, gint length,
const guint encoding, guint64 *retval);
1134 WS_DLL_PUBLIC proto_item *
1135 proto_tree_add_item_ret_varint(proto_tree *tree,
int hfindex,
tvbuff_t *tvb,
1136 const gint start, gint length,
const guint encoding, guint64 *retval, gint *lenretval);
1138 WS_DLL_PUBLIC proto_item *
1139 proto_tree_add_item_ret_boolean(proto_tree *tree,
int hfindex,
tvbuff_t *tvb,
1140 const gint start, gint length,
const guint encoding, gboolean *retval);
1171 WS_DLL_PUBLIC proto_item *
1173 tvbuff_t *tvb,
const gint start, gint length,
const guint encoding,
1203 WS_DLL_PUBLIC proto_item *
1205 const gint start, gint length,
const guint encoding,
1218 ...) G_GNUC_PRINTF(5,6);
1230 gint length,
const char *format, va_list ap)
1231 G_GNUC_PRINTF(5, 0);
1242 WS_DLL_PUBLIC proto_tree *
1255 WS_DLL_PUBLIC proto_tree *
1275 WS_DLL_PUBLIC proto_item *
1277 gint length,
const char *format, ...) G_GNUC_PRINTF(6,7);
1288 WS_DLL_PUBLIC proto_item *
1290 gint length,
const char *format, ...) G_GNUC_PRINTF(6,7);
1303 WS_DLL_PUBLIC proto_item *
1305 gint length,
const guint8* start_ptr);
1317 WS_DLL_PUBLIC proto_item *
1319 gint length,
const guint8 *start_ptr, gint ptr_length);
1354 WS_DLL_PUBLIC proto_item *
1356 const gint start, gint length,
const guint encoding,
1357 GByteArray *retval, gint *endoff, gint *err);
1371 WS_DLL_PUBLIC proto_item *
1373 gint start, gint length,
const guint8* start_ptr,
const char *format,
1374 ...) G_GNUC_PRINTF(7,8);
1387 WS_DLL_PUBLIC proto_item *
1389 gint length,
const guint8* start_ptr,
const char *format, ...) G_GNUC_PRINTF(7,8);
1399 WS_DLL_PUBLIC proto_item *
1401 gint length,
const nstime_t* value_ptr);
1433 WS_DLL_PUBLIC proto_item *
1435 const gint start, gint length,
const guint encoding,
1436 nstime_t *retval, gint *endoff, gint *err);
1451 WS_DLL_PUBLIC proto_item *
1453 gint start, gint length,
nstime_t* value_ptr,
const char *format, ...)
1468 WS_DLL_PUBLIC proto_item *
1470 gint length,
nstime_t* value_ptr,
const char *format, ...) G_GNUC_PRINTF(7,8);
1480 WS_DLL_PUBLIC proto_item *
1482 gint length, guint32 value);
1496 WS_DLL_PUBLIC proto_item *
1498 gint start, gint length, guint32 value,
const char *format, ...)
1512 WS_DLL_PUBLIC proto_item *
1514 gint length, guint32 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
1524 WS_DLL_PUBLIC proto_item *
1526 gint length, guint32 value);
1540 WS_DLL_PUBLIC proto_item *
1542 gint start, gint length, guint32 value,
const char *format, ...)
1556 WS_DLL_PUBLIC proto_item *
1558 gint length, guint32 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
1568 WS_DLL_PUBLIC proto_item *
1584 WS_DLL_PUBLIC proto_item *
1586 gint start, gint length,
const ws_in6_addr *value_ptr,
const char *format,
1587 ...) G_GNUC_PRINTF(7,8);
1600 WS_DLL_PUBLIC proto_item *
1602 gint length,
const ws_in6_addr *value_ptr,
const char *format, ...) G_GNUC_PRINTF(7,8);
1612 WS_DLL_PUBLIC proto_item *
1614 gint length,
const guint8* value);
1628 WS_DLL_PUBLIC proto_item *
1630 gint start, gint length,
const guint8* value,
const char *format, ...)
1644 WS_DLL_PUBLIC proto_item *
1646 gint length,
const guint8* value,
const char *format, ...) G_GNUC_PRINTF(7,8);
1656 WS_DLL_PUBLIC proto_item *
1658 gint length,
const e_guid_t *value_ptr);
1672 WS_DLL_PUBLIC proto_item *
1674 gint start, gint length,
const e_guid_t *value_ptr,
const char *format,
1675 ...) G_GNUC_PRINTF(7,8);
1688 WS_DLL_PUBLIC proto_item *
1690 gint length,
const e_guid_t *value_ptr,
const char *format, ...) G_GNUC_PRINTF(7,8);
1702 gint length,
const guint8* value_ptr);
1718 gint start, gint length,
const guint8* value_ptr,
const char *format,
1719 ...) G_GNUC_PRINTF(7,8);
1734 gint length,
const guint8* value_ptr,
const char *format, ...) G_GNUC_PRINTF(7,8);
1744 WS_DLL_PUBLIC proto_item *
1746 gint length,
const char* value);
1760 WS_DLL_PUBLIC proto_item *
1762 gint start, gint length,
const char* value,
const char *format, ...)
1777 WS_DLL_PUBLIC proto_item *
1779 gint length,
const char* value,
const char *format, ...) G_GNUC_PRINTF(7,8);
1789 WS_DLL_PUBLIC proto_item *
1791 gint length, guint32 value);
1805 WS_DLL_PUBLIC proto_item *
1807 tvbuff_t *tvb, gint start, gint length, guint32 value,
1808 const char *format, ...) G_GNUC_PRINTF(7,8);
1821 WS_DLL_PUBLIC proto_item *
1823 gint length, guint32 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
1833 WS_DLL_PUBLIC proto_item *
1835 gint length,
float value);
1849 WS_DLL_PUBLIC proto_item *
1851 gint start, gint length,
float value,
const char *format, ...)
1865 WS_DLL_PUBLIC proto_item *
1867 gint length,
float value,
const char *format, ...) G_GNUC_PRINTF(7,8);
1877 WS_DLL_PUBLIC proto_item *
1879 gint length,
double value);
1893 WS_DLL_PUBLIC proto_item *
1895 gint start, gint length,
double value,
const char *format, ...)
1909 WS_DLL_PUBLIC proto_item *
1911 gint length,
double value,
const char *format, ...) G_GNUC_PRINTF(7,8);
1921 WS_DLL_PUBLIC proto_item *
1923 gint length, guint32 value);
1937 WS_DLL_PUBLIC proto_item *
1939 gint start, gint length, guint32 value,
const char *format, ...)
1954 WS_DLL_PUBLIC proto_item *
1956 gint length, guint32 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
1966 WS_DLL_PUBLIC proto_item *
1968 gint length, guint64 value);
1982 WS_DLL_PUBLIC proto_item *
1984 gint start, gint length, guint64 value,
const char *format, ...)
1998 WS_DLL_PUBLIC proto_item *
2000 gint length, guint64 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
2010 WS_DLL_PUBLIC proto_item *
2012 gint length, gint32 value);
2026 WS_DLL_PUBLIC proto_item *
2028 gint start, gint length, gint32 value,
const char *format, ...)
2043 WS_DLL_PUBLIC proto_item *
2045 gint length, gint32 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
2055 WS_DLL_PUBLIC proto_item *
2057 gint length, gint64 value);
2071 WS_DLL_PUBLIC proto_item *
2073 gint start, gint length, gint64 value,
const char *format, ...)
2087 WS_DLL_PUBLIC proto_item *
2089 gint length, gint64 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
2099 WS_DLL_PUBLIC proto_item *
2101 gint length,
const guint64 value);
2115 WS_DLL_PUBLIC proto_item *
2117 gint start, gint length,
const guint64 value,
const char *format, ...)
2131 WS_DLL_PUBLIC proto_item *
2133 gint length,
const guint64 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
2142 WS_DLL_PUBLIC proto_item *
2144 ...) G_GNUC_PRINTF(2,3);
2205 WS_DLL_PUBLIC
void proto_register_fields_manual(
const int parent,
header_field_info **hfi,
const int num_records);
2206 WS_DLL_PUBLIC
void proto_register_fields_section(
const int parent,
header_field_info *hfi,
const int num_records);
2286 WS_DLL_PUBLIC
int proto_get_data_protocol(
void *cookie);
2287 WS_DLL_PUBLIC
int proto_get_next_protocol(
void **cookie);
2288 WS_DLL_PUBLIC
header_field_info *proto_get_first_protocol_field(
const int proto_id,
void **cookie);
2289 WS_DLL_PUBLIC
header_field_info *proto_get_next_protocol_field(
const int proto_id,
void **cookie);
2382 gboolean *is_ip, gboolean *is_tcp, gboolean *is_udp, gboolean *is_sctp,
2383 gboolean *is_ssl, gboolean *is_rtp, gboolean *is_lte_rlc);
2434 WS_DLL_PUBLIC GPtrArray*
proto_find_finfo(proto_tree *tree,
const int hfindex);
2456 #ifdef HAVE_JSONGLIB 2458 WS_DLL_PUBLIC
void proto_registrar_dump_elastic(
const gchar* filter);
2487 #ifndef g_ptr_array_len 2488 #define g_ptr_array_len(a) ((a)?(a)->len:0) 2500 WS_DLL_PUBLIC gboolean
2522 WS_DLL_PUBLIC gchar*
2544 WS_DLL_PUBLIC proto_item *
2546 const int hf_hdr,
const gint ett,
const int **fields,
const guint encoding);
2571 WS_DLL_PUBLIC proto_item *
2573 const int hf_hdr,
const gint ett,
const int **fields,
2574 const guint encoding, guint64 *retval);
2599 WS_DLL_PUBLIC proto_item *
2601 const int hf_hdr,
const gint ett,
const int **fields,
const guint encoding,
const int flags);
2630 WS_DLL_PUBLIC proto_item *
2632 const int hf_hdr,
const gint ett,
const int **fields,
2633 const guint encoding,
const int flags, guint64 *retval);
2654 WS_DLL_PUBLIC proto_item *
2656 const int hf_hdr,
const gint ett,
const int **fields,
const guint64 value);
2681 WS_DLL_PUBLIC proto_item *
2683 const int hf_hdr,
const gint ett,
const int **fields,
const guint64 value,
const int flags);
2702 const int len,
const int **fields,
const guint encoding);
2720 const int len,
const int **fields,
const guint64 value);
2744 WS_DLL_PUBLIC proto_item *
2746 const int hf_hdr,
const gint ett,
const int **fields,
struct expert_field* exp,
const guint encoding);
2760 WS_DLL_PUBLIC proto_item *
2762 const char *name,
const char *fallback,
2763 const gint ett,
const int **fields,
const guint encoding,
const int flags);
2765 #define BMT_NO_FLAGS 0x00 2766 #define BMT_NO_APPEND 0x01 2767 #define BMT_NO_INT 0x02 2768 #define BMT_NO_FALSE 0x04 2769 #define BMT_NO_TFS 0x08 2780 WS_DLL_PUBLIC proto_item * 2798 WS_DLL_PUBLIC proto_item *
2800 const guint bit_offset,
const crumb_spec_t *crumb_spec,
2801 guint64 *return_value);
2831 WS_DLL_PUBLIC proto_item *
2832 proto_tree_add_bits_ret_val(proto_tree *tree,
const int hf_index,
tvbuff_t *tvb,
const guint bit_offset,
const gint no_of_bits, guint64 *return_value,
const guint encoding);
2845 WS_DLL_PUBLIC proto_item *
2847 guint32 value,
const char *format, ...) G_GNUC_PRINTF(7,8);
2860 WS_DLL_PUBLIC proto_item *
2862 guint64 value, const
char *format, ...) G_GNUC_PRINTF(7,8);
2878 guint32 value, const
char *format, ...) G_GNUC_PRINTF(7,8);
2894 guint64 value, const
char *format, ...) G_GNUC_PRINTF(7,8);
2910 gint32 value, const
char *format, ...) G_GNUC_PRINTF(7,8);
2926 gint64 value, const
char *format, ...) G_GNUC_PRINTF(7,8);
2942 float value, const
char *format, ...) G_GNUC_PRINTF(7,8);
2952 WS_DLL_PUBLIC proto_item *
2954 const guint bit_offset, const gint no_of_chars);
2963 WS_DLL_PUBLIC proto_item *
2965 const guint bit_offset, const gint no_of_chars);
2984 WS_DLL_PUBLIC proto_item *
2986 const
int hf_checksum, const
int hf_checksum_status, struct
expert_field* bad_checksum_expert,
2987 packet_info *pinfo, guint32 computed_checksum, const guint encoding, const guint flags);
2991 PROTO_CHECKSUM_E_BAD = 0,
2992 PROTO_CHECKSUM_E_GOOD,
2993 PROTO_CHECKSUM_E_UNVERIFIED,
2994 PROTO_CHECKSUM_E_NOT_PRESENT
2996 } proto_checksum_enum_e;
2998 #define PROTO_CHECKSUM_NO_FLAGS 0x00 2999 #define PROTO_CHECKSUM_VERIFY 0x01 3000 #define PROTO_CHECKSUM_GENERATED 0x02 3001 #define PROTO_CHECKSUM_IN_CKSUM 0x04 3002 #define PROTO_CHECKSUM_ZERO 0x08 3003 #define PROTO_CHECKSUM_NOT_PRESENT 0x10 3005 WS_DLL_PUBLIC const value_string proto_checksum_vals[]; 3011 WS_DLL_PUBLIC guchar
3026 gchar *expr,
const int size );
3030 #ifdef HAVE_HFI_SECTION_INIT 3031 #define HFI_INIT(proto) __attribute__((section( "_data_" G_STRINGIFY(proto)))) __attribute__((aligned(sizeof(void *)))) 3033 #define proto_register_fields(proto, hfi, count) \ 3035 extern header_field_info __start__data_ ##proto[]; \ 3036 extern header_field_info __stop__data_ ##proto[]; \ 3038 proto_register_fields_section(proto, __start__data_ ##proto, (int) (__stop__data_ ##proto - __start__data_ ##proto)); \ 3041 #define HFI_INIT(proto) 3042 #define proto_register_fields(proto, hfi, count) \ 3043 proto_register_fields_manual(proto, hfi, count) 3046 #ifdef NEW_PROTO_TREE_API 3047 #define proto_tree_add_item(tree, hfinfo, tvb, start, length, encoding) \ 3048 proto_tree_add_item_new(tree, hfinfo, tvb, start, length, encoding) 3050 #define proto_tree_add_item_ret_length(tree, hfinfo, tvb, start, length, encoding, retval) \ 3051 proto_tree_add_item_new_ret_length(tree, hfinfo, tvb, start, length, encoding, retval) 3053 #define proto_tree_add_boolean(tree, hfinfo, tvb, start, length, value) \ 3054 proto_tree_add_boolean(tree, (hfinfo)->id, tvb, start, length, value) 3056 #define proto_tree_add_string(tree, hfinfo, tvb, start, length, value) \ 3057 proto_tree_add_string(tree, (hfinfo)->id, tvb, start, length, value) 3059 #define proto_tree_add_time(tree, hfinfo, tvb, start, length, value) \ 3060 proto_tree_add_time(tree, (hfinfo)->id, tvb, start, length, value) 3062 #define proto_tree_add_int(tree, hfinfo, tvb, start, length, value) \ 3063 proto_tree_add_int(tree, (hfinfo)->id, tvb, start, length, value) 3065 #define proto_tree_add_uint(tree, hfinfo, tvb, start, length, value) \ 3066 proto_tree_add_uint(tree, (hfinfo)->id, tvb, start, length, value) 3068 #define proto_tree_add_float(tree, hfinfo, tvb, start, length, value) \ 3069 proto_tree_add_float(tree, (hfinfo)->id, tvb, start, length, value) 3071 #define proto_tree_add_float_format_value(tree, hfinfo, \ 3072 tvb, start, length, value, format, ...) \ 3073 proto_tree_add_float_format_value(tree, (hfinfo)->id, \ 3074 tvb, start, length, value, format, __VA_ARGS__) WS_DLL_PUBLIC proto_item * proto_tree_add_ether_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC gboolean proto_tracking_interesting_fields(const proto_tree *tree)
Definition: proto.c:9455
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_protocol_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const char *format,...) G_GNUC_PRINTF(6
WS_DLL_PUBLIC void proto_heuristic_dissector_foreach(const protocol_t *protocol, GFunc func, gpointer user_data)
Definition: proto.c:6815
WS_DLL_PUBLIC proto_item * proto_tree_add_bytes_with_length(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *start_ptr, gint ptr_length)
Definition: proto.c:3564
void proto_tree_set_fake_protocols(proto_tree *tree, gboolean fake_protocols)
Definition: proto.c:782
WS_DLL_PUBLIC int proto_registrar_get_id_byname(const char *field_name)
Definition: proto.c:947
Definition: inet_ipv6.h:20
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_int(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, gint32 value)
Definition: proto.c:4786
struct hf_register_info hf_register_info
proto_item proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_string(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const char *value)
Definition: proto.c:4131
WS_DLL_PUBLIC void proto_add_deregistered_data(void *data)
Definition: proto.c:7112
WS_DLL_PUBLIC proto_item * proto_tree_add_bitmask(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int hf_hdr, const gint ett, const int **fields, const guint encoding)
Definition: proto.c:10974
WS_DLL_PUBLIC const char * proto_get_protocol_short_name(const protocol_t *protocol)
Definition: proto.c:6775
WS_DLL_PUBLIC proto_item * proto_tree_add_bitmask_len(proto_tree *tree, tvbuff_t *tvb, const guint offset, const guint len, const int hf_hdr, const gint ett, const int **fields, struct expert_field *exp, const guint encoding)
Definition: proto.c:11118
WS_DLL_PUBLIC void proto_register_subtree_array(gint *const *indices, const int num_indices)
Definition: proto.c:7930
WS_DLL_PUBLIC void proto_register_field_array(const int parent, hf_register_info *hf, const int num_records)
Definition: proto.c:6993
WS_DLL_PUBLIC guchar proto_check_field_name(const gchar *field_name)
Definition: proto.c:12052
void proto_tree_prime_with_hfid(proto_tree *tree, const int hfid)
WS_DLL_PUBLIC proto_item * proto_tree_add_uint_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC protocol_t * find_protocol_by_id(const int proto_id)
Definition: proto.c:6704
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_boolean_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value, const char *format,...) G_GNUC_PRINTF(7
void(* prefix_initializer_t)(const char *match)
Definition: proto.h:2191
WS_DLL_PUBLIC proto_item * proto_tree_add_bitmask_with_flags_ret_uint64(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int hf_hdr, const gint ett, const int **fields, const guint encoding, const int flags, guint64 *retval)
Definition: proto.c:10986
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_int64(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, gint64 value)
Definition: proto.c:4878
WS_DLL_PUBLIC GPtrArray * proto_find_finfo(proto_tree *tree, const int hfindex)
Definition: proto.c:9513
WS_DLL_PUBLIC proto_item * proto_tree_add_ipv6_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const ws_in6_addr *value_ptr, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_double_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, double value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_uint64(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint64 value)
Definition: proto.c:4697
Definition: packet_info.h:44
WS_DLL_PUBLIC void WS_DLL_PUBLIC void WS_DLL_PUBLIC void proto_item_prepend_text(proto_item *ti, const char *format,...) G_GNUC_PRINTF(2
WS_DLL_PUBLIC const char * proto_registrar_get_abbrev(const int n)
Definition: proto.c:9373
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_uint(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value)
Definition: proto.c:4607
WS_DLL_PUBLIC void proto_registrar_dump_protocols(void)
Definition: proto.c:9666
WS_DLL_PUBLIC proto_item * proto_item_get_parent_nth(proto_item *ti, int gen)
Definition: proto.c:6322
struct _item_label_t item_label_t
WS_DLL_PUBLIC proto_item * proto_tree_add_none_format(proto_tree *tree, const int hfindex, tvbuff_t *tvb, const gint start, gint length, const char *format,...) G_GNUC_PRINTF(6
proto_item * proto_tree_add_oid_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *value_ptr, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC int proto_item_get_len(const proto_item *ti)
Definition: proto.c:6216
WS_DLL_PUBLIC void proto_register_prefix(const char *prefix, prefix_initializer_t initializer)
Definition: proto.c:877
WS_DLL_PUBLIC gboolean tree_expanded(int tree_type)
Definition: proto.c:12074
WS_DLL_PUBLIC proto_item * proto_tree_add_bitmask_ret_uint64(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int hf_hdr, const gint ett, const int **fields, const guint encoding, guint64 *retval)
Definition: proto.c:10948
WS_DLL_PUBLIC GPtrArray * proto_get_finfo_ptr_array(const proto_tree *tree, const int hfindex)
Definition: proto.c:9442
WS_DLL_PUBLIC proto_item * proto_item_get_parent(const proto_item *ti)
Definition: proto.c:6315
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ipv6_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const ws_in6_addr *value_ptr, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item * proto_tree_add_uint64_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item * proto_tree_add_ipxnet_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item * proto_tree_add_guid_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const e_guid_t *value_ptr, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC void proto_get_frame_protocols(const wmem_list_t *layers, gboolean *is_ip, gboolean *is_tcp, gboolean *is_udp, gboolean *is_sctp, gboolean *is_ssl, gboolean *is_rtp, gboolean *is_lte_rlc)
Definition: proto.c:6824
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_bytes(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *start_ptr)
Definition: proto.c:3539
WS_DLL_PUBLIC proto_tree * proto_tree_add_subtree_format(proto_tree *tree, tvbuff_t *tvb, gint start, gint length, gint idx, proto_item **tree_item, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ipxnet(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value)
Definition: proto.c:3734
WS_DLL_PUBLIC proto_item * proto_tree_add_float_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, float value, const char *format,...) G_GNUC_PRINTF(7
proto_item proto_item * proto_tree_add_text_valist_internal(proto_tree *tree, tvbuff_t *tvb, gint start, gint length, const char *format, va_list ap) G_GNUC_PRINTF(5
WS_DLL_PUBLIC int proto_get_id_by_filter_name(const gchar *filter_name)
Definition: proto.c:6735
WS_DLL_PUBLIC void proto_free_deregistered_fields(void)
Definition: proto.c:7218
WS_DLL_PUBLIC gboolean proto_is_frame_protocol(const wmem_list_t *layers, const char *proto_name)
Definition: proto.c:6864
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_debug_text(proto_tree *tree, const char *format,...) G_GNUC_PRINTF(2
#define ITEM_LABEL_LENGTH
Definition: proto.h:63
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ipv4(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value)
Definition: proto.c:3799
WS_DLL_PUBLIC proto_item * proto_tree_add_int_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, gint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item * proto_tree_add_item_ret_string_and_length(proto_tree *tree, int hfindex, tvbuff_t *tvb, const gint start, gint length, const guint encoding, wmem_allocator_t *scope, const guint8 **retval, gint *lenretval)
Definition: proto.c:3058
WS_DLL_PUBLIC header_field_info * proto_registrar_get_byname(const char *field_name)
Definition: proto.c:905
WS_DLL_PUBLIC proto_item * proto_tree_add_split_bits_item_ret_val(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const crumb_spec_t *crumb_spec, guint64 *return_value)
Definition: proto.c:11354
Definition: tvbuff-int.h:35
gboolean proto_check_for_protocol_or_field(const proto_tree *tree, const int id)
Definition: proto.c:9424
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC void proto_item_fill_label(field_info *fi, gchar *label_str)
Definition: proto.c:8066
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_uint64_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC gboolean proto_field_is_referenced(proto_tree *tree, int proto_id)
Definition: proto.c:795
WS_DLL_PUBLIC proto_item * proto_tree_add_item_new_ret_length(proto_tree *tree, header_field_info *hfinfo, tvbuff_t *tvb, const gint start, gint length, const guint encoding, gint *lenretval)
Definition: proto.c:3185
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item proto_item proto_item proto_item proto_item proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ts_23_038_7bits_item(proto_tree *tree, const int hfindex, tvbuff_t *tvb, const guint bit_offset, const gint no_of_chars)
Definition: proto.c:11883
WS_DLL_PUBLIC void proto_tree_add_bitmask_list(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int len, const int **fields, const guint encoding)
Definition: proto.c:11083
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ether(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *value)
Definition: proto.c:4232
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_string_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const char *value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC gboolean proto_tree_set_visible(proto_tree *tree, gboolean visible)
Definition: proto.c:772
WS_DLL_PUBLIC proto_item * proto_tree_add_boolean_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_uint64_bits_format_value(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, guint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ipv6(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const ws_in6_addr *value_ptr)
Definition: proto.c:3864
WS_DLL_PUBLIC proto_item * proto_tree_add_bits_item(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, const guint encoding)
Definition: proto.c:11193
WS_DLL_PUBLIC void WS_DLL_PUBLIC void proto_item_append_text(proto_item *ti, const char *format,...) G_GNUC_PRINTF(2
WS_DLL_PUBLIC void proto_tree_set_appendix(proto_tree *tree, tvbuff_t *tvb, gint start, const gint length)
Definition: proto.c:6416
WS_DLL_PUBLIC proto_item * proto_tree_add_bitmask_with_flags(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int hf_hdr, const gint ett, const int **fields, const guint encoding, const int flags)
Definition: proto.c:11021
WS_DLL_PUBLIC void proto_reenable_all(void)
Definition: proto.c:6955
WS_DLL_PUBLIC void WS_DLL_PUBLIC void WS_DLL_PUBLIC void WS_DLL_PUBLIC void proto_item_set_len(proto_item *ti, const gint length)
Definition: proto.c:6176
WS_DLL_PUBLIC proto_item * proto_tree_get_parent(proto_tree *tree)
Definition: proto.c:6335
proto_node proto_item
Definition: proto.h:771
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item proto_item proto_item proto_item * proto_tree_add_int_bits_format_value(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, gint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_tree * proto_tree_get_root(proto_tree *tree)
Definition: proto.c:6355
const gchar * proto_custom_set(proto_tree *tree, GSList *field_id, gint occurrence, gchar *result, gchar *expr, const int size)
Definition: proto.c:5582
WS_DLL_PUBLIC gchar * proto_find_undecoded_data(proto_tree *tree, guint length)
Definition: proto.c:9645
Definition: guid-utils.h:21
WS_DLL_PUBLIC proto_item * proto_tree_add_ipv4_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_double(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, double value)
Definition: proto.c:4542
WS_DLL_PUBLIC gboolean proto_can_match_selected(field_info *finfo, struct epan_dissect *edt)
Definition: proto.c:10607
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item proto_item proto_item * proto_tree_add_boolean_bits_format_value64(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, guint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_uint_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC gboolean proto_can_toggle_protocol(const int proto_id)
Definition: proto.c:6919
WS_DLL_PUBLIC void proto_registrar_dump_ftypes(void)
Definition: proto.c:10336
WS_DLL_PUBLIC proto_item * proto_tree_add_time_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, nstime_t *value_ptr, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC void proto_item_set_end(proto_item *ti, tvbuff_t *tvb, gint end)
Definition: proto.c:6197
WS_DLL_PUBLIC const char * proto_field_display_to_string(int field_display)
Definition: proto.c:7287
WS_DLL_PUBLIC WS_NORETURN void proto_report_dissector_bug(const char *format,...) G_GNUC_PRINTF(1
WS_DLL_PUBLIC proto_item * proto_tree_add_double_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, double value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item * proto_tree_add_item_new(proto_tree *tree, header_field_info *hfinfo, tvbuff_t *tvb, const gint start, gint length, const guint encoding)
Definition: proto.c:3150
WS_DLL_PUBLIC void proto_item_set_text(proto_item *ti, const char *format,...) G_GNUC_PRINTF(2
WS_DLL_PUBLIC proto_tree * proto_item_add_subtree(proto_item *ti, const gint idx) G_GNUC_WARN_UNUSED_RESULT
Definition: proto.c:6285
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_time_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, nstime_t *value_ptr, const char *format,...) G_GNUC_PRINTF(7
proto_item proto_item * proto_tree_add_oid_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *value_ptr, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ether_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_int_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, gint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item * proto_tree_add_item_ret_string(proto_tree *tree, int hfindex, tvbuff_t *tvb, const gint start, gint length, const guint encoding, wmem_allocator_t *scope, const guint8 **retval)
Definition: proto.c:3107
WS_DLL_PUBLIC GPtrArray * proto_all_finfos(proto_tree *tree)
Definition: proto.c:9559
proto_item * proto_tree_add_text_internal(proto_tree *tree, tvbuff_t *tvb, gint start, gint length, const char *format,...) G_GNUC_PRINTF(5
WS_DLL_PUBLIC void proto_deregister_field(const int parent, gint hf_id)
Definition: proto.c:7082
proto_node proto_tree
Definition: proto.h:769
WS_DLL_PUBLIC void proto_set_decoding(const int proto_id, const gboolean enabled)
Definition: proto.c:6944
proto_item * proto_tree_add_format_wsp_text(proto_tree *tree, tvbuff_t *tvb, gint start, gint length)
Definition: proto.c:1296
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_eui64_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC const char * proto_get_protocol_long_name(const protocol_t *protocol)
Definition: proto.c:6783
WS_DLL_PUBLIC void proto_tree_move_item(proto_tree *tree, proto_item *fixed_item, proto_item *item_to_move)
Definition: proto.c:6365
WS_DLL_PUBLIC void proto_initialize_all_prefixes(void)
Definition: proto.c:894
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ipv4_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value, const char *format,...) G_GNUC_PRINTF(7
Definition: wmem_allocator.h:26
WS_DLL_PUBLIC gboolean proto_registrar_dump_fieldcount(void)
Definition: proto.c:9921
WS_DLL_PUBLIC field_info * proto_find_field_from_offset(proto_tree *tree, guint offset, tvbuff_t *tvb)
Definition: proto.c:9606
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_time(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const nstime_t *value_ptr)
Definition: proto.c:3667
WS_DLL_PUBLIC proto_tree * proto_tree_get_parent_tree(proto_tree *tree)
Definition: proto.c:6342
WS_DLL_PUBLIC const char * proto_get_protocol_filter_name(const int proto_id)
Definition: proto.c:6791
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_int64_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, gint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_boolean(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value)
Definition: proto.c:4303
WS_DLL_PUBLIC proto_item * proto_tree_add_bitmask_value_with_flags(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int hf_hdr, const gint ett, const int **fields, const guint64 value, const int flags)
Definition: proto.c:11055
gint proto_registrar_get_length(const int n)
Definition: proto.c:9413
WS_DLL_PUBLIC int hf_text_only
Definition: proto.h:60
WS_DLL_PUBLIC proto_item * proto_tree_add_ascii_7bits_item(proto_tree *tree, const int hfindex, tvbuff_t *tvb, const guint bit_offset, const gint no_of_chars)
Definition: proto.c:11915
WS_DLL_PUBLIC proto_item * proto_tree_add_checksum(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int hf_checksum, const int hf_checksum_status, struct expert_field *bad_checksum_expert, packet_info *pinfo, guint32 computed_checksum, const guint encoding, const guint flags)
Definition: proto.c:11956
WS_DLL_PUBLIC proto_item * proto_tree_add_bitmask_value(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int hf_hdr, const gint ett, const int **fields, const guint64 value)
Definition: proto.c:11046
WS_DLL_PUBLIC proto_item * proto_tree_add_bits_ret_val(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, guint64 *return_value, const guint encoding)
Definition: proto.c:11547
WS_DLL_PUBLIC proto_tree proto_item * proto_tree_add_format_text(proto_tree *tree, tvbuff_t *tvb, gint start, gint length)
Definition: proto.c:1277
WS_DLL_PUBLIC void proto_set_cant_toggle(const int proto_id)
Definition: proto.c:6972
struct _proto_node proto_node
void proto_add_heuristic_dissector(protocol_t *protocol, const char *short_name)
Definition: proto.c:6801
WS_DLL_PUBLIC int proto_get_id(const protocol_t *protocol)
Definition: proto.c:6719
WS_DLL_PUBLIC enum ftenum proto_registrar_get_ftype(const int n)
Definition: proto.c:9382
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_float_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, float value, const char *format,...) G_GNUC_PRINTF(7
proto_tree * proto_tree_create_root(struct _packet_info *pinfo)
Definition: proto.c:6223
WS_DLL_PUBLIC GPtrArray * proto_find_first_finfo(proto_tree *tree, const int hfindex)
Definition: proto.c:9532
WS_DLL_PUBLIC proto_item * proto_tree_add_bytes_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *start_ptr, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC gboolean proto_registrar_is_protocol(const int n)
Definition: proto.c:9400
WS_DLL_PUBLIC void proto_tree_free(proto_tree *tree)
Definition: proto.c:746
Definition: epan_dissect.h:28
WS_DLL_PUBLIC proto_item * proto_tree_add_time_item(proto_tree *tree, int hfindex, tvbuff_t *tvb, const gint start, gint length, const guint encoding, nstime_t *retval, gint *endoff, gint *err)
Definition: proto.c:3373
WS_DLL_PUBLIC int num_tree_types
Definition: proto.h:2479
WS_DLL_PUBLIC int proto_get_first_protocol(void **cookie)
Definition: proto.c:6635
WS_DLL_PUBLIC const char * proto_registrar_get_name(const int n)
Definition: proto.c:9364
WS_DLL_PUBLIC gboolean proto_is_pino(const protocol_t *protocol)
Definition: proto.c:6890
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_ipxnet_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, guint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item proto_item proto_item proto_item proto_item * proto_tree_add_int64_bits_format_value(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, gint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC const char * proto_get_protocol_name(const int proto_id)
Definition: proto.c:6763
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_guid(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const e_guid_t *value_ptr)
Definition: proto.c:3952
void proto_init(GSList *register_all_protocols_list, GSList *register_all_handoffs_list, register_cb cb, void *client_data)
WS_DLL_PUBLIC proto_item * proto_tree_add_uint_bits_format_value(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, guint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item * proto_tree_add_string_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const char *value, const char *format,...) G_GNUC_PRINTF(7
gboolean proto_deregister_protocol(const char *short_name)
Definition: proto.c:6588
WS_DLL_PUBLIC void proto_tree_add_bitmask_list_value(proto_tree *tree, tvbuff_t *tvb, const guint offset, const int len, const int **fields, const guint64 value)
Definition: proto.c:11096
WS_DLL_PUBLIC int proto_get_id_by_short_name(const gchar *short_name)
Definition: proto.c:6749
Definition: wmem_list.c:23
WS_DLL_PUBLIC proto_item * proto_tree_add_eui64_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC char * proto_construct_match_selected_string(field_info *finfo, struct epan_dissect *edt)
Definition: proto.c:10619
struct field_info field_info
WS_DLL_PUBLIC gboolean proto_is_protocol_enabled(const protocol_t *protocol)
Definition: proto.c:6896
WS_DLL_PUBLIC proto_item * proto_tree_add_bitmask_text(proto_tree *tree, tvbuff_t *tvb, const guint offset, const guint len, const char *name, const char *fallback, const gint ett, const int **fields, const guint encoding, const int flags)
Definition: proto.c:11170
field_display_e
Definition: proto.h:550
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_eui64(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint64 value)
Definition: proto.c:4970
WS_DLL_PUBLIC gboolean proto_is_protocol_enabled_by_default(const protocol_t *protocol)
Definition: proto.c:6909
WS_DLL_PUBLIC proto_item * proto_tree_add_int64_format_value(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, gint64 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC void proto_disable_by_default(const int proto_id)
Definition: proto.c:6932
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_float(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, float value)
Definition: proto.c:4477
WS_DLL_PUBLIC int proto_register_protocol_in_name_only(const char *name, const char *short_name, const char *filter_name, int parent_proto, enum ftenum field_type)
Definition: proto.c:6529
WS_DLL_PUBLIC int proto_registrar_get_parent(const int n)
Definition: proto.c:9391
WS_DLL_PUBLIC void proto_registrar_dump_fields(void)
Definition: proto.c:10220
WS_DLL_PUBLIC proto_tree * proto_item_get_subtree(proto_item *ti)
Definition: proto.c:6303
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item proto_item * proto_tree_add_oid(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *value_ptr)
Definition: proto.c:4029
void proto_tree_add_split_bits_crumb(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const crumb_spec_t *crumb_spec, guint16 crumb_index)
Definition: proto.c:11527
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_bytes_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const guint8 *start_ptr, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item proto_item proto_item proto_item proto_item proto_item * proto_tree_add_float_bits_format_value(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, float value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC void tree_expanded_set(int tree_type, gboolean value)
Definition: proto.c:12084
proto_item proto_item WS_DLL_PUBLIC proto_tree * proto_tree_add_subtree(proto_tree *tree, tvbuff_t *tvb, gint start, gint length, gint idx, proto_item **tree_item, const char *text)
Definition: proto.c:1226
WS_DLL_PUBLIC proto_item * proto_tree_add_item_ret_int(proto_tree *tree, int hfindex, tvbuff_t *tvb, const gint start, gint length, const guint encoding, gint32 *retval)
Definition: proto.c:2544
WS_DLL_PUBLIC header_field_info * proto_registrar_get_nth(guint hfindex)
Definition: proto.c:819
WS_DLL_PUBLIC int proto_register_protocol(const char *name, const char *short_name, const char *filter_name)
Definition: proto.c:6459
void proto_cleanup(void)
Definition: proto.c:606
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item * proto_tree_add_guid_format(proto_tree *tree, int hfindex, tvbuff_t *tvb, gint start, gint length, const e_guid_t *value_ptr, const char *format,...) G_GNUC_PRINTF(7
hf_ref_type
Definition: proto.h:612
WS_DLL_PUBLIC void proto_registrar_dump_values(void)
Definition: proto.c:9724
WS_DLL_PUBLIC proto_item WS_DLL_PUBLIC proto_item proto_item * proto_tree_add_boolean_bits_format_value(proto_tree *tree, const int hf_index, tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, guint32 value, const char *format,...) G_GNUC_PRINTF(7
WS_DLL_PUBLIC int proto_name_already_registered(const gchar *name)
Definition: proto.c:6725
WS_DLL_PUBLIC proto_item * proto_tree_add_bytes_item(proto_tree *tree, int hfindex, tvbuff_t *tvb, const gint start, gint length, const guint encoding, GByteArray *retval, gint *endoff, gint *err)
Definition: proto.c:3253