Wireshark 4.7.3
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
proto_data.h
Go to the documentation of this file.
1/* proto_data.h
2 * Definitions for protocol-specific data
3 *
4 * Wireshark - Network traffic analyzer
5 * By Gerald Combs <[email protected]>
6 * Copyright 1998 Gerald Combs
7 *
8 * SPDX-License-Identifier: GPL-2.0-or-later
9 */
10#pragma once
11#include "ws_symbol_export.h"
12
13#ifdef __cplusplus
14extern "C" {
15#endif /* __cplusplus */
16
20
25
26/* Allocator should be either pinfo->pool or wmem_file_scope() */
27
43WS_DLL_PUBLIC void p_add_proto_data(wmem_allocator_t *scope, struct _packet_info* pinfo, int proto, uint32_t key, void *proto_data);
44
61WS_DLL_PUBLIC void p_set_proto_data(wmem_allocator_t *scope, struct _packet_info* pinfo, int proto, uint32_t key, void *proto_data);
62
74WS_DLL_PUBLIC void *p_get_proto_data(wmem_allocator_t *scope, struct _packet_info* pinfo, int proto, uint32_t key);
75
84WS_DLL_PUBLIC void p_remove_proto_data(wmem_allocator_t *scope, struct _packet_info* pinfo, int proto, uint32_t key);
85
98GPtrArray *p_get_proto_names_and_keys(wmem_allocator_t *scope, struct _packet_info* pinfo);
99
107WS_DLL_PUBLIC void p_set_proto_depth(struct _packet_info* pinfo, int proto, unsigned depth);
108
115WS_DLL_PUBLIC unsigned p_get_proto_depth(struct _packet_info* pinfo, int proto);
116
118
119#ifdef __cplusplus
120}
121#endif /* __cplusplus */
122
123/*
124 * Editor modelines - https://www.wireshark.org/tools/modelines.html
125 *
126 * Local variables:
127 * c-basic-offset: 2
128 * tab-width: 8
129 * indent-tabs-mode: nil
130 * End:
131 *
132 * vi: set shiftwidth=2 tabstop=8 expandtab:
133 * :indentSize=2:tabSize=8:noTabs=true:
134 */
WS_DLL_PUBLIC void p_add_proto_data(wmem_allocator_t *scope, struct _packet_info *pinfo, int proto, uint32_t key, void *proto_data)
Definition proto_data.c:50
WS_DLL_PUBLIC void p_remove_proto_data(wmem_allocator_t *scope, struct _packet_info *pinfo, int proto, uint32_t key)
Definition proto_data.c:142
WS_DLL_PUBLIC void * p_get_proto_data(wmem_allocator_t *scope, struct _packet_info *pinfo, int proto, uint32_t key)
Definition proto_data.c:110
WS_DLL_PUBLIC void p_set_proto_depth(struct _packet_info *pinfo, int proto, unsigned depth)
Definition proto_data.c:199
WS_DLL_PUBLIC void p_set_proto_data(wmem_allocator_t *scope, struct _packet_info *pinfo, int proto, uint32_t key, void *proto_data)
Definition proto_data.c:78
WS_DLL_PUBLIC unsigned p_get_proto_depth(struct _packet_info *pinfo, int proto)
Definition proto_data.c:203
GPtrArray * p_get_proto_names_and_keys(wmem_allocator_t *scope, struct _packet_info *pinfo)
Definition proto_data.c:170
struct _wmem_allocator_t wmem_allocator_t
Definition wmem_core.h:44
Represents the metadata and indexing information for a single captured frame.
Definition packet_info.h:43