certutil.exe is not working

Krishnan Krishnan 20 Reputation points
2025-01-14T18:17:27.58+00:00

I tried to generate SHA256 of a downloaded file by using command certutil -hashfile [file path] SHA256. its returning message:"CertUtil: -hashfile command FAILED: 0x80070002 (WIN32: 2 ERROR_FILE_NOT_FOUND) CertUtil: The system cannot find the file specified."

Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
10,455 questions
0 comments No comments
{count} votes

Accepted answer
  1. MotoX80 35,131 Reputation points
    2025-01-15T13:39:02.87+00:00

    The most obvious cause is that whatever you entered as "[file path]" is incorrect.

    From a command prompt run a "dir [file path]" command to verify that you didn't mistype the name. If there are spaces in the name, you will need to put double quotes around [file path].

    1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. Ian Xue 38,936 Reputation points Microsoft Vendor
    2025-01-16T05:17:15.57+00:00

    Hi Krishnan Krishnan,

    Thanks for your post. Based on my experience, we have encountered similar cases that was resolved by add the private key in the same folder. Can you please also try to put the private key in the same folder renamed to mycert.key (where mycert is whatever the name of the CER file is). This was the file that could not be found. The private key in this case had been downloaded from Certificate app as a text file.

    Best Regards,

    Ian Xue


    If the Answer is helpful, please click "Accept Answer" and upvote it.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.