Error description: An error occurred while opening Visual Studio Installer: “vs_installershell.exe has an invalid certificate”. The program terminates afterwards.
Problem analysis: Manually check the digital signature via Properties window, the SHA1 signature is invalid. By clicking “View certificate”, it says that the “Microsoft Root Certificate Authority” CA certificate is revoked, the signature is invalid. The VS installer cannot be started because the digital signature validation failed.
Work around: Manually start vs_installershell.exe from File Explorer. By default it’s located in C:\Program Files(x86)\Microsoft Visual Studio\Installer\. Note that you should run as administrator.
Export the CA certificate “Microsoft Root Certificate Authority” to file.
Disable Automatic Root Certificate Update in Group policy. Run gpedit.msc -> Computer config -> Administrative Templates -> System -> Internet Communication Management -> Internet Communication Settings -> Turn off Automatic Root Certificates Update -> Enabled.
Open local computer certificate manager. (Steps here) Delete the “Microsoft Root Certificate Authority” CA certificate from trusted root certification authorities.
Import the certificate from file (just exported in step 1).
Check the digital signature of vs_installershell.exe from File Properties again. Now the signature should be valid.
Turn on Automatic Root Certificates Update. (Refer to the operation in step 2)
Root cause: Before the error occurs, I just deleted all the certificate from system. But “Microsoft Root Certificate Authority” is required for Windows. If deleted, the system might encounter unknown issue. Turn off and turn on the Automatic Certificate Update and re-import the certificate would reset internal system state, which solve the problem.