title: How to create certificate authority certificate with makecert?
body: <p>I'm trying to create a website which uses SSL with a self-signed certificate.</p>
  
  <p>Here's what I do:</p>
  
  <p>Create authority certificate:</p>
  
  <pre><code>makecert -n "CN=root signing authority" -r -sv root.pvk root.cer
  </code></pre>
  
  <p>Create target certificate</p>
  
  <pre><code>makecert -r -pe -n "CN=localhost" -b 01/01/2012 -e 01/01/2020 -sky exchange localhost.cer -sv localhost.pvk
  </code></pre>
  
  <p>Sign the created certificate</p>
  
  <pre><code>makecert -ic root.cer -iv root.pvk -n "CN=localhost" -sv localhost.pvk -pe -sky exchange localhost.cer
  </code></pre>
  
  <p>Create a certificate with private key inside    </p>
  
  <pre><code>pvk2pfx.exe -pvk localhost.pvk -spc localhost.cer -pfx localhost.pfx
  </code></pre>
  
  <p>Now, I want to use firefox for debugging website. To do that, I need to import the authority root certificate (root.cer) into the trusted certificate list.</p>
  
  <p>However, when I'm trying to do this, I'm getting following error message:</p>
  
  <blockquote>
    <p>This is not a certificate authority certificate, so it can't be imported into  the certificate authority list.</p>
  </blockquote>
  
  <p>I've done something similar with fiddler's authority certificate, and it went fine, which means  that there's a problem with my process of creating authority certificate.</p>
  
  <p>How do I properly create certificate authority certificates?</p>