| Wireshark 4.7.3 The Wireshark network protocol analyzer

Loading...
Searching...
No Matches
Functions
text_import_regex.h File Reference
`#include <glib.h>`
`#include "text_import.h"`

Go to the source code of this file.

## Functions
void | parse_data (unsigned char *start_field, unsigned char *end_field, enum data_encoding encoding)
| Parses data based on the specified encoding.
void | parse_dir (const unsigned char *start_field, const unsigned char *end_field, const char *in_indicator, const char *out_indicator)
| Parses directory information from a given field.
void | parse_time (const unsigned char *start_field, const unsigned char *end_field, const char *format)
| Parses time information from a given field and updates the timestamp.
void | parse_seqno (const unsigned char *start_field, const unsigned char *end_field)
| Parses sequence number from a given field.
void | flush_packet (void)
| Flushes the current packet and prepares for the next one.
int | text_import_regex (const text_import_info_t *info)
| Imports text data using regular expressions.

## Detailed Description

text_import_regex.h Regex based alternative to the state machine for text import February 2021, Paul Weiß pauln.nosp@m.ikla.nosp@m.sweis.nosp@m.s@gm.nosp@m.ail.c.nosp@m.om

Wireshark - Network traffic analyzer By Gerald Combs geral.nosp@m.d@wi.nosp@m.resha.nosp@m.rk.o.nosp@m.rg Copyright 1998 Gerald Combs

Based on text_import.h by Jaap Keuter jaap..nosp@m.keut.nosp@m.er@xs.nosp@m.4all.nosp@m..nl

SPDX-License-Identifier: GPL-2.0-or-later*

## Function Documentation

## ◆ parse_data()

void parse_data | ( | unsigned char * | start_field,
|  | unsigned char * | end_field,
|  | enum data_encoding | encoding )

Parses data based on the specified encoding.

Parameters

  start_field | Pointer to the start of the field containing the data.
  end_field | Pointer to the end of the field containing the data.
  encoding | The encoding type of the data (e.g., HEX, OCT, BIN, BASE64).

## ◆ parse_dir()

void parse_dir | ( | const unsigned char * | start_field,
|  | const unsigned char * | end_field,
|  | const char * | in_indicator,
|  | const char * | out_indicator )

Parses directory information from a given field.

Parameters

  start_field | Pointer to the start of the field.
  end_field | Pointer to the end of the field.
  in_indicator | Pointer to the input indicator string.
  out_indicator | Pointer to the output indicator string.

## ◆ parse_seqno()

void parse_seqno | ( | const unsigned char * | start_field,
|  | const unsigned char * | end_field )

Parses sequence number from a given field.

Parameters

  start_field | Pointer to the start of the field.
  end_field | Pointer to the end of the field.

## ◆ parse_time()

void parse_time | ( | const unsigned char * | start_field,
|  | const unsigned char * | end_field,
|  | const char * | format )

Parses time information from a given field and updates the timestamp.

Parameters

  start_field | Pointer to the start of the time field in the input data.
  end_field | Pointer to the end of the time field in the input data.
  format | The format string specifying how to parse the time field.

## ◆ text_import_regex()

int text_import_regex | ( | const text_import_info_t * | info | ) |

Imports text data using regular expressions.

Parameters

  info | Pointer to the import information structure.

Returns
  int Status of the import operation (1 for success, 0 for failure).