{"id":562,"date":"2019-07-04T14:06:43","date_gmt":"2019-07-04T06:06:43","guid":{"rendered":"http:\/\/xiaoding.org\/?p=562"},"modified":"2019-07-04T14:06:43","modified_gmt":"2019-07-04T06:06:43","slug":"%e8%a7%a3%e5%86%b3vs_installershell-exe-has-an-invalid-certificate%e9%97%ae%e9%a2%98","status":"publish","type":"post","link":"https:\/\/xiaoding.org\/?p=562","title":{"rendered":"\u89e3\u51b3vs_installershell.exe has an invalid certificate\u95ee\u9898"},"content":{"rendered":"<p>\u95ee\u9898\u63cf\u8ff0\uff1a\u6253\u5f00Visual Studio Installer\u51fa\u73b0\u4e86\u9519\u8bef\uff1avs_installershell.exe has an invalid certificate\uff0c\u7a0b\u5e8f\u7ec8\u6b62\uff0c\u65e0\u6cd5\u542f\u52a8visual studio installer.<\/p>\n<p>\u95ee\u9898\u5206\u6790\uff1a\u68c0\u67e5vs_installer.exe\u7684\u6570\u5b57\u7b7e\u540d\uff0c\u53d1\u73b0SHA1\u7b7e\u7f72\u7684\u7b7e\u540d\u65e0\u6548\u3002\u70b9\u51fb\u8bc1\u4e66\u8be6\u60c5\uff0c\u53d1\u73b0\u662fMicrosoft Root Certificate Authority\u88ab\u540a\u9500\uff0c\u5bfc\u81f4\u6570\u5b57\u7b7e\u540d\u9a8c\u8bc1\u5931\u8d25\uff0c\u6240\u4ee5\u65e0\u6cd5\u542f\u52a8VS Installer\u3002\u4f46\u5728\u8bc1\u4e66\u7ba1\u7406\u5668\u91cc\u68c0\u67e5\u8fd9\u4e2a\u8bc1\u4e66\u6ca1\u6709\u95ee\u9898\u3002<\/p>\n<p>Work around\uff1a\u624b\u52a8\u542f\u52a8vs_installershell.exe\uff08\u6ce8\u610f\u8981\u4ee5\u7ba1\u7406\u5458\u6a21\u5f0f\u542f\u52a8\uff09\uff0c\u4ecd\u7136\u80fd\u6253\u5f00VS Installer\u5e76\u6267\u884cVS\u66f4\u65b0\u3002<\/p>\n<p>\u89e3\u51b3\u65b9\u6cd5\uff1a<\/p>\n<ol>\n<li>\u5bfc\u51faMicrosoft Root Certificate Authority\u8fd9\u4e2a\u6839\u8bc1\u4e66\u5230\u6587\u4ef6\u5907\u4efd\u3002<\/li>\n<li>\u5728\u7ec4\u7b56\u7565\u4e2d\u53d6\u6d88\u8bc1\u4e66\u81ea\u52a8\u66f4\u65b0\u3002gpedit.msc -&gt; \u8ba1\u7b97\u673a\u914d\u7f6e -&gt; \u7ba1\u7406\u6a21\u677f -&gt; \u7cfb\u7edf -&gt; Internet\u901a\u4fe1\u7ba1\u7406 -&gt; Internet\u901a\u4fe1\u8bbe\u7f6e -&gt; \u5173\u95ed\u81ea\u52a8\u6839\u8bc1\u4e66\u66f4\u65b0 -&gt; \u5df2\u542f\u7528<\/li>\n<li>\u5728\u8bc1\u4e66\u7ba1\u7406\u5668\u4e2d\u5220\u9664Microsoft Root Certificate Authority\u8fd9\u4e2a\u6839\u8bc1\u4e66\uff0c\u6ce8\u610f\u8ba1\u7b97\u673a\u8d26\u6237\u548c\u7528\u6237\u8d26\u6237\u91cc\u7684\u8bc1\u4e66\u90fd\u8981\u5220\u6389\u3002\uff08\u65b9\u6cd5\u662f\u8fd0\u884cmmc.exe\u7136\u540e\u9009\u62e9\u6dfb\u52a0\u7ba1\u7406\u5355\u5143\uff0c\u9009\u62e9\u8bc1\u4e66\u540e\u518d\u9009\u62e9\u672c\u5730\u8ba1\u7b97\u673a\u8d26\u6237\uff09<\/li>\n<li>\u5bfc\u5165\u521a\u624d\u5907\u4efd\u7684\u6839\u8bc1\u4e66\u5230\u7cfb\u7edf\u4e2d\u3002<\/li>\n<li>\u5728\u6587\u4ef6\u5c5e\u6027\u4e2d\u67e5\u770bvs_installershell.exe\u7684\u6570\u5b57\u7b7e\u540d\uff0c\u6b64\u65f6\u5e94\u8be5\u7b7e\u540d\u6b63\u5e38\u3002<\/li>\n<li>\u6253\u5f00\u7ec4\u7b56\u7565\u4e2d\u7684\u8bc1\u4e66\u81ea\u52a8\u66f4\u65b0\u3002\uff08\u53c2\u8003\u7b2c2\u6b65\uff0c\u6700\u540e\u9009\u62e9\u5df2\u505c\u7528\u6216\u672a\u914d\u7f6e\u5373\u53ef\uff09<\/li>\n<\/ol>\n<p>\u539f\u56e0\uff1a\u51fa\u73b0\u95ee\u9898\u4e4b\u524d\u81ea\u5df1\u624b\u52a8\u5220\u9664\u4e86\u7cfb\u7edf\u91cc\u6240\u6709\u7684\u6839\u8bc1\u4e66\u3002\u731c\u60f3\u662f\u8fd9\u4e2a\u539f\u56e0\u5bfc\u81f4\u7cfb\u7edf\u7684\u8bc1\u4e66\u9a8c\u8bc1\u51fa\u73b0\u5f02\u5e38\u3002\u800cMicrosoft Root Certificate Authority\u8fd9\u4e2a\u8bc1\u4e66\u662fWindows\u7cfb\u7edf\u9700\u8981\u7684\uff0c\u5982\u679c\u51fa\u73b0\u95ee\u9898\u4f1a\u5bfc\u81f4\u7cfb\u7edf\u7ec4\u4ef6\u5de5\u4f5c\u4e0d\u6b63\u5e38\u3002\u6240\u4ee5\u901a\u8fc7\u505c\u7528\u81ea\u52a8\u66f4\u65b0\u7684\u65b9\u5f0f\uff0c\u624b\u52a8\u5237\u65b0\u4e86\u8fd9\u4e2a\u6839\u8bc1\u4e66\u7684\u72b6\u6001\uff0c\u7cfb\u7edf\u6062\u590d\u6b63\u5e38\u3002<\/p>\n<hr \/>\n<p>English Version:<\/p>\n<p>Error description: An error occurred while opening Visual Studio Installer: &#8220;vs_installershell.exe has an invalid certificate&#8221;. The program terminates afterwards.<\/p>\n<p>Problem analysis: Manually check the digital signature via Properties window, the SHA1 signature is invalid. By clicking &#8220;View certificate&#8221;, it says that the &#8220;Microsoft Root Certificate Authority&#8221; CA certificate is revoked, the signature is invalid. The VS installer cannot be started because the digital signature validation failed.<\/p>\n<p>Work around: Manually start vs_installershell.exe from File Explorer. By default it&#8217;s located in C:\\Program Files(x86)\\Microsoft Visual Studio\\Installer\\. Note that you should run as administrator.<\/p>\n<p>Solution:<\/p>\n<ol>\n<li>Export the CA certificate &#8220;Microsoft Root Certificate Authority&#8221; to file.<\/li>\n<li>Disable Automatic Root Certificate Update in Group policy. Run gpedit.msc -&gt; Computer config -&gt; Administrative Templates -&gt; System -&gt; Internet Communication Management -&gt; Internet Communication Settings -&gt; Turn off Automatic Root Certificates Update -&gt; Enabled.<\/li>\n<li>Open local computer certificate manager. (<a href=\"https:\/\/docs.microsoft.com\/en-us\/dotnet\/framework\/wcf\/feature-details\/how-to-view-certificates-with-the-mmc-snap-in\">Steps here<\/a>) Delete the &#8220;Microsoft Root Certificate Authority&#8221; CA certificate from trusted root certification authorities.<\/li>\n<li>Import the certificate from file (just exported in step 1).<\/li>\n<li>Check the digital signature of vs_installershell.exe from File Properties again. Now the signature should be valid.<\/li>\n<li>Turn on Automatic Root Certificates Update. (Refer to the operation in step 2)<\/li>\n<\/ol>\n<p>Root cause: Before the error occurs, I just deleted all the certificate from system. But &#8220;Microsoft Root Certificate Authority&#8221; 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.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u95ee\u9898\u63cf\u8ff0\uff1a\u6253\u5f00Visual Studio Installer\u51fa\u73b0\u4e86\u9519\u8bef\uff1avs_installershell.e &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/xiaoding.org\/?p=562\" class=\"more-link\">\u7ee7\u7eed\u9605\u8bfb<span class=\"screen-reader-text\">\u201c\u89e3\u51b3vs_installershell.exe has an invalid certificate\u95ee\u9898\u201d<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[36,54],"class_list":["post-562","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-36","tag-54"],"_links":{"self":[{"href":"https:\/\/xiaoding.org\/index.php?rest_route=\/wp\/v2\/posts\/562","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/xiaoding.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xiaoding.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xiaoding.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/xiaoding.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=562"}],"version-history":[{"count":0,"href":"https:\/\/xiaoding.org\/index.php?rest_route=\/wp\/v2\/posts\/562\/revisions"}],"wp:attachment":[{"href":"https:\/\/xiaoding.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=562"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xiaoding.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=562"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xiaoding.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=562"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}