Fciv command

Updated: 11/12/2023 by Computer Hope
fciv command at a command line.

Short for File Checksum Integrity Verifier, FCIV is a command that checks the MD5 or SHA-1 file checksum cryptographic hash information.

Availability

Fciv is an external command that is not pre-installed with any version of Windows, it must be downloaded from Microsoft. Once it is installed, it is executed using the fciv.exe external file. See the link below for full steps on installing and using the FCIV command.

Fciv syntax

fciv.exe [Commands] <Options>
-add <file | dir>

Compute hash and send to output (default screen).

dir options:
-r : recursive.
-type : ex: -type *.exe.
-exc file: list of directories that should not be computed.
-wp : Without full path name. Default store full path.
-bp : specify base path to remove from full path name.
-list List entries in the database.
-v

Verify hashes.

Option: -bp basepath
-md5 | -sha1 | -both Specify hashtype, default md5,
-xml db Specify database format and name,

Fciv examples

fciv hope.txt

Running the fciv against any file (in this case hope.txt) displays the file checksum information similar to the example below.

//
// File Checksum Integrity Verifier version 2.05.
//
30ad2c562520d88d4e030fecf2f8c642 hope.txt
fciv hope.txt -both

Running the command above gives the output for both MD5 and SHA-1.

fciv -add hope.txt -xml hope.xml

Add the MD5 information of the "hope.txt" file to the XML hope.xml file. If the file does not exist a new file is created. Below is an example of the XML file created using this command.

<?xml version="1.0" encoding="utf-8"?>
<FCIV>
<FILE_ENTRY><name>hope.txt</name><MD5>kS7IA7LOSeSlQQaNSVq1cA==</MD5></FILE_ENTRY></FCIV>