Wireshark 4.7.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
Public Attributes | List of all members
file_extension_info Struct Reference

For registering extensions used for file formats. More...

#include <wtap.h>

Public Attributes

const char * name
 
bool is_capture_file
 
const char * extensions
 

Detailed Description

For registering extensions used for file formats.

These items are used in dialogs for opening files, so that the user can ask to see all capture files (as identified by file extension) or particular types of capture files.

Each item has a human-readable description of the file types (possibly more than one!) that use all of this set of extensions, a flag indicating whether it's a capture file or just some file whose contents we can dissect, and a list of extensions files of that type might have.

Note that entries in this table do not necessarily correspond to single file types; for example, the entry that lists just "cap" is for several file formats, all of which use the extension ".cap".

Also note that a given extension may appear in multiple entries; for example, "cap" (again!) is in an entry for some file types that use only ".cap" and in entries for file types that use ".cap" and some other extensions, and ".trc" is used both for DOS Sniffer Token Ring captures ("trc") and EyeSDN USB ISDN trace files ("tr{a}c{e}").

Some entries aren't for capture file types, they're just generic types, such as "text file" or "XML file", that can be used for, among other things, captures we can read, or for file formats we can read in order to dissect the contents of the file (think of this as "Fileshark", which is a program that we really should have). Those are marked specially, because, in file section dialogs, the user should be able to select "All Capture Files" and get a set of extensions that are associated with capture file formats, but not with files in other formats that might or might not contain captured packets (such as .txt or .xml") or formats that aren't capture files but that we support as "we're being Fileshark now" (such as .jpeg). The routine that constructs a list of extensions for "All Capture Files" omits extensions for those entries.

Member Data Documentation

◆ extensions

const char* file_extension_info::extensions

Semicolon-separated list of file extensions.

◆ is_capture_file

bool file_extension_info::is_capture_file

True if this is a capture file format.

◆ name

const char* file_extension_info::name

Human-readable description of the file type.


The documentation for this struct was generated from the following file: