Windows ships with a small, easily-overlooked command-line tool called expand.exe for extracting the contents of CAB files — useful for driver packages, Windows Update packages, or any archive distributed in Microsoft’s cabinet format, without needing a third-party archiver.
Extract All Files from a CAB
expand -F:* driverpack.cab C:Extracted
The -F:* switch tells expand to extract every file in the cabinet (rather than a single named file) into the destination folder.
Extract a Single File
expand -F:ntprint.inf driverpack.cab C:Extracted
Expanding a Single Renamed Compressed File
Some older Windows source media store individual files in a compressed form with the last character of the extension replaced by an underscore (for example ntoskrnl.ex_). To decompress one of these directly to its real filename:
expand ntoskrnl.ex_ ntoskrnl.exe
Run expand /? for the full switch list — it also supports listing a cabinet’s contents without extracting anything, using -D.
Resources
Gear We Recommend
A few general tech accessories worth having alongside this.
Browse our General Tech Accessories picks on AmazonAs an Amazon Associate, TechyGeeksHome earns from qualifying purchases.
Discover more from TechyGeeksHome
Subscribe to get the latest posts sent to your email.