title: Signing .exe with .cer file (what is my certificate's name that signtool.exe is asking for?)
body: <p>I have bought a certificate for my program.</p>
  <p>The website from which I bought it, sent me an <em>.cer</em> file (<em>43-some-really-long-name-9962812767788.cer</em>). No additional files were sent, but I'm almost 100% sure that I don't need anything more.</p>
  <p>When I click on that <em>.cer</em> file, there are information like:</p>
  <ul>
  <li>for: (my data)</li>
  <li>by: Certum Code Signing CA</li>
  <li>expires: 2014-10-24</li>
  </ul>
  <p>All that info seems to be fine.</p>
  <p>I have my <em>.exe</em> file, that I want to sign with it (so when e.g. user will run it as administrator on Windows, he will be able to see the certificate info).</p>
  <p>I found that I can use <em>signtool.exe</em> for it, but it always returns an error that no certificate that meets all criteria was found.</p>
  <p>So, <strong>how to sign my program</strong> (add <em>.cer</em> to my <em>.exe</em>) <strong>using only <em>.cer</em> file</strong> (and all files that I can generate from that <em>.cer</em> file)?</p>
  <p>I have no experience in certificates, .cer and all certificates terminology, so please take that into account while answering (I'm a simple man... ;)</p>
  <hr />
  <p>So far I have installed (I think I did it in right way) .cer at the <strong>Trusted Root Certification Authorities</strong> store on your computer account, according to <a href="http://blogs.msdn.com/b/winsdk/archive/2009/11/13/steps-to-sign-a-file-using-signtool-exe.aspx" rel="nofollow noreferrer">MSDN blog</a>:</p>
  <ol>
  <li>Start-&gt;Run -&gt;MMC </li>
  <li>File -&gt; Add/ Remove Sanp in…</li>
  <li>From the “Add or Remove Snap-ins” window select “Certificates” and click at “Add &gt;”. Select “Computer Account” and then click at “Next”.</li>
  <li>Select “Local Computer” and click at “Finish”.</li>
  <li>Open “Trusted Root Certification Authorities” store at the left pane and click at “Certificates”, shown in Figure 7. Then right click at the right window pane and select “All Task -&gt; Import”.</li>
  <li>Import the above <em>.cer</em> file that you created and install it.</li>
  </ol>
  <p>I indeed see my cer at the MMC now:
  <img src="https://i.stack.imgur.com/uFzAo.png" alt="enter image description here" /></p>
  <p>Still, I don't know how to use signtool.exe in proper way.
  The command:</p>
  <pre><code>Signtool sign /v 
  /t http://timestamp.verisign.com/scripts/timstamp.dll 
  /n CER_NAME_HERE FileToSign.exe
  </code></pre>
  <p>Fails, because <strong>I don't know what is the &quot;CER_NAME_HERE&quot; for my certificate.</strong></p>