![]() |
Wireshark
4.3.0
The Wireshark network protocol analyzer
|
#include <glib.h>
#include <epan/guid-utils.h>
#include <epan/wmem_scopes.h>
#include <wsutil/inet_cidr.h>
#include <wsutil/nstime.h>
#include "wsutil/ws_mempbrk.h"
Go to the source code of this file.
Classes | |
struct | dgt_set_t |
Macros | |
#define | tvb_get_h_guint16 tvb_get_letohs |
#define | tvb_get_h_guint32 tvb_get_letohl |
Typedefs | |
typedef struct tvbuff | tvbuff_t |
typedef void(* | tvbuff_free_cb_t) (void *) |
typedef struct dgt_set_t | dgt_set_t |
Functions | |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_octet_aligned (tvbuff_t *tvb, guint32 bit_offset, gint32 no_of_bits) |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_octet_right_aligned (tvbuff_t *tvb, guint32 bit_offset, gint32 no_of_bits) |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_chain (tvbuff_t *parent, tvbuff_t *backing) |
WS_DLL_PUBLIC tvbuff_t * | tvb_clone (tvbuff_t *tvb) |
WS_DLL_PUBLIC tvbuff_t * | tvb_clone_offset_len (tvbuff_t *tvb, guint offset, guint len) |
WS_DLL_PUBLIC void | tvb_free (tvbuff_t *tvb) |
WS_DLL_PUBLIC void | tvb_free_chain (tvbuff_t *tvb) |
WS_DLL_PUBLIC void | tvb_set_free_cb (tvbuff_t *tvb, const tvbuff_free_cb_t func) |
WS_DLL_PUBLIC void | tvb_set_child_real_data_tvbuff (tvbuff_t *parent, tvbuff_t *child) |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_child_real_data (tvbuff_t *parent, const guint8 *data, const guint length, const gint reported_length) |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_real_data (const guint8 *data, const guint length, const gint reported_length) |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_subset_length_caplen (tvbuff_t *backing, const gint backing_offset, const gint backing_length, const gint reported_length) |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_subset_length (tvbuff_t *backing, const gint backing_offset, const gint reported_length) |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_subset_remaining (tvbuff_t *backing, const gint backing_offset) |
WS_DLL_PUBLIC void | tvb_composite_append (tvbuff_t *tvb, tvbuff_t *member) |
void | tvb_composite_prepend (tvbuff_t *tvb, tvbuff_t *member) |
WS_DLL_PUBLIC tvbuff_t * | tvb_new_composite (void) |
WS_DLL_PUBLIC void | tvb_composite_finalize (tvbuff_t *tvb) |
WS_DLL_PUBLIC guint | tvb_captured_length (const tvbuff_t *tvb) |
WS_DLL_PUBLIC gint | tvb_captured_length_remaining (const tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint | tvb_ensure_captured_length_remaining (const tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC bool | tvb_bytes_exist (const tvbuff_t *tvb, const gint offset, const gint length) |
WS_DLL_PUBLIC void | tvb_ensure_bytes_exist64 (const tvbuff_t *tvb, const gint offset, const guint64 length) |
WS_DLL_PUBLIC void | tvb_ensure_bytes_exist (const tvbuff_t *tvb, const gint offset, const gint length) |
WS_DLL_PUBLIC bool | tvb_offset_exists (const tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint | tvb_reported_length (const tvbuff_t *tvb) |
WS_DLL_PUBLIC gint | tvb_reported_length_remaining (const tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint | tvb_ensure_reported_length_remaining (const tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC void | tvb_set_reported_length (tvbuff_t *tvb, const guint) |
WS_DLL_PUBLIC void | tvb_fix_reported_length (tvbuff_t *tvb) |
WS_DLL_PUBLIC guint | tvb_offset_from_real_beginning (const tvbuff_t *tvb) |
WS_DLL_PUBLIC gint | tvb_raw_offset (tvbuff_t *tvb) |
WS_DLL_PUBLIC void | tvb_set_fragment (tvbuff_t *tvb) |
WS_DLL_PUBLIC struct tvbuff * | tvb_get_ds_tvb (tvbuff_t *tvb) |
WS_DLL_PUBLIC guint8 | tvb_get_guint8 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint8 | tvb_get_gint8 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint16 | tvb_get_ntohs (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint16 | tvb_get_ntohis (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint32 | tvb_get_ntoh24 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint32 | tvb_get_ntohi24 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint32 | tvb_get_ntohl (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint32 | tvb_get_ntohil (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint64 | tvb_get_ntoh40 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint64 | tvb_get_ntohi40 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint64 | tvb_get_ntoh48 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint64 | tvb_get_ntohi48 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint64 | tvb_get_ntoh56 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint64 | tvb_get_ntohi56 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint64 | tvb_get_ntoh64 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint64 | tvb_get_ntohi64 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gfloat | tvb_get_ntohieee_float (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gdouble | tvb_get_ntohieee_double (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint16 | tvb_get_letohs (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint16 | tvb_get_letohis (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint32 | tvb_get_letoh24 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint32 | tvb_get_letohi24 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint32 | tvb_get_letohl (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint32 | tvb_get_letohil (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint64 | tvb_get_letoh40 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint64 | tvb_get_letohi40 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint64 | tvb_get_letoh48 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint64 | tvb_get_letohi48 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint64 | tvb_get_letoh56 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint64 | tvb_get_letohi56 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint64 | tvb_get_letoh64 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint64 | tvb_get_letohi64 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gfloat | tvb_get_letohieee_float (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gdouble | tvb_get_letohieee_double (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint16 | tvb_get_guint16 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gint16 | tvb_get_gint16 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC guint32 | tvb_get_guint24 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gint32 | tvb_get_gint24 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC guint32 | tvb_get_guint32 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gint32 | tvb_get_gint32 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC guint64 | tvb_get_guint40 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gint64 | tvb_get_gint40 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC guint64 | tvb_get_guint48 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gint64 | tvb_get_gint48 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC guint64 | tvb_get_guint56 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gint64 | tvb_get_gint56 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC guint64 | tvb_get_guint64 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gint64 | tvb_get_gint64 (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gfloat | tvb_get_ieee_float (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC gdouble | tvb_get_ieee_double (tvbuff_t *tvb, const gint offset, const guint encoding) |
WS_DLL_PUBLIC nstime_t * | tvb_get_string_time (tvbuff_t *tvb, const gint offset, const gint length, const guint encoding, nstime_t *ns, gint *endoff) |
WS_DLL_PUBLIC GByteArray * | tvb_get_string_bytes (tvbuff_t *tvb, const gint offset, const gint length, const guint encoding, GByteArray *bytes, gint *endoff) |
WS_DLL_PUBLIC guint32 | tvb_get_ipv4 (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC void | tvb_get_ipv6 (tvbuff_t *tvb, const gint offset, ws_in6_addr *addr) |
int | tvb_get_ipv4_addr_with_prefix_len (tvbuff_t *tvb, int offset, ws_in4_addr *addr, guint32 prefix_len) |
int | tvb_get_ipv6_addr_with_prefix_len (tvbuff_t *tvb, int offset, ws_in6_addr *addr, guint32 prefix_len) |
WS_DLL_PUBLIC void | tvb_get_ntohguid (tvbuff_t *tvb, const gint offset, e_guid_t *guid) |
WS_DLL_PUBLIC void | tvb_get_letohguid (tvbuff_t *tvb, const gint offset, e_guid_t *guid) |
WS_DLL_PUBLIC void | tvb_get_guid (tvbuff_t *tvb, const gint offset, e_guid_t *guid, const guint encoding) |
WS_DLL_PUBLIC guint8 * | tvb_get_bits_array (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, size_t length, size_t *data_length, const guint encoding) |
WS_DLL_PUBLIC guint8 | tvb_get_bits8 (tvbuff_t *tvb, guint bit_offset, const gint no_of_bits) |
WS_DLL_PUBLIC guint16 | tvb_get_bits16 (tvbuff_t *tvb, guint bit_offset, const gint no_of_bits, const guint encoding) |
WS_DLL_PUBLIC guint32 | tvb_get_bits32 (tvbuff_t *tvb, guint bit_offset, const gint no_of_bits, const guint encoding) |
WS_DLL_PUBLIC guint64 | tvb_get_bits64 (tvbuff_t *tvb, guint bit_offset, const gint no_of_bits, const guint encoding) |
WS_DLL_PUBLIC guint32 | tvb_get_bits (tvbuff_t *tvb, const guint bit_offset, const gint no_of_bits, const guint encoding) |
WS_DLL_PUBLIC void * | tvb_memcpy (tvbuff_t *tvb, void *target, const gint offset, size_t length) |
WS_DLL_PUBLIC void * | tvb_memdup (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, size_t length) |
WS_DLL_PUBLIC const guint8 * | tvb_get_ptr (tvbuff_t *tvb, const gint offset, const gint length) |
WS_DLL_PUBLIC gint | tvb_find_guint8 (tvbuff_t *tvb, const gint offset, const gint maxlength, const guint8 needle) |
WS_DLL_PUBLIC gint | tvb_find_guint16 (tvbuff_t *tvb, const gint offset, const gint maxlength, const guint16 needle) |
WS_DLL_PUBLIC gint | tvb_ws_mempbrk_pattern_guint8 (tvbuff_t *tvb, const gint offset, const gint maxlength, const ws_mempbrk_pattern *pattern, guchar *found_needle) |
WS_DLL_PUBLIC guint | tvb_strsize (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC guint | tvb_unicode_strsize (tvbuff_t *tvb, const gint offset) |
WS_DLL_PUBLIC gint | tvb_strnlen (tvbuff_t *tvb, const gint offset, const guint maxlength) |
WS_DLL_PUBLIC gchar * | tvb_format_text (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, const gint size) |
WS_DLL_PUBLIC gchar * | tvb_format_text_wsp (wmem_allocator_t *allocator, tvbuff_t *tvb, const gint offset, const gint size) |
gchar * | tvb_format_stringzpad (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, const gint size) |
gchar * | tvb_format_stringzpad_wsp (wmem_allocator_t *allocator, tvbuff_t *tvb, const gint offset, const gint size) |
WS_DLL_PUBLIC guint8 * | tvb_get_string_enc (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, const gint length, const guint encoding) |
WS_DLL_PUBLIC gchar * | tvb_get_ts_23_038_7bits_string_packed (wmem_allocator_t *scope, tvbuff_t *tvb, const gint bit_offset, gint no_of_chars) |
WS_DLL_PUBLIC gchar * | tvb_get_ts_23_038_7bits_string_unpacked (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, gint length) |
WS_DLL_PUBLIC gchar * | tvb_get_etsi_ts_102_221_annex_a_string (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, gint length) |
WS_DLL_PUBLIC gchar * | tvb_get_ascii_7bits_string (wmem_allocator_t *scope, tvbuff_t *tvb, const gint bit_offset, gint no_of_chars) |
WS_DLL_PUBLIC guint8 * | tvb_get_stringzpad (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, const gint length, const guint encoding) |
WS_DLL_PUBLIC guint8 * | tvb_get_stringz_enc (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, gint *lengthp, const guint encoding) |
WS_DLL_PUBLIC const guint8 * | tvb_get_const_stringz (tvbuff_t *tvb, const gint offset, gint *lengthp) |
WS_DLL_PUBLIC gint | tvb_get_raw_bytes_as_stringz (tvbuff_t *tvb, const gint offset, const guint bufsize, guint8 *buffer) |
WS_DLL_PUBLIC gint | tvb_get_raw_bytes_as_string (tvbuff_t *tvb, const gint offset, char *buffer, size_t bufsize) |
WS_DLL_PUBLIC bool | tvb_ascii_isprint (tvbuff_t *tvb, const gint offset, const gint length) |
WS_DLL_PUBLIC bool | tvb_utf_8_isprint (tvbuff_t *tvb, const gint offset, const gint length) |
WS_DLL_PUBLIC bool | tvb_ascii_isdigit (tvbuff_t *tvb, const gint offset, const gint length) |
WS_DLL_PUBLIC gint | tvb_find_line_end (tvbuff_t *tvb, const gint offset, int len, gint *next_offset, const gboolean desegment) |
WS_DLL_PUBLIC gint | tvb_find_line_end_unquoted (tvbuff_t *tvb, const gint offset, int len, gint *next_offset) |
WS_DLL_PUBLIC gint | tvb_skip_wsp (tvbuff_t *tvb, const gint offset, const gint maxlength) |
WS_DLL_PUBLIC gint | tvb_skip_wsp_return (tvbuff_t *tvb, const gint offset) |
int | tvb_skip_guint8 (tvbuff_t *tvb, int offset, const int maxlength, const guint8 ch) |
WS_DLL_PUBLIC int | tvb_get_token_len (tvbuff_t *tvb, const gint offset, int len, gint *next_offset, const gboolean desegment) |
WS_DLL_PUBLIC gint | tvb_strneql (tvbuff_t *tvb, const gint offset, const gchar *str, const size_t size) |
WS_DLL_PUBLIC gint | tvb_strncaseeql (tvbuff_t *tvb, const gint offset, const gchar *str, const size_t size) |
WS_DLL_PUBLIC gint | tvb_memeql (tvbuff_t *tvb, const gint offset, const guint8 *str, size_t size) |
WS_DLL_PUBLIC gchar * | tvb_bytes_to_str_punct (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, const gint len, const gchar punct) |
WS_DLL_PUBLIC gchar * | tvb_bytes_to_str (wmem_allocator_t *allocator, tvbuff_t *tvb, const gint offset, const gint len) |
WS_DLL_PUBLIC const gchar * | tvb_bcd_dig_to_str (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, const gint len, const dgt_set_t *dgt, gboolean skip_first) |
WS_DLL_PUBLIC const gchar * | tvb_bcd_dig_to_str_be (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, const gint len, const dgt_set_t *dgt, gboolean skip_first) |
WS_DLL_PUBLIC gchar * | tvb_get_bcd_string (wmem_allocator_t *scope, tvbuff_t *tvb, const gint offset, gint len, const dgt_set_t *dgt, gboolean skip_first, gboolean odd, gboolean bigendian) |
WS_DLL_PUBLIC gint | tvb_find_tvb (tvbuff_t *haystack_tvb, tvbuff_t *needle_tvb, const gint haystack_offset) |
WS_DLL_PUBLIC tvbuff_t * | tvb_uncompress (tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_uncompress_zlib (tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress (tvbuff_t *parent, tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress_zlib (tvbuff_t *parent, tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_uncompress_brotli (tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress_brotli (tvbuff_t *parent, tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_uncompress_snappy (tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress_snappy (tvbuff_t *parent, tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_uncompress_lz77 (tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress_lz77 (tvbuff_t *parent, tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_uncompress_lz77huff (tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress_lz77huff (tvbuff_t *parent, tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_uncompress_lznt1 (tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress_lznt1 (tvbuff_t *parent, tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_uncompress_zstd (tvbuff_t *tvb, const int offset, int comprlen) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress_zstd (tvbuff_t *parent, tvbuff_t *tvb, const int offset, int comprlen) |
tvbuff_t * | base64_to_tvb (tvbuff_t *parent, const char *base64) |
tvbuff_t * | base64_tvb_to_new_tvb (tvbuff_t *parent, int offset, int length) |
tvbuff_t * | base64uri_tvb_to_new_tvb (tvbuff_t *parent, int offset, int length) |
WS_DLL_PUBLIC wmem_strbuf_t * | tvb_get_hpack_huffman_strbuf (wmem_allocator_t *scope, tvbuff_t *tvb, const int offset, const int len) |
WS_DLL_PUBLIC tvbuff_t * | tvb_child_uncompress_hpack_huff (tvbuff_t *parent, int offset, int length) |
WS_DLL_PUBLIC guint | tvb_get_varint (tvbuff_t *tvb, guint offset, guint maxlen, guint64 *value, const guint encoding) |
Testy, Virtual(-izable) Buffer of guint8*'s
"Testy" – the buffer gets mad when an attempt is made to access data beyond the bounds of the buffer. An exception is thrown.
"Virtual" – the buffer can have its own data, can use a subset of the data of a backing tvbuff, or can be a composite of other tvbuffs.
Copyright (c) 2000 by Gilbert Ramirez gram@ alum ni.ri ce.e du
Wireshark - Network traffic analyzer By Gerald Combs geral Copyright 1998 Gerald Combs d@wi resha rk.o rg
SPDX-License-Identifier: GPL-2.0-or-later