{"id":297,"date":"2008-09-12T13:39:25","date_gmt":"2008-09-12T21:39:25","guid":{"rendered":"http:\/\/www.curlybrace.com\/words\/?p=297"},"modified":"2008-09-12T13:48:45","modified_gmt":"2008-09-12T21:48:45","slug":"stripping-an-authenticode-signature","status":"publish","type":"post","link":"https:\/\/www.curlybrace.com\/words\/2008\/09\/stripping-an-authenticode-signature\/","title":{"rendered":"Stripping an Authenticode Signature"},"content":{"rendered":"<p>We needed to modify the resources of an installer and then apply an Authenticode signature.  Unfortunately, it already had a signature on it, and modifying the resources of an executable with a signature results in a corrupted signature.  The Microsoft signing tools cannot recover from this situation, so:<\/p>\n<blockquote><p><b>It is not possible to re-sign a file after modifying its resources.<\/b><\/p><\/blockquote>\n<p>However, it is possible to remove the existing signature, modify the binary, and then apply a new signature.  There are two approaches (which almost certainly amount to the same thing):<\/p>\n<ol>\n<li \/>Use delcert.exe from the <a href=\"http:\/\/forum.xda-developers.com\/showthread.php?p=2508061\">this XDA Forum post<\/a> (note, this is <b>not<\/b> the same as the <a href=\"http:\/\/technet.microsoft.com\/en-us\/sms\/bb676787.aspx\">SMS Server 2003<\/a> tool ccmdelcert.exe, which deletes all SMS certificates on a machine).\n<li \/>Write an application which calls <a href=\"http:\/\/msdn.microsoft.com\/en-us\/library\/ms680214(VS.85).aspx\">ImageRemoveCertificate<\/a>.\n<\/ol>\n","protected":false},"excerpt":{"rendered":"<p>We needed to modify the resources of an installer and then apply an Authenticode signature. Unfortunately, it already had a signature on it, and modifying the resources of an executable with a signature results in a corrupted signature. The Microsoft &hellip; <a href=\"https:\/\/www.curlybrace.com\/words\/2008\/09\/stripping-an-authenticode-signature\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[180,15],"tags":[],"class_list":["post-297","post","type-post","status-publish","format-standard","hentry","category-authenticode","category-technology"],"_links":{"self":[{"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/posts\/297","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/comments?post=297"}],"version-history":[{"count":6,"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/posts\/297\/revisions"}],"predecessor-version":[{"id":303,"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/posts\/297\/revisions\/303"}],"wp:attachment":[{"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/media?parent=297"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/categories?post=297"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.curlybrace.com\/words\/wp-json\/wp\/v2\/tags?post=297"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}