Cabextract
   HOME

TheInfoList



OR:

Cabinet (or CAB) is an archive-file format for
Microsoft Windows Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
that supports
lossless data compression Lossless compression is a class of data compression that allows the original data to be perfectly reconstructed from the compressed data with no loss of information. Lossless compression is possible because most real-world data exhibits Redundanc ...
and embedded
digital certificate In cryptography, a public key certificate, also known as a digital certificate or identity certificate, is an electronic document used to prove the validity of a public key. The certificate includes the public key and information about it, informa ...
s used for maintaining archive integrity. Cabinet files have .cab
filename extension A filename extension, file name extension or file extension is a suffix to the name of a computer file (for example, .txt, .mp3, .exe) that indicates a characteristic of the file contents or its intended use. A filename extension is typically d ...
s and are recognized by their first four bytes (also called their '' magic number'') ''MSCF''. Cabinet files were known originally as Diamond files.


Design

A CAB archive can contain up to 65,535 ''folders'' (distinct from standard operating system directories), each of which can contain up to 65,535 files for a maximum of 4,294,836,225. Internally, each folder is treated as a single compressed block, which provides more efficient compression than individually compressing each file. Every entry in a folder has to be a file.Microsoft Cabinet Format
/ref> Due to this structure, it is not possible to store empty folders in CAB archives. The following shows an example a CAB file structure, demonstrating the relationship between folders and files: * CAB file ** First folder *** *** ** Second folder *** *** How paths should be handled is not specified in the CAB file format, leaving it to the software implementation: * Some affix file paths to filenames only, as if all files in a CAB archive are in a single folder. IExpress works this way, as does Microsoft Windows Explorer, which can open CAB archives as a folder. * Some can store the paths, and upon extraction, create folders as necessary. and (tools from Microsoft Cabinet SDK) as well as and (third-party
open-source Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use and view the source code, design documents, or content of the product. The open source model is a decentrali ...
tools) work this way. * , only since version 6 (which is included from Windows Vista to above) can extract files to their paths. The previous versions don't do it. The CAB file format may employ the following
compression algorithm In information theory, data compression, source coding, or bit-rate reduction is the process of encoding information using fewer bits than the original representation. Any particular compression is either lossy or lossless. Lossless compression ...
s: * DEFLATE: invented by
Phil Katz Phillip Walter Katz (November 3, 1962 – April 14, 2000) was a computer programmer best known as the co-creator of the ZIP file format for data compression, and the author of PKZIP, a program for creating zip files that ran under DOS. ...
, the author of the
ZIP file format ZIP is an archive file format that supports lossless data compression. A ZIP file may contain one or more files or directories that may have been compressed. The ZIP file format permits a number of compression algorithms, though DEFLATE is t ...
(specifically, the MSZIP encapsulation) * Quantum compression: licensed from David Stafford, the author of the Quantum archiver (not available in all versions of makecab.exe/diamond.exe) *
LZX LZX is an LZ77 family Data compression, compression algorithm, a slightly improved version of DEFLATE. imlib: the open source Windows Imaging (WIM) library - Compression algorithm https://wimlib.net/compression.htmlIt is also the name of a arc ...
: invented by Jonathan Forbes and Tomi Poutanen, given to Microsoft when Forbes joined the company * NULL: stored A CAB archive can reserve empty spaces in the archive as well as for each file in the archive, for some application-specific uses like digital signatures or arbitrary data.


Implementations

Microsoft Windows Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
supports creating CAB archive files using the makecab
command-line A command-line interface (CLI) is a means of interacting with software via commands each formatted as a line of text. Command-line interfaces emerged in the mid-1960s, on computer terminals, as an interactive and more user-friendly alternativ ...
utility. It supports extracting the contents of a CAB archive files using
File Explorer File Explorer, previously known as Windows Explorer, is a file manager application and default desktop environment that is included with releases of the Microsoft Windows operating system from Windows 95 onwards. It provides a graphical user i ...
, Setup API, and using the command-line commands expand.exe,expand – Windows CMD – SS64.com
/ref> extract.exe and extrac32.exe.
/ref> Other well-known software with CAB archive support includes
WinZip WinZip is a trialware file archiver and data compression, compressor for Microsoft Windows, macOS, iOS and Android (operating system), Android. It is developed by WinZip Computing (formerly Nico Mak Computing), which is owned by Alludo. The p ...
,
WinRAR WinRAR is a trialware file archiver utility, developed by Eugene Roshal of win.rar GmbH. It can create and view archives in RAR or ZIP file formats, and unpack numerous archive file formats. To enable the user to test the integrity of archive ...
or
7-Zip 7-Zip is a free and open-source file archiver, a utility used to place groups of files within compressed containers known as "archives". It is developed by Igor Pavlov and was first released in 1999. 7-Zip has its own Archive file, archive forma ...
. The aforementioned cabextract is a common tool for Linux systems, but is only capable of extracting archives. The gcab tool however can both extract and create CAB archives. For a full list, see .


Uses

