KeyView 24.1

# extract

Some files can contain embedded subfiles, including archive formats such as `zip` and `rar`, email containers, and Office formats. This sample program makes use of the subfile extraction API methods.

The sample program takes two positional arguments:

- a path to a file
- a path to an output directory

The program copies all the subfiles in the file to the output directory, and prints any errors encountered during extraction. For example, the following output is produced when you run the program on a password-protected 7zip file:

    $ ./extract pass.7z outputdir/
    Error extracting subfile 0
    Name: hello.txt
    Keyview error: The file is password protected

If you provide the correct password using the optional argument, KeyView can extract the file:

    $ ./extract --password 'pass' pass.7z outputdir/
    $ ls outputdir/
    hello.txt

NOTE: In this instance KeyView captures the name of the subfile even without providing a password. Whether this is possible depends on the file format and the encryption options that were used to create the file.

Copyright 2016-2023 Open Text
Version 24.1 | Last updated December 2023

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to MFI-swpdl.idoldocsfeedback@opentext.com.

We appreciate your feedback!

Product: IDOL KeyView 24.1

Topic Title: extract