Rizin
unix-like reverse engineering framework and cli tools
mscabd_cabinet Struct Reference

#include <mspack.h>

Public Attributes

struct mscabd_cabinetnext
 
const char * filename
 
off_t base_offset
 
unsigned int length
 
struct mscabd_cabinetprevcab
 
struct mscabd_cabinetnextcab
 
char * prevname
 
char * nextname
 
char * previnfo
 
char * nextinfo
 
struct mscabd_filefiles
 
struct mscabd_folderfolders
 
unsigned short set_id
 
unsigned short set_index
 
unsigned short header_resv
 
int flags
 

Detailed Description

A structure which represents a single cabinet file.

All fields are READ ONLY.

If this cabinet is part of a merged cabinet set, the files and folders fields are common to all cabinets in the set, and will be identical.

See also
mscab_decompressor::open(), mscab_decompressor::close(), mscab_decompressor::search()

Definition at line 699 of file mspack.h.

Member Data Documentation

◆ base_offset

off_t mscabd_cabinet::base_offset

The file offset of cabinet within the physical file it resides in.

Definition at line 715 of file mspack.h.

Referenced by cabd_read_headers(), cabd_search(), and cabinfo().

◆ filename

const char * mscabd_cabinet::filename

The filename of the cabinet. More correctly, the filename of the physical file that the cabinet resides in. This is given by the library user and may be in any format.

Definition at line 712 of file mspack.h.

Referenced by cabd_extract(), cabd_find(), cabd_open(), cabinfo(), and process_cabinet().

◆ files

struct mscabd_file * mscabd_cabinet::files

A list of all files in the cabinet or cabinet set.

Definition at line 743 of file mspack.h.

Referenced by cabd_close(), cabd_merge(), cabd_read_headers(), cabinfo(), main(), process_cabinet(), and rz_bin_pdb_extract_in_folder().

◆ flags

int mscabd_cabinet::flags

Header flags.

  • MSCAB_HDR_PREVCAB indicates the cabinet is part of a cabinet set, and has a predecessor cabinet.
  • MSCAB_HDR_NEXTCAB indicates the cabinet is part of a cabinet set, and has a successor cabinet.
  • MSCAB_HDR_RESV indicates the cabinet has reserved header space.
See also
prevname, previnfo, nextname, nextinfo, header_resv

Definition at line 784 of file mspack.h.

Referenced by cmd_descs_generate.Arg::__str__(), cabd_read_headers(), cabinfo(), and load_spanning_cabinets().

◆ folders

struct mscabd_folder * mscabd_cabinet::folders

A list of all folders in the cabinet or cabinet set.

Definition at line 746 of file mspack.h.

Referenced by cabd_close(), cabd_merge(), and cabd_read_headers().

◆ header_resv

unsigned short mscabd_cabinet::header_resv

The number of bytes reserved in the header area of the cabinet.

If this is non-zero and flags has MSCAB_HDR_RESV set, this data can be read by the calling application. It is of the given length, located at offset (base_offset + MSCAB_HDR_RESV_OFFSET) in the cabinet file.

See also
flags

Definition at line 771 of file mspack.h.

Referenced by cabd_read_headers().

◆ length

unsigned int mscabd_cabinet::length

The length of the cabinet file in bytes.

Definition at line 718 of file mspack.h.

Referenced by cabd_read_headers(), and cabinfo().

◆ next

struct mscabd_cabinet * mscabd_cabinet::next

The next cabinet in a chained list, if this cabinet was opened with mscab_decompressor::search(). May be NULL to mark the end of the list.

Definition at line 705 of file mspack.h.

Referenced by cabd_close(), cabd_read_headers(), cabinfo(), and process_cabinet().

◆ nextcab

struct mscabd_cabinet * mscabd_cabinet::nextcab

The next cabinet in a cabinet set, or NULL.

Definition at line 724 of file mspack.h.

Referenced by cabd_append(), cabd_close(), cabd_merge(), cabd_read_headers(), cabinfo(), load_spanning_cabinets(), and process_cabinet().

◆ nextinfo

char * mscabd_cabinet::nextinfo

The name of the disk containing the next cabinet in a cabinet set, or NULL.

Definition at line 740 of file mspack.h.

Referenced by cabd_close(), cabd_read_headers(), cabinfo(), and load_spanning_cabinets().

◆ nextname

char * mscabd_cabinet::nextname

The filename of the next cabinet in a cabinet set, or NULL.

Definition at line 730 of file mspack.h.

Referenced by cabd_close(), cabd_read_headers(), cabinfo(), and load_spanning_cabinets().

◆ prevcab

struct mscabd_cabinet * mscabd_cabinet::prevcab

The previous cabinet in a cabinet set, or NULL.

Definition at line 721 of file mspack.h.

Referenced by cabd_close(), cabd_merge(), cabd_prepend(), cabd_read_headers(), cabinfo(), load_spanning_cabinets(), and process_cabinet().

◆ previnfo

char * mscabd_cabinet::previnfo

The name of the disk containing the previous cabinet in a cabinet set, or NULL.

Definition at line 735 of file mspack.h.

Referenced by cabd_close(), cabd_read_headers(), and load_spanning_cabinets().

◆ prevname

char * mscabd_cabinet::prevname

The filename of the previous cabinet in a cabinet set, or NULL.

Definition at line 727 of file mspack.h.

Referenced by cabd_close(), cabd_read_headers(), and load_spanning_cabinets().

◆ set_id

unsigned short mscabd_cabinet::set_id

The set ID of the cabinet. All cabinets in the same set should have the same set ID.

Definition at line 752 of file mspack.h.

Referenced by cabd_merge(), and cabd_read_headers().

◆ set_index

unsigned short mscabd_cabinet::set_index

The index number of the cabinet within the set. Numbering should start from 0 for the first cabinet in the set, and increment by 1 for each following cabinet.

Definition at line 759 of file mspack.h.

Referenced by cabd_merge(), and cabd_read_headers().


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