A variety of
Microsoft Microsoft Corporation is an American multinational corporation and technology company, technology conglomerate headquartered in Redmond, Washington. Founded in 1975, the company became influential in the History of personal computers#The ear ...
installation technologies use the CAB format: these include
Windows Installer Windows Installer (msiexec.exe, previously known as Microsoft Installer, List of Microsoft codenames, codename Darwin) is a software component and application programming interface (API) of Microsoft Windows used for the Installation (computer ...
,
Windows Setup Windows Setup is an Installation (computer programs), installer that prepares a computer for a Microsoft Windows installation by allowing the user to pick installation settings (modifying Partition (computing), partitions if necessary) and co ...
(from
Windows 95 Windows 95 is a consumer-oriented operating system developed by Microsoft and the first of its Windows 9x family of operating systems, released to manufacturing on July 14, 1995, and generally to retail on August 24, 1995. Windows 95 merged ...
to
Windows Server 2003 Windows Server 2003, codenamed "Whistler Server", is the sixth major version of the Windows NT operating system produced by Microsoft and the first server version to be released under the Windows Server brand name. It is part of the Windows NT ...
), Setup API, Device Installer, Theme Pack and AdvPack (used by
Internet Explorer Internet Explorer (formerly Microsoft Internet Explorer and Windows Internet Explorer, commonly abbreviated as IE or MSIE) is a deprecation, retired series of graphical user interface, graphical web browsers developed by Microsoft that were u ...
to install
ActiveX ActiveX is a deprecated software framework created by Microsoft that adapts its earlier Component Object Model (COM) and Object Linking and Embedding (OLE) technologies for content downloaded from a network, particularly from the World Wide W ...
components). CAB files are also often associated with self-extracting programs like IExpress where the executable program extracts the associated CAB file. CAB files are also sometimes embedded into other files. For example, MSI and MSU files usually include one or more embedded CAB files. Windows uses the cabinet format to archive its Component-Based Servicing (CBS) log, which is kept in the folder . A bug in the compression process can cause run-away generation of useless log files both in that folder and in , which can consume disk storage until completely filling the hard drive. Deletion of the files without following a specific procedure can cause the deleted files to be regenerated at an increased pace. On
Linux Linux ( ) is a family of open source Unix-like operating systems based on the Linux kernel, an kernel (operating system), operating system kernel first released on September 17, 1991, by Linus Torvalds. Linux is typically package manager, pac ...
systems, CAB archives are used by
fwupd fwupd is an open-source daemon for managing the installation of firmware updates on Linux-based systems, developed by GNOME maintainer Richard Hughes. It is designed primarily for servicing the Unified Extensible Firmware Interface (UEFI) firmwa ...
to distribute
firmware In computing Computing is any goal-oriented activity requiring, benefiting from, or creating computer, computing machinery. It includes the study and experimentation of algorithmic processes, and the development of both computer hardware, h ...
updates from hardware vendors that can be flashed on
non-volatile memory Non-volatile memory (NVM) or non-volatile storage is a type of computer memory that can retain stored information even after power is removed. In contrast, volatile memory needs constant power in order to retain data. Non-volatile memory typ ...
.


Related formats

The .cab filename extension is also used by other installer programs (e.g.
InstallShield InstallShield is a proprietary software tool for creating installers or software packages. InstallShield is primarily used for installing software for Microsoft Windows desktop and server platforms, though it can also be used to manage software ...
) for their own proprietary archiving formats. InstallShield uses
zlib zlib ( or "zeta-lib", ) is a software library used for data compression as well as a data format. zlib was written by Jean-loup Gailly and Mark Adler and is an abstraction of the DEFLATE compression algorithm used in their gzip file compre ...
for compression (see Deflate), but their headers are not the same as for Microsoft CAB files so they are incompatible and cannot be manipulated or edited with the programs that are made for standard cabinet format. Specialized third-party utilities, such as Unshield, can extract this specific proprietary format. This format has a different magic number of .
Windows CE Windows CE, later known as Windows Embedded CE and Windows Embedded Compact, is a discontinued operating system developed by Microsoft for mobile and embedded devices. It was part of the Windows Embedded family and served as the software foun ...
software is distributed as CAB files where the first file inside, ending with extension ".000", details how it is installed.
Microsoft Installer Windows Installer (msiexec.exe, previously known as Microsoft Installer, codename Darwin) is a software component and application programming interface (API) of Microsoft Windows used for the installation, maintenance, and removal of software ...
.msi files sometimes ''contain'' CAB files, but are themselves in the
Compound File Binary Format Compound File Binary Format (CFBF), also called Compound File, Compound Document format, or Composite Document File V2 (CDF), is a compound document file format for storing numerous files and streams within a single file on a disk. CFBF is develo ...
which has to be decoded first. Software like lessmsi can be used to unpack these files. Microsoft Publisher has a "Pack and Go" feature that bundles a publisher document, together with all external links, into a CAB file with a .PUZ extension. These files are meant to be activated with a companion .EXE file which is distributed along with the .PUZ file. These files may be opened with any CAB file extraction program.


See also

*
List of archive formats This is a list of file formats used by file archiver, archivers and data compression, compressors used to create Archive file, archive files. Archive formats by purpose Archive formats are used for backups, mobility, and archiving. Many archive ...


References


External links


Microsoft Cabinet SDK
– updated versions of these resources are available in the
Microsoft Windows SDK Microsoft Windows SDK, and its predecessors Platform SDK, and .NET Framework SDK, are software development kits (SDKs) from Microsoft that contain documentation, header files, libraries, samples and tools required to develop applications for Micr ...

Cabinet Software Development Kit (CAB SDK)
– downloads of all Microsoft CAB SDK versions (free) {{Windows commands Archive formats Windows administration