MsCab.exe works via MultiArc with (Microsoft) CAB archives.
It allows you to create, modify and extract CAB archives.

MsCab extends original (Microsoft) CAB format:
1. It allows you to add dirs' names to an archive.
2. You can encrypt files with password.
3. You can pack more than 65535 files per cabinet.
You can make standard CAB archives -- simply don't use these three extensions.


You can apply following options:

Multiple volumes archive:
  -v360, -v720, -v1200, -v1440    standard floppy disk size
  -v<size>                        <size> bytes volumes
                                  32K <= <size> <= 2047M
    size = <number>[k|K|m|M]
         = number bytes [*1000, *1024, *1000*1000, *1024*1024]

  -vr<size>                       reserve <size> bytes of space on first volume
  -n1                             name of first volume append with '1'
                        (default: Name.cab, Name2.cab, Name3.cab, ...
                             -n1: Name1.cab, Name2.cab, Name3.cab, ...)
  -n01                            name of first volume append with '01'
   ...
  -n000001                        name of first volume append with '000001'

  examples:
    -v1440 -vr100K -n1          1.44 floppy disk size,
                                  first volume smaller 100*1024 bytes,
                                  first volume name append with '1'
    -v4M                        4 MB volume size

  If you create archive on removable media (like floppy disk), MsCab checks
  free space (on each of needed disks) and automatically creates multiple
  volumes archive.

Archive folder size:
  -f<size>                        <size> bytes archive folder
                                  32K <= <size> <= 512M
                                  (default: -f16M)
  Small size - fast random file decompression,
               (usually) worse compression ratio
  Large size - slow random file decompression,
               (usually) better compression ratio

Compression method:
  -NONE                           no compression
  -MSZIP                          ZIP compression method
  -LZX:15, -LZX:16, ..., -LZX:21  LZX compression method
                                  (default: -LZX:21)
Sorting file names:
  -ds                             disable name sort
                                  (default: sort by extension and file size)
Progress information:
  -i                              display progress window in taskbar
  -i0                             display percentage progress in console
                                    window
Path inside archive:
  -ap["]<path>["]                 set path inside archive
                                    for example: -ap"Directory with spaces"
Wildcards:
  -r0                             search for wildcards in subdirs too
  -r                              search for any name in subdirs too

SFX module:
  -sfx[Module][:ScriptFile]       add Module.MsCabSFX (if specified)
                                    or Default.MsCabSFX (if Module omitted)
                                    or internal en_i.MsCabSFX (if there isn't
                                    Default.MsCabSFX on HDD)
                                  SFX module file must be in the same directory
                                    as the MsCab.exe
  -sfx-                           remove SFX module when modifying an archive

  examples:
    -sfxru                        add ru.MsCabSFX module
    -sfxen2_i:C:\Script.txt       add en2_i.MsCabSFX module + C:\Script.txt
                                    script file (valid only for "*_i" modules)

Encryption with password:
  -p[password]                    encrypt files with password; if you don't
                                    specify password (only '-p' switch), MsCab
                                    ask you for a password
  /+<name(s)>                     if you start with '/+' option (after '-p'
                                    option), MsCab assume that you want
                                    to encrypt only files specified in '/+'
                                    option(s), excluding files from '/-'
                                    option(s)
  /-<name(s)>                     if you start with '/-' option (after '-p'
                                    option), MsCab assume that you want
                                    to encrypt all files excluding specified
                                    in '/-' option(s)
  -rp                             recurse subdirectories in '/+' and '/-' options
  -rp0                            recurse subdirectories for wildcard names only
                                    in '/+' and '/-' options
  examples:
    -p"My password" /-ReadMe.* /+*.htm* -rp0
                                  encrypt all files with 'My password' password
                                    except 'ReadMe.*' files in all subdirs, but
                                    encrypt 'ReadMe.htm*' files
    -p /+*.exe /+*.dll            encrypt *.exe and *.dll files from top level
                                    directory with password (MsCab ask you for
                                    the password)

Adding directory names to archive:
  -dirs[-]                        turn on [off] adding dirs into archive

Dialog box for choosing options:
  -ask[-]                         MsCab displays [or not] a GUI dialog box
                                    for easy options setting

Set priority:
  -ri<n>                          n | Priority
                                  --+--------------
                                  0 | PRIORITY_IDLE
                                  1 | PRIORITY_BELOW_NORMAL (default)
                                  2 | PRIORITY_NORMAL (default up to 0.60)
                                  3 | PRIORITY_ABOVE_NORMAL

Working directory:
  -wt                             force temporary folder
  -wd                             force destination folder
  -w[directory]                   force user specified directory
                                    for example -w"c:\My documents\temp"
  -w                              turn back autodetect of working dir

Generate archive name using the current date and time
  -ag[format]                     works like in RAR -- copy from Rar.txt:
           "Appends the current date string to an archive name when
            creating an archive. Useful for daily backups.

            Format of the appending string is defined by the optional
            "format" parameter or by "YYYYMMDDHHMMSS" if this parameter
            is absent. Format string may include the following characters:

            Y   - year
            M   - month
            MMM - month name as text string (Jan, Feb, etc.)
            W   - a week number (a week starts with Monday)
            A   - day of week number (Monday is 1, Sunday - 7)
            D   - day of month
            E   - day of year
            H   - hours
            M   - minutes (treated as minutes if encountered after hours)
            S   - seconds

            If the first character in the format string is '*', positions
            of the date string and base archive name are exchanged,
            so date will precede an archive name.

            All other characters are added to an archive name without
            changes." [end of copy; N not works in MsCab; * replaces +]


WARNING: If you want to make a standard CAB archive, please use -dirs- option,
         don't use encryption with password and don't pack more than 65535 files
         per cabinet.
         If you want to add dirs’ names and/or encrypt files with password in
         archive that you send to someone, consider making SFX archive (for
         archive with encrypted files you must use bigger *_i.MsCabSFX module).
         In this case you will be sure, that the person who receive this archive
         can unpack it.


Options are case sensitive. You must put them before command letter.

If you want to view contents and extract files from SFX CAB archives
(and even from some *.msi files) via MsCab, rename considered files
to names with .cab extension.


You can use MsCab manually from command line (not recommended).
Examples:
  MsCab -i0 -r a t               - Add to 't.cab' all files from current
                                   directory (and subdirs)
  MsCab -i0 m t.cab *.doc *.wbk  - Move to 't.cab' all *.doc and *.wbk files
                                   from current directory
  MsCab x t.cab                  - Extract (with paths) all files from 't.cab'
  MsCab -sfx s t.cab             - Convert 't.cab' archive to 't.exe'
                                   SFX archive with default SFX module

  MsCab -i0 -r -dirs -ag_YYYY-MM-DD-HH-MM -ap"test backup" a ..\test.cab @COMPRESS.LST
     COMPRESS.LST:
        debug*\.
        debug
        *.txt
        description\
        description\*
     [end of COMPRESS.LST]
                                 - Create 'test_YYYY-MM-DD-HH-MM.cab' archive
                                   (for example test_2003-05-29-06-30.cab)
                                   and add (to 'test backup' subdir in the
                                   archive) files (from subdirs too):
                                    debug*\.      - no files
                                    debug         - all debug files
                                    *.txt         - all *.txt files
                                    description\  - no files
                                    description\* - all files inside this dir
                                   Directories' names are added:
                                    debug*\.      - all that match debug* mask
                                    debug         - all debug (sub)dirs
                                                    (subset of debug*\. mask)
                                    *.txt         - all that match *.txt mask
                                    description\  - only description dir
                                    description\* - all subdirs from this dir

          You can use wildcards *? only in the last part of the path:
             dir1\dir2\*.txt   - all *.txt files from dir1\dir2
     ERROR:  dir1\dir?\*.txt   - not works
          If you add '\.' at the end of the mask, MsCab search for dirs only:
             *\.               - add all dirs' names (without any file)
          If you add '\' at the end of the name, MsCab adds only this one dir:
             dir1\dir2\        - only dir1\dir2 dir (error if it not exists)
          DirName\* adds all files (and dirs) inside DirName but not DirName.


If you make SFX archive and you use *_i.MsCabSFX module, you can add script
file, for example -sfxen_i:ScriptFile.txt


*** Script File Description ***

Script file is simply text file of the form:
MBSF
Key1=Value1
Key2=Value2
...
END=

First 4 bytes of the script must be MBSF (Mateusz Brzostek Script File ;-)).

Currently there are 14 valid keys:
Title -- you can specify text in the title bar of main MsCab SFX window;
Text  -- you can specify (up to 750 chars) text instead of default
         "Press "OK" button..."; For new line character use \n string,
         for \ character use \\ string; do not break this line by ENTER;
Prompt -- text that replaces "Extract to:";
IDOK  -- text that replaces "OK" in the IDOK button;
Path  -- you can specify suggested path; you can specify an absolute path
         or you can use a special folder paths; you can specify environment
         variables to expand by *NAME*, for example
           Path=c:\%USERNAME%\*USERNAME*\USERNAME
         it will be expanded to
           c:\%USERNAME%\Mateusz\USERNAME
         if 'USERNAME' environment variable is equal to 'Mateusz';
         currently only five 'special folders' are valid:
  :PERSONAL  -- "My documents" folder;
  :DESKTOPDIRECTORY  -- "Windows\Desktop" folder (after extraction
                        there are icons on the screen);
  :STARTUP  -- File system directory that corresponds to the user's
               Startup program group;
  :TEMP     -- the path of the directory designated for temporary files;
  :PROGRAMFILES  -- ProgramFilesDir.

Open=<FileName>
OpenDel=<FileName>
Run=<CommandLine>
RunDel=<CommandLine>
  -- you can specify file to open (for example ReadMe.html) or whole command
  line to execute (for example Notepad.exe "My TXT file.txt"); 'OpenDel' and
  'RunDel' waits for process finish and deletes extracted files/dirs;
  you can use up to 8 Open/OpenDel/Run/RunDel commands (in sum)
WaitDel=<FileName>
  -- it waits for read/write access to 'FileName' file; you can use it
  when SetUp.exe launches Install.exe and terminates -- in such case use
    RunDel=SetUp.exe
    WaitDel=Install.exe
  -- it prevents from too fast deleting files;
  you can use up to 8 'WaitDel' commands, but you must use at least one
  Open/OpenDel/Run/RunDel command when you use 'WaitDel'
RunText=<Prompt>
  -- you can specify new prompt instead of default
  '&Run "%s" after unpacking'
  (%s is for first Open/OpenDel/Run/RunDel command)
Over=1
  -- you can initially check '&Overwrite without prompting'
OverText=<Prompt>
  -- you can specify new prompt instead of default
  '&Overwrite without prompting'
Off=[Path][Run][Over]
  -- you can turn off 'Path' edit box, 'Run' or/and 'Over' checkbox (do not
  forget to specify valid path when you use 'Off=Path' command)

Last 4 bytes of that script must be END=

Example:
MBSF
Title=Main window title
Text=   Hello!\n   Would you like to extract this archive into 'SubDir' directory in your documents folder?
Path=:PERSONAL\SubDir
IDOK=Extract
Over=1
Open=ReadMe.txt
RunText=Display ReadMe file
Off=Path Over
END=

If you omit some key, the default values (for that key) will be used.

If you use
  -sfxen_i:Script.txt
option in MsCab, the 'Script.txt' file will be loaded from the same directory
as MsCab.exe; if there is no 'Script.txt' file in that directory, MsCab loads
script file from the current directory. You can also specify an absolute path
for script file.

You can use the script file only with xx_i.MsCabSFX or xx2_i.MsCabSFX
modules, where xx is from desired language (de, en, fr, it, pl, ru).
From MsCab 0.60b6 you can use the script file with internal (en_i) MsCabSFX
module (for example -sfx:Script.txt).

For latest version of MsCab please visit http://www.mscab.prv.pl