<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Gavin Adams Information Blog &#187; PKI / Certificates</title>
	<atom:link href="http://www.gavinadams.org/blog/category/tech-tips/pki-certificates/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.gavinadams.org/blog</link>
	<description>Musings on hobbies, technology and topics of interest</description>
	<lastBuildDate>Sat, 25 Jun 2011 14:22:21 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>The Cost of SSL &#8211; Selecting Affordable Certificates</title>
		<link>http://www.gavinadams.org/blog/2010/08/09/the-cost-of-ssl-%e2%80%93-selecting-affordable-certificates/</link>
		<comments>http://www.gavinadams.org/blog/2010/08/09/the-cost-of-ssl-%e2%80%93-selecting-affordable-certificates/#comments</comments>
		<pubDate>Tue, 10 Aug 2010 00:49:52 +0000</pubDate>
		<dc:creator>me@gavinadams.org</dc:creator>
				<category><![CDATA[Opinion]]></category>
		<category><![CDATA[PKI / Certificates]]></category>
		<category><![CDATA[SSL]]></category>

		<guid isPermaLink="false">http://www.gavinadams.org/blog/?p=269</guid>
		<description><![CDATA[<p>SSL server certificates are mandatory for finance, e-commerce, and any site that wishes to protect data in transit. Tied to a fully qualified domain name, they also provide a level of non-repudiation. SSL in its more modern incarnation, transport layer security (TLS), is a very effective layer of security.</p> <p>A quick Google search for &#8220;web [...]]]></description>
			<content:encoded><![CDATA[<p>SSL server certificates are mandatory for finance, e-commerce, and any site that wishes to protect data in transit. Tied to a fully qualified domain name, they also provide a level of non-repudiation. SSL in its more modern incarnation, transport layer security (TLS), is a very effective layer of security.</p>
<p>A quick Google search for &#8220;<a href="http://www.google.com/search?q=web+server+certificate">web server certificate</a>&#8221; or &#8220;<a href="http://www.google.com/search?q=ssl+certificate">ssl certificate</a>&#8221; returns companies that sell basic level certificates from USD$50 (GoDaddy) to USD$700 (rest of prices in the article are in USD)  for a standard single domain and single server two year certificate. Granted, these are retail prices, but most systems engineers or security staff only deal with obtaining these certificates once every couple of years.</p>
<p><span id="more-269"></span></p>
<p>A better place to get competitive pricing for the major brands such as VeriSign, Thawte (part of VeriSign), GeoTrust, and RapidSSL (also part of VeriSign, see a trend here?)  is from &#8220;The SSL Store&#8221;.  <a href="https://www.thesslstore.com/brands.aspx">This chart</a> shows the breakdown of various vendors.</p>
<p>So, why do companies fork out $695 to VeriSign when they can get literally the same product for $540 from <a href="https://www.thesslstore.com/verisign/secure-site.aspx">The SSL Store</a>, or as low as $220 for a <a href="https://www.thesslstore.com/geotrust/true-businessid.aspx">GeoTrust issued certificate</a>?</p>
<h3>The Past</h3>
<p>Way back in the mid to late 90s we were provisioning e-commerce sites at a furious pace. A key for order conversion was to prevent any pop-up or alert from hitting the user&#8217;s browser. And with the concerns of credit card information, encryption alerts were<strong> B-A-D</strong>.</p>
<p>Back then, our browser selection was limited. Internet Explorer 4 through 6 were the major players, but there was also Netscape Navigator, Opera, and a bunch of smaller market share browsers. Each browser or operating system had a list of &#8220;trusted&#8221; certificate authorities. Browse to an HTTPS site where the certificate was signed by one of these and you were golden.</p>
<h4>Limited Selection</h4>
<p>Ask anyone from 1997 to 2003 where they got their certificates from and mostly likely it would be VeriSign, Network Solutions, GeoTrust, or maybe even Equifax (now part of GeoTrust). Security staff saw nothing wrong with ponying up $1,300 for a certificate per year. The CFO might take exception, but it was, and is, a cost of doing business.</p>
<h4>Branding</h4>
<p>VeriSign has done a fabulous job in keeping market share. The continue to compete with products, acquisitions of other Certificate Authorities (Thawte, Equifax and RapidSSL), and hammer the market with advertising. If you look at the <a href="https://ssl.netcraft.com/ssl-sample-report/CMatch/certs">market share statistics at Netcraft</a>, you see that higher the trust products (low to high: domain only -&gt; organization validated -&gt; EV) have VeriSign leading the pack.</p>
<p>Another reason VeriSign has such a high market share may be due to Certificate Authority policies and reviews. The due diligence, audits, and processes to perform higher end Extended Validation reviews may require good organizational controls by the Certificate Authorities.</p>
<h3>Does the Issuing Certificate Authority Matter?</h3>
<p>I remember when I first found out about Thawte, the South African Certificate Authority. Certificates at 50% or less than VeriSign and easier organization validation processes. When I first proposed to replace around 30 certificates with Thawte-issued ones, the savings was around $30,000/year. There were concerns about potential browser conflicts or savvy users calling in to complain, so we did the migration slowly for the first batch of load-balanced web front-ends. In the end, there was not a single complaint or issue.</p>
<p>The market has normalized on certificates at varying trust levels:</p>
<table border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td width="319" valign="top">Self-signed</td>
<td width="319" valign="top">No Certificate Authority involved, used for encryption   where non-repudiation is not required</td>
</tr>
<tr>
<td width="319" valign="top">Domain verified</td>
<td width="319" valign="top">Certificate Authority issued to authorized party of a   domain name (e.g. gavinadams.org)</td>
</tr>
<tr>
<td width="319" valign="top">Organization verified</td>
<td width="319" valign="top">Certificate Authority issued to authorized company or   organization (e.g., certificate can be assigned to <em>Newco Inc.</em>)</td>
</tr>
<tr>
<td width="319" valign="top"><a href="http://en.wikipedia.org/wiki/Extended_Validation_Certificate">Extended   Validation Certificate</a></td>
<td width="319" valign="top">Certificate that establishes legal identity to a much higher   degree.  Supported browsers clearly   identify the web site (see <a href="https://www.paypal.com/">PayPal</a> example).</td>
</tr>
</tbody>
</table>
<p>With the exception of self-signed certificates, I contend it doesn&#8217;t matter if a domain or organization verified certificate comes from VeriSign, StartCom, or GoDaddy. And since Extended Validation (EV) certificates require the 20 odd Certificate Authorities to follow the same practices, there few reasons not to choose on price or convenience.</p>
<h3>What to Look for in a Good Certificate Authority Issuer</h3>
<p>Depending upon your needs, who you give your certificate business to depends up:</p>
<ul>
<li>Cost</li>
<li>Locality</li>
<li>Ease of Managing Certificates</li>
<li>Stability</li>
<li>The Extras &#8211; seals, insurance, etc.</li>
</ul>
<h4>Cost</h4>
<p>Not necessarily the top of everyone&#8217;s list, but even Fortune 500 companies like to save costs. Look for Certificate Authorities that use resellers. Do they accept credit cards, company invoices, or other methods of payment? Are the prices competitive?</p>
<h4>Locality</h4>
<p>Does the Certificate Authority have a presence where you are located? If you&#8217;re in Bermuda, it&#8217;s nice to know that a major Certificate Authority, <a href="http://www.quovadisglobal.bm/">QuoVadis</a>, is just down de road. You may find VeriSign has a great North American and European support organization, but isn&#8217;t as well versed in South America.</p>
<h4>Ease of Management</h4>
<p>Personally for me, besides costs, the process for validation and how easy it is to request, download and manage the [re]issuance process is key. Some of the SSL resellers have convoluted sites. Others, such as StartCom&#8217;s StartSSL, take the meaning of the word &#8220;bespoke interface&#8221; to new heights! (But their pricing model is unique and very cost effective).</p>
<p>Play around with various sites and talk to the staff to see just how hard is it to perform the domain or organization validation process. Some resellers have automated processes for domain-only validation while others need to make telephone calls or some other method of authentication.</p>
<h4>Stability</h4>
<p>How long has the Certificate Authority been in business and what is the risk the may suddenly close up shop and turn off the certificate revocation list (CRL) points. Granted the risk is limited to the duration of certificates issues by them, but having to pick a new Certificate Authority would be required.</p>
<h4>The Extras</h4>
<p>These are bits that to me don&#8217;t mean much of anything.  Look at these features a VeriSign Secure Site certificate gets you:</p>
<p><img class="size-full wp-image-272 alignnone" title="vrsn-extras" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/vrsn-extras.png" alt="" width="593" height="260" /></p>
<p>And look at company that uses them but still only uses a &#8220;blue bar&#8221; (domain validation) certificate:</p>
<p><img class="alignnone size-full wp-image-271" title="amazon-cert" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/amazon-cert.png" alt="" width="600" height="500" /></p>
<p>Nowhere on Amazon.com&#8217;s site do they mention VeriSign. Even going into the Help section show&#8217;s limited search results:</p>
<p><img class="alignnone size-full wp-image-273" title="vrsn-help-search" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/vrsn-help-search.png" alt="" width="489" height="137" /></p>
<p>So unless you want to put up a seal and advertise for a Certificate Authority, the only extra that may have value is the insurance&#8211;and most companies will have much better umbrella policies than the CA&#8217;s provide.</p>
<h4>Selecting a Certificate Authority Do&#8217;s and Don&#8217;ts</h4>
<p>Do&#8217;s</p>
<ul>
<li>Buy from a reseller or discount provider &#8211; They either represent top brands, or in the case of GoDaddy, simply have cheap prices. I&#8217;ve used <a href="http://www.namecheap.com/learn/other-services/ssl-certificates.asp">NameCheap</a>, <a href="https://www.thesslstore.com/rapidssl/rapidssl-certificates.aspx">RapidSSL</a> (via reseller), <a href="https://www.thesslstore.com/rapidssl/rapidssl-certificates.aspx">Enom</a>, and <a href="http://www.godaddy.com/ssl/ssl-certificates.aspx?ci=8979">GoDaddy</a>.</li>
<li>Take advantage of multi-year deals and discounts for certificates &#8211; Some providers will give certificates for free if you host a domain with them.</li>
<li>Take advantage of wildcard and subject alternate name (SAN) certificates &#8211; If you are protecting more than a couple domains, a wildcard certificate can be very cost effective.  The same holds true for SAN certificates. Beware the costs as you add additional servers or domain names.</li>
<li>Export and backup the certificate &#8211; Make sure the private key and certificate and exported and stored somewhere safe. Some Certificate Authorities can reissue a certificate, why pay for something that should be good system practice (backup).</li>
</ul>
<p>Don&#8217;ts:</p>
<ul>
<li>Buy directly from a major brand &#8211; I wonder how many people actually do buy directly from VeriSign instead of a reseller.</li>
<li>Break the usage agreement &#8211; If the agreement says you pay for each physical or virtual server the certificate is used on, then pay the provider or look to one that allows multi-server use.</li>
<li>Base selection just on price &#8211; Certain usage patterns may place convenience or the locality of a Certificate Authority over price.</li>
</ul>
<h3>Conclusion</h3>
<p>Hopefully this article has presented some information to help people select an appropriate Certificate Authority and save some money. In looking back upon the hundreds of certificates I&#8217;ve purchased personally and for clients, the prices continue to drive down towards zero. What cost $1,300 in 1997 now costs $9 to $11.</p>
<p>And as prices drop on domain and organization certificates, the browser and Certificate Authorities continue to develop &#8220;new-and-improved&#8221; products at higher prices.  What do the Certificate Authorities have in store for us once the price of an EV certificates have fallen?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gavinadams.org/blog/2010/08/09/the-cost-of-ssl-%e2%80%93-selecting-affordable-certificates/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>StartSSL (StartCom) Certificates on the Citrix NetScaler</title>
		<link>http://www.gavinadams.org/blog/2010/08/02/startssl-startcom-certificates-on-the-citrix-netscaler/</link>
		<comments>http://www.gavinadams.org/blog/2010/08/02/startssl-startcom-certificates-on-the-citrix-netscaler/#comments</comments>
		<pubDate>Mon, 02 Aug 2010 15:45:47 +0000</pubDate>
		<dc:creator>me@gavinadams.org</dc:creator>
				<category><![CDATA[Netscaler]]></category>
		<category><![CDATA[PKI / Certificates]]></category>
		<category><![CDATA[Citrix]]></category>
		<category><![CDATA[NetScaler]]></category>
		<category><![CDATA[SSL]]></category>
		<category><![CDATA[startssl.com]]></category>

		<guid isPermaLink="false">http://www.gavinadams.org/blog/?p=139</guid>
		<description><![CDATA[<p>For a very low cost, it&#8217;s easy to use StartSSL (Startcom) certificates on the Citrix NetScaler product line. This is includes the free NetScaler VPX Express edition. A lot of problems I see with others configuring the NetScaler is related to either self-signed certificates or the use of intermediate (e.g., chained) certificates.</p> <p>Using a Startcom [...]]]></description>
			<content:encoded><![CDATA[<p>For a very low cost, it&#8217;s easy to use <a href="https://www.startssl.com/">StartSSL </a>(Startcom) certificates on the <a href="http://www.citrix.com/English/ps2/products/product.asp?contentID=21679">Citrix NetScaler</a> product line. This is includes the free <a href="https://secureportal.citrix.com/MyCitrix/login/EvalLand.aspx?downloadid=1857216&amp;LandingFrom=1004">NetScaler VPX Express </a>edition. A lot of problems I see with others configuring the NetScaler is related to either self-signed certificates or the use of intermediate (e.g., chained) certificates.</p>
<p>Using a Startcom certificate allows for a trusted CA (no certificate errors) and the NetScaler makes it easy to configure intermediate certificates. We&#8217;ll go through the entire process of creating a certificate usable on the NetScaler. The process is also the same for any chained certificate.</p>
<p><span id="more-139"></span></p>
<h3>The Objective</h3>
<p>We want to secure a connection to virtual server on the NetScaler using SSL for a low cost (free for a 30 day certificate or USD$50 for a two-year certificate). Specifically:</p>
<ul>
<li>Low-cost certificate (or certificates)</li>
<li>Valid for all major browsers or servers that will connect to the NetScaler</li>
<li>Imported and bound to a NetScaler Access Gateway Virtual Server</li>
</ul>
<h3>The Environment</h3>
<p>NetScaler VPX Express with the following configuration:</p>
<ul>
<li>Version 9.2 (9.1 or previous versions should work, maybe with changes to the GUI)</li>
<li>NetScaler IP (NIP) and Mapped IP (MIP) already configured</li>
<li>Commands via GUI</li>
<li>Usable IP address for a virtual server (to test)</li>
<li>Administrative access (nsroot) to the NetScaler</li>
</ul>
<p>Other required items:</p>
<ul>
<li>A valid public domain (required for Startcom certificate issuance)</li>
<li>Workstation or server with OpenSSL tools loaded</li>
<li>Startcom account (class 1 or class 2, meaning you have a client certificate)</li>
</ul>
<h3>Create the Certificate</h3>
<p>Prior to any NetScaler configurations, we&#8217;ll first create the certificate and prep the files for the NetScaler. This include the private key, signing request, then downloading the certificate and the certificate chain (intermediate and root certificates). You can do these same steps from the NetScaler GUI, but I&#8217;ve always found having the OpenSSL toolkit around to be consistent across platforms and useful for troubleshooting problems.</p>
<h4>Private Key and Certificate Signing Request (CSR)</h4>
<p>First create a private key of suitable size (I&#8217;m using an URL from my domain as an example):</p>
<pre>D:\Temp&gt;<strong>openssl genrsa -out test.gavinadams.org.key 2048</strong>
Generating RSA private key, 2048 bit long modulus
.........................................................+++
.................+++
e is 65537 (0x10001)
</pre>
<p>Then create the certificate signing request (CSR):</p>
<pre>D:\Temp&gt;<strong>openssl req -new -key test.gavinadams.org.key -out test.gavinadams.org.csr</strong>
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [AU]:<strong>US</strong>
State or Province Name (full name) [Some-State]:<strong>GA</strong>
Locality Name (eg, city) []:Cumming
Organization Name (eg, company) [Internet Widgits Pty Ltd]:<strong>Not used by Startcom</strong>
Organizational Unit Name (eg, section) []:
Common Name (eg, YOUR name) []:<strong>test.gavinadams.org</strong>
Email Address []:

Please enter the following 'extra' attributes
to be sent with your certificate request
A challenge password []:
An optional company name []:

D:\Temp&gt;<strong>ls test*</strong>
test.gavinadams.org.csr  test.gavinadams.org.key
</pre>
<p>A couple things to note:</p>
<ul>
<li>Organizational name is not used. Common name is not used. Actually, everything but the private key signing portion is thrown out when submitting the request to StartCom. I enter them for consistency though.</li>
<li>There is no password on the private key or CSR, so be careful and protect that key!</li>
</ul>
<h4>Create the Certificate</h4>
<p>Login into the control panel at <a href="https://www.startssl.com/">StartSSL</a> and then go to the <em>StartSSL PKI </em>page. Use the <em>Certificates Wizard </em>to start the process. At different points you will need to copy and paste the contents of the local .csr file and enter the URL for the common name field.</p>
<p>To keep this short I&#8217;ll skip all the steps on the StartCom website and jump the end steps (email me if you&#8217;d like a tutorial on managing StartSSL certificates):</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/retrieve-cert1.png"><img class="alignnone size-full wp-image-237" title="retrieve cert1" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/retrieve-cert1.png" alt="" width="844" height="251" /></a></p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/retrieve-cert2.png"><img class="alignnone size-full wp-image-238" title="retrieve cert2" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/retrieve-cert2.png" alt="" width="564" height="255" /></a></p>
<p><em>Select all </em>and <em>copy </em>the contents to a local text editor and save with the .key file (<strong>test.gavinadams.org.crt</strong> in this example). You can delete the CSR file at this point.</p>
<h3>Download Startcom CA Certificates</h3>
<p>Now download the root and appropriate intermediate certificate. The root is the same for all certificates, but the intermediate will depend upon your class. In this example, it is a class 2 certificate, so I download the<em> Class 2 Intermediate Server CA</em> file.</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ret-int-and-ca.png"><img class="alignnone size-full wp-image-236" title="Retrieve Intermediate and Root CA" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ret-int-and-ca.png" alt="" width="419" height="375" /></a></p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ret-ca.png"><img class="alignnone size-full wp-image-234" title="Retrieve Root CA" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ret-ca.png" alt="" width="308" height="325" /></a></p>
<p>Save the StartCom Root CA  file as <strong>startcom-ca.pem</strong></p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ret-int.png"><img class="alignnone size-full wp-image-235" title="Retrieve Intermediate Server CA (Class 2)" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ret-int.png" alt="" width="470" height="262" /></a></p>
<p>Save the intermediate file as <strong>startcom-sub.class2.server.server.ca.pem</strong></p>
<h3>Install Certificates into the NetScaler</h3>
<p>At this point we have the following files in a temporary directory (the .csr file is not needed but I normally keep them around until I complete housecleaning):</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/filelist.png"><img class="alignnone size-full wp-image-229" title="Files" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/filelist.png" alt="" width="249" height="136" /></a></p>
<p>From the NetScaler configuration page, select <em>SSL-&gt;Certificates</em>, then <em>Add&#8230; </em>from the bottom. Use the GUI to upload the certificate and key along with the root and intermediate CA.</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/test-ga.png"><img class="alignnone size-full wp-image-239" title="test.gavinadams.org" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/test-ga.png" alt="" width="621" height="355" /></a></p>
<p style="padding-left: 30px;"><em>Enabling the notification period is optional. I rely upon my network monitoring to provide notice when a certificate is getting close to expiration.</em></p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ns-root-ca.png"><img class="alignnone size-full wp-image-233" title="Upload Root CA" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ns-root-ca.png" alt="" width="621" height="355" /></a></p>
<p>For this and and the intermediate certificates there is no corresponding private key, so only populate the <em>Certificate File Name </em>field.</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ns-int-ca.png"><img class="alignnone size-full wp-image-232" title="Upload Intermediate Root CA" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/ns-int-ca.png" alt="" width="671" height="355" /></a></p>
<p>Finally, on the NetScaler GUI the SSL window should show the three certificates loaded, along with the default self-signed certificates of the NetScaler:</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/cert-list.png"><img class="alignnone size-full wp-image-227" title="NetScaler Certificate List" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/cert-list.png" alt="" width="1174" height="52" /></a></p>
<p>My CA names are different as this is on a box where they are already loaded, so note the names in the first column when we link the certificate together. Note the expiry date on the intermediate certificate. The intermediate certificates expire much sooner than the root CA. This is why I download the complete chain from StartCom each time I issue a new certificate. Any new intermediate certificates would need to be uploaded.</p>
<h3>Link the Certificates</h3>
<p>Probably the easiest part of the process. I reckon the linking process is simply combining the PEM formatted certificates into a single file. But the GUI makes it easy. First link the certificate we created to the intermediate by right-clicking on the certificate and selecting Link&#8230;</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/test-with-link-meu.png"><img class="alignnone size-full wp-image-240" title="Link certificate to intermediate" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/test-with-link-meu.png" alt="" width="289" height="236" /></a></p>
<p>then select the intermediate certificate and press OK:</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/link-test-to-int.png"><img class="alignnone size-full wp-image-231" title="Link test to intermediate 2" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/link-test-to-int.png" alt="" width="288" height="139" /></a></p>
<p>From the certificate window, select the intermediate certificate, right-click, and link to the Root CA:</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/link-inter-to-root.png"><img class="alignnone size-full wp-image-230" title="Link intermediate to Root CA" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/link-inter-to-root.png" alt="" width="290" height="139" /></a></p>
<h3>Housekeeping</h3>
<p>At this point we have the certificates and private key loaded in the NetScaler.<span style="text-decoration: underline;"> Back everything up at this point!</span> Before I got into the habit of creating a passphrase protected PKCS12 file, I may have misplaced the certificate, or exposed the unprotected key file. I now create a p12/pfx file with the certificate and key in it. Then it gets backup up to a protected site (<a href="http://keepass.info/">Keepass</a> or something similar). finally, the Keepass file gets uploaded to <a href="https://www.dropbox.com/referrals/NTEwNTIyNDk">Dropbox</a> and synced across my multiple workstations.</p>
<pre>D:\Temp&gt;<strong>openssl pkcs12 -export -in test.gavinadams.org.crt -inkey test.gavinadams.org.key -out test.gavinadams.org.p12</strong>
Enter Export Password:
Verifying - Enter Export Password:

D:\Temp&gt;l<strong>s *p12</strong>
test.gavinadams.org.p12
</pre>
<p>This is important for Startcom issued certificates. I love the price for issuing certs: all you can eat for two years for USD$50 (class 2 validation), but if you lose the certificate, it&#8217;s a USD$25 charge to have it added to the CRL.</p>
<h3>Access Gateway Test</h3>
<p>Okay, the certificate has been created, all portions uploaded, and backed up for safe keeping. Now go to <em>Access Gateway-&gt;Virtual Servers </em>and select <em>Add&#8230;</em> from the bottom of the display:</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/create-virt-cert.png"><img class="alignnone size-full wp-image-228" title="Create test.gavinadams.org Virtual Server" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/create-virt-cert.png" alt="" width="817" height="664" /></a></p>
<p>Important parts are the Name, IP address, and certificate selected. If testing, choose an unused IP address and ensure a DNS or hosts file entry exists, then use a browser to hit the site (Firefox 3.6 used here):</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/browser-page.png"><img class="alignnone size-full wp-image-226" title="Hit the site via a browser" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/08/browser-page.png" alt="" width="778" height="385" /></a></p>
<p>You should get a validSSL lock from the log in page. This validates the NetScaler and the certificate is working fine. At this point you can remove the Access Gateway Virtual Server. The certificates are still on the NetScaler and can be bound to other items where SSL is used.</p>
<h3>Summary</h3>
<p>Hopefully not too long of a post. Briefly:</p>
<ol>
<li>Create a Startcom web server certificate</li>
<li>Upload the certificate, private key and Startcom CA certs (root and intermediate) to the NetScaler</li>
<li>Link the certificates on the NetScaler and bind the web server certificate to a Access Gateway Virtual Server</li>
<li>Use a web browser to verify the SSL connection</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://www.gavinadams.org/blog/2010/08/02/startssl-startcom-certificates-on-the-citrix-netscaler/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Replacing vCenter 4.1 SSL Certificate with Active Directory Issued One</title>
		<link>http://www.gavinadams.org/blog/2010/07/14/replacing-vcenter-4-1-ssl-certificate-with-active-directory-issued-one/</link>
		<comments>http://www.gavinadams.org/blog/2010/07/14/replacing-vcenter-4-1-ssl-certificate-with-active-directory-issued-one/#comments</comments>
		<pubDate>Wed, 14 Jul 2010 18:02:36 +0000</pubDate>
		<dc:creator>me@gavinadams.org</dc:creator>
				<category><![CDATA[PKI / Certificates]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Virtualization]]></category>
		<category><![CDATA[VMware]]></category>
		<category><![CDATA[vCenter]]></category>
		<category><![CDATA[vSphere]]></category>

		<guid isPermaLink="false">http://www.gavinadams.org/blog/?p=170</guid>
		<description><![CDATA[<p>This is an update post to reflect the differences in vCenter 4.1 vs the older vCenter 25 install. The older post can be found here.</p> <p>Certain third party products such as XenDesktop respect the expiration date on the vCenter SSL certificate. The vSphere Client doesn&#8217;t mind so much, nor it appears do the vSphere (ESX/ESXi [...]]]></description>
			<content:encoded><![CDATA[<p>This is an update post to reflect the differences in vCenter 4.1 vs the older vCenter 25 install. The older post can be found <a href="http://www.gavinadams.org/blog/2010/04/16/replacing-vicenter-2-5-self-signed-certificate-with-active-directory-issued-one">here</a>.</p>
<p>Certain third party products such as XenDesktop respect the expiration date on the vCenter SSL certificate. The vSphere Client doesn&#8217;t mind so much, nor it appears do the vSphere (ESX/ESXi &#8212; err vSphere Hypervisor) hosts, but when your VDIs suddenly can&#8217;t be reached, it&#8217;s a bad thing. I&#8217;m sure other products may have the same issue.</p>
<p>By default, vCenter will create a self-signed certificate issued to &#8220;<em>VMware default certificate</em>&#8220;. Unlike previous vCenter installs, the certificate is valid for 10 years, but still can cause problems for third parties that want to see the proper common name (e.g., FQDN of the vCenter server).</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/07/vmware-def-cert.png"><img class="alignnone size-full wp-image-177" title="VMware Default Certificate" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/07/vmware-def-cert.png" alt="" width="402" height="506" /></a></p>
<p>In our case, since we&#8217;re not publishing any SSL services to the public and already have a Microsoft Certificate Authority, we can create and sign our own vCenter certificate. And just like the newer version of vCenter, we&#8217;ll set it up for 10 years too.</p>
<p>This can be completed in just under 15 minutes if all the prerequisites are in place. Took me an hour (including this documentation).</p>
<p><span id="more-170"></span></p>
<h2>Environment Summary</h2>
<p>For this process to work, the following assumptions are made:</p>
<ul>
<li>Active Directory installed and Certificate Authority installed (in my case, it&#8217;s on a Windows 2008 Domain Controller with Certificate Authority and Certificate Authority Web Enrollment )</li>
<li>DNS used for vCenter and internal FQDN name</li>
<li>vCenter server part of the domain, Domain Admin access to it</li>
<li>vCenter installed with local database (SQL Server 2005 Express) and using SYSTEM account &#8211; People commented on my <a href="http://www.gavinadams.org/blog/2010/04/16/replacing-vicenter-2-5-self-signed-certificate-with-active-directory-issued-one">previous related post</a> about other steps required for database connectivity</li>
<li>Using the included web services that comes with vCenter (IIS users on your own for this one)</li>
</ul>
<p>To test, we&#8217;ll use a browser from a workstation and the XenDesktop DDC to validate connection (make sure the root CA certificate is added to the Trusted Roots for the Computer Account on each test and production server)</p>
<h2>Prep vCenter</h2>
<p>Since vCenter 4.1 now requires a 64-Bit Operating System (Server 2008 R2 Standard in my case), we&#8217;ll download the OpenSSL for Windows 64-Bit version.</p>
<p>Download <a href="http://www.slproweb.com/products/Win32OpenSSL.html">OpenSSL for Windows</a> (binary for the 64-bit version  v1.0.0a is <a href="http://www.slproweb.com/download/Win64OpenSSL-1_0_0a.exe">here</a>) You may have to install the Visual C++ 2008 redistributable package first.</p>
<p>Verify the private key exists in: <strong>C:\Users\All Users\VMware\VMware VirtualCenter\SSL\rui.key</strong> (you will need to change permissions to allow your user account to access this directory and files)</p>
<p>Copy  all the files in<strong> C:\Users\All Users\VMware\VMware VirtualCenter\SSL</strong> to a temporary location such as  <strong>c:\temp\vcenter\oldssl</strong> (create if needed)</p>
<p>Open a command shell and go to <strong>c:\temp\vcenter\newssl</strong> (create if needed)</p>
<p>Generate the new RSA private key (2048 bit) and the certificate request (most important is that the common name must be the FQDN of the server). For the CSR, I normally use the common name value.csr, but since we&#8217;re working with rui.*, we&#8217;ll use that here too:</p>
<pre>C:\temp\vcenter\newssl&gt;c:\OpenSSL-Win64\bin\openssl.exe req -newkey rsa:2048 -keyout rui.key -nodes -days 3650 -out rui.csr
Loading 'screen' into random state - done
Generating a 2048 bit RSA private key
.............................+++
......................................+++
writing new private key to 'rui.key'
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [AU]:<strong>US</strong>
State or Province Name (full name) [Some-State]:<strong>Georgia</strong>
Locality Name (eg, city) []:<strong>Cumming</strong>
Organization Name (eg, company) [Internet Widgits Pty Ltd]:<strong>Gavin Adams</strong>
Organizational Unit Name (eg, section) []:
Common Name (eg, YOUR name) []:<strong>vcenter.peanuts.local</strong>
Email Address []:
Please enter the following 'extra' attributes
to be sent with your certificate request
A challenge password []:
An optional company name []:

C:\temp\vcenter\newssl&gt;<strong>dir</strong>
Volume in drive C has no label.
Volume Serial Number is 204A-99B1
Directory of C:\temp\vcenter\newssl
04/16/2010  03:50 PM    &lt;DIR&gt;          .
04/16/2010  03:50 PM    &lt;DIR&gt;          ..
04/16/2010  03:50 PM             1,024 .rnd
04/16/2010  03:49 PM             1,675 privkey.pem
04/16/2010  03:50 PM             1,679 rui.key
04/16/2010  03:50 PM             1,005 rui.csr
</pre>
<p>From the vCenter system, browse to the certsrv URL for your Active Directory Certificate Authority (normally https://dcname/certsrv and probably will require a valid Active Directory user):</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/04/vcu-1.png"><img class="size-full wp-image-153 alignnone" title="vcu-1" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/04/vcu-1.png" alt="" width="474" height="295" /></a></p>
<p>Select Request a certificate, advanced certificate request, and then <em>Submit a certificate using base-64&#8230;.</em> Past the entire contents of the <strong>rui.csr </strong>(open in Notepad, select all &#8212; it will be all on one line, but a CTRL-A CTRL-C will do fine) in the Saved Request box, select <em>Web Server </em>for Certificate template:</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/04/vcu-2.png"><img class="alignnone size-full wp-image-154" title="vcu-2" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/04/vcu-2.png" alt="" width="487" height="515" /></a></p>
<p>At this point the certificate will be signed. On the next page select <em>Base 64 encoded</em> then  <em>Download certificate</em> and save as <strong>rui.crt</strong> in <strong>c:\temp\vcenter\newssl</strong></p>
<p>From the private key and certificate, create the PFX fie:</p>
<pre>C:\temp\vcenter\newssl&gt;c:\OpenSSL-Win64\bin\openssl pkcs12 -export -in rui.crt -inkey rui.key -name rui -passout pass:testpassword -out rui.pfx</pre>
<p>Stop the following services:</p>
<blockquote><p>VMware VirtualCenter Management Webservices<br />
VMware VirtualCenter Server</p></blockquote>
<p>Copy  all the files in the newssl directory to :<strong> </strong><strong>C:\Users\All Users\VMware\VMware VirtualCenter\SSL</strong><strong>\</strong> replacing the existing ones. Don&#8217;t worry, we backed these up.</p>
<p>Now restart the services in this order (unsure if it matters):</p>
<blockquote><p>VMware VirtualCenter Server<br />
VMware VirtualCenter Management Webservices</p></blockquote>
<p>Use browser and navigate to the URL of the vCenter (e.g.,  <em>https://vcenter.peanuts.local</em>) and verify the certificate is valid. Open the vSphere client and verify all looks okay. After restarting the services, you will need  to reconnect to the ESX / ESXi hosts and re-authenticate with root credentials on each server. This is because the SSL trust between the two has changed and a new trust relationship needs to be established. Another reason for a longer term certificate!</p>
<h2>Problems and Resolution</h2>
<p>I&#8217;ll update the post with corrections, but with different configurations, we may run into different issues.</p>
<table border="0">
<caption><strong>Observed Problems and Resolutions</strong></caption>
<tbody>
<tr>
<td style="text-align: center;">Problem</td>
<td style="text-align: center;">Resolution</td>
</tr>
<tr>
<td>Web Service won&#8217;t restart with error<br />
One thing after this the webservice won&#8217;t start.<br />
in the log I found following error:<br />
vmware RSA_padding_check_PKCS1_type_2:block type is not 02</td>
<td>See VMware KB article: <a rel="nofollow" href="http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&amp;cmd=displayKC&amp;externalId=1003070">http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&amp;cmd=displayKC&amp;externalId=1003070</a></p>
<p>May require account password for database (assuming db other than SQL Server express)</td>
</tr>
</tbody>
</table>
]]></content:encoded>
			<wfw:commentRss>http://www.gavinadams.org/blog/2010/07/14/replacing-vcenter-4-1-ssl-certificate-with-active-directory-issued-one/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>Replacing vCenter 2.5 Self-Signed Certificate with Active Directory Issued One</title>
		<link>http://www.gavinadams.org/blog/2010/04/16/replacing-vicenter-2-5-self-signed-certificate-with-active-directory-issued-one/</link>
		<comments>http://www.gavinadams.org/blog/2010/04/16/replacing-vicenter-2-5-self-signed-certificate-with-active-directory-issued-one/#comments</comments>
		<pubDate>Fri, 16 Apr 2010 21:27:48 +0000</pubDate>
		<dc:creator>me@gavinadams.org</dc:creator>
				<category><![CDATA[PKI / Certificates]]></category>
		<category><![CDATA[VMware]]></category>
		<category><![CDATA[Active Directory]]></category>
		<category><![CDATA[vCenter]]></category>

		<guid isPermaLink="false">http://www.gavinadams.org/blog/?p=145</guid>
		<description><![CDATA[<p>Certain third party products such as XenDesktop respect the expiration date on the vCenter SSL certificate. The vSphere Client doesn&#8217;t mind so much, nor it appears does the ESX hosts, but when your VDIs suddenly can&#8217;t be reached, it&#8217;s a bad thing.</p> <p>By default, vCenter will create a self-signed certificate with just the host name. [...]]]></description>
			<content:encoded><![CDATA[<p>Certain third party products such as XenDesktop respect the expiration date on the vCenter SSL certificate. The vSphere Client doesn&#8217;t mind so much, nor it appears does the ESX hosts, but when your VDIs suddenly can&#8217;t be reached, it&#8217;s a bad thing.</p>
<p>By default, vCenter will create a self-signed certificate with just the host name. In our case, since we&#8217;re not publishing any SSL services to the public and already have a Microsoft Certificate Authority, we can create and sign our own vCenter certificate. And just like the newer version of vCenter, we&#8217;ll set it up for 10 years too.</p>
<p>This can be completed in just under 15 minutes if all the prerequisites are in place. Took me an hour (including this documentation).</p>
<p><span id="more-145"></span></p>
<h3>Environment Summary</h3>
<p>For this process to work, the following assumptions are made:</p>
<ul>
<li>Active Directory installed and Certificate Authority installed (in my case, it&#8217;s on a Windows 2008 Domain Controller with Certificate Authority and Certificate Authority Web Enrollment )</li>
<li>DNS used for vCenter and internal FQDN name</li>
<li>vCenter server part of the domain, Domain Admin access to it</li>
<li>Using the included web services that comes with vCenter (IIS users on your own for this one)</li>
</ul>
<p>To test, we&#8217;ll use a browser from a workstation and the XenDesktop DDC to validate connection (make sure the root CA certificate is added to the Trusted Roots for the Computer Account on each test and production server)</p>
<h3>Prep vCenter</h3>
<p>Download OpenSSL for Windows (binaries can be found at: <a href="http://www.slproweb.com/products/Win32OpenSSL.html">http://www.slproweb.com/products/Win32OpenSSL.html</a>) . You may have to install the 2008 redistributable package first.</p>
<p>Open a command shell and go to <strong>c:\temp\vcenter\newssl</strong> (create if needed)</p>
<p>Verify the private key exists in: <strong>C:\Documents and Settings\All Users\Application Data\VMware\VMware VirtualCenter\SSL\rui.key</strong></p>
<p>Copy all the files in<strong> C:\Documents and Settings\All Users\Application Data\VMware\VMware VirtualCenter\SSL</strong> to a temporary location such as <strong>c:\temp\vcenter\oldssl</strong> (create if needed)</p>
<p>Generate the new RSA private key (2048 bit) and the certificate request (most important is that the common name must be the FQDN of the server). For the CSR, I normally use the common name value.csr, but since we&#8217;re working with rui.*, we&#8217;ll use that here too:</p>
<pre>C:\temp\vcenter\newssl&gt;c:\OpenSSL\bin\openssl.exe req -newkey rsa:2048 -keyout rui.key -nodes -days 3650 -out rui.csr
Loading 'screen' into random state - done
Generating a 2048 bit RSA private key
.............................+++
......................................+++
writing new private key to 'rui.key'
-----
You are about to be asked to enter information that will be incorporated
into your certificate request.
What you are about to enter is what is called a Distinguished Name or a DN.
There are quite a few fields but you can leave some blank
For some fields there will be a default value,
If you enter '.', the field will be left blank.
-----
Country Name (2 letter code) [AU]:<strong>US</strong>
State or Province Name (full name) [Some-State]:<strong>Georgia</strong>
Locality Name (eg, city) []:Cumming
Organization Name (eg, company) [Internet Widgits Pty Ltd]:<strong>Gavin Adams</strong>
Organizational Unit Name (eg, section) []:
Common Name (eg, YOUR name) []:<strong>vcenter.peanuts.local</strong>
Email Address []:
Please enter the following 'extra' attributes
to be sent with your certificate request
A challenge password []:
An optional company name []:

C:\temp\vcenter\newssl&gt;<strong>dir</strong>
Volume in drive C has no label.
Volume Serial Number is 204A-99B1
Directory of C:\temp\vcenter\newssl
04/16/2010  03:50 PM    &lt;DIR&gt;          .
04/16/2010  03:50 PM    &lt;DIR&gt;          ..
04/16/2010  03:50 PM             1,024 .rnd
04/16/2010  03:49 PM             1,675 privkey.pem
04/16/2010  03:50 PM             1,679 rui.key
04/16/2010  03:50 PM             1,005 rui.csr
</pre>
<p>From the vCenter system, browse to the certsrv URL for your Active Directory Certificate Authority:</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/04/vcu-1.png"><img class="size-full wp-image-153 alignnone" title="vcu-1" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/04/vcu-1.png" alt="" width="474" height="295" /></a></p>
<p>Select Request a certificate, advanced certificate request, and then Submit a certificate using base-64&#8230;. Past the entire contents of the CSR (open in Notepad) in the Saved Request box, select Web Server for Certificate template:</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/04/vcu-2.png"><img class="alignnone size-full wp-image-154" title="vcu-2" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/04/vcu-2.png" alt="" width="487" height="515" /></a></p>
<p>At this point the certificate will be signed. On the next page select <em>Base 64 encoded</em> then  <em>Download certificate</em> and save as <strong>rui.crt</strong> in <strong>c:\temp\vcenter\newssl</strong></p>
<p>From the private key and certificate, create the PFX fie:</p>
<pre>C:\temp\vcenter\newssl&gt;c:\openssl\bin\openssl pkcs12 -export -in rui.crt -inkey rui.key -name rui -passout pass:testpassword -out rui.pfx</pre>
<p>Stop the following services:</p>
<blockquote><p>VMware VirtualCenter Management Webservices<br />
VMware VirtualCenter Server</p></blockquote>
<p>Copy  all the files in the newssl directory to :<strong> C:\Documents and Settings\All Users\Application Data\VMware\VMware VirtualCenter\SSL\</strong> replacing the existing ones. Don&#8217;t worry, we backed these up.</p>
<p>Now restart the services in this order (unsure if it matters):</p>
<blockquote><p>VMware VirtualCenter Server<br />
VMware VirtualCenter Management Webservices</p></blockquote>
<p>Use browser and navigate to the URL of the vCenter (e.g.,  <em>https://vcenter.peanuts.local</em>) and verify the certificate is valid. Open the vSphere client and verify all looks okay. After restarting the services, you will need  to reconnect to the ESX / ESXi hosts and re-authenticate with root credentials on each server. This is because the SSL trust between the two has changed and a new trust relationship needs to be established. Another reason for a longer term certificate!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gavinadams.org/blog/2010/04/16/replacing-vicenter-2-5-self-signed-certificate-with-active-directory-issued-one/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Snow Leopard Certificate Sillyness</title>
		<link>http://www.gavinadams.org/blog/2010/01/05/snow-leopard-certificate-sillyness/</link>
		<comments>http://www.gavinadams.org/blog/2010/01/05/snow-leopard-certificate-sillyness/#comments</comments>
		<pubDate>Tue, 05 Jan 2010 22:10:46 +0000</pubDate>
		<dc:creator>me@gavinadams.org</dc:creator>
				<category><![CDATA[OS X]]></category>
		<category><![CDATA[PKI / Certificates]]></category>
		<category><![CDATA[pkcs12]]></category>
		<category><![CDATA[startssl.com]]></category>

		<guid isPermaLink="false">http://www.gavinadams.org/blog/?p=132</guid>
		<description><![CDATA[<p>I love OS X and every iteration has gotten better and better. But every once in a while tasks that should be simple&#8211;aren&#8217;t. Take the case of trying to add a S/MIME certificate to the Keychain.</p> <p>In the past, simply double-clicking on the .p12 file would prompt for the passphrase and import it into the [...]]]></description>
			<content:encoded><![CDATA[<p>I love OS X and every iteration has gotten better and better. But every once in a while tasks that should be simple&#8211;aren&#8217;t. Take the case of trying to add a S/MIME certificate to the Keychain.</p>
<p>In the past, simply double-clicking on the .p12 file would prompt for the passphrase and import it into the login chain. After getting my certificate issued by StartSSL and stored in Firefox, I exported the certificate and private key, set a passphrase, double-clicked, and&#8230;.</p>
<p><a href="http://www.gavinadams.org/blog/wp-content/uploads/2010/01/hate-the-keychain.png"><img class="aligncenter size-full wp-image-133" title="hate-the-keychain" src="http://www.gavinadams.org/blog/wp-content/uploads/2010/01/hate-the-keychain.png" alt="" width="750" height="385" /></a></p>
<p><strong>An error has occurred. Unable to import an item. The contents of this item cannot be retrieved. You failed to provide the necessary administrator authorization.</strong> <em>(Added so the search engines will pick this up)</em></p>
<p><span id="more-132"></span>And so the battle commenced. There really isn&#8217;t a lot out there discussing when Keychain Access fails. The closest similar discussion was by Midori Green (email thread <a href="http://www.mail-archive.com/openssl-users@openssl.org/msg59442.html">here</a>). The error was different, but it was the same attempt to import a PKCS12 file.</p>
<p>I tried using openssl to rearrange the certificates in the file (after exporting into PEM format), tried adding/removing/changing the private key passphrase, import/export from a Windows machine in .PFX format, and even trying to recreate the PKCS12 file from its&#8217; constituent parts.</p>
<p>Luckily, I ran across this post on <a href="http://krypted.com/mac-os-x/basic-pkcs12-management-with-security/">krypted.com</a> that mentioned the CLI command <em>security</em>. After placing the exported .p12 file (from Firefox) in a directory and launching terminal, I was able to use the command:</p>
<pre>linus:gadams$ <strong>security import startssl-smime-cert.p12 -f pkcs12 ~/Library/Keychains/login.keychain</strong>
1 identity imported.
2 certificates imported.
</pre>
<p>And <em>bam!</em>, the certificate loaded. Composing a new message in Mail.app showed the signing and encryption boxes. Although I still get invalid signatures when sending rich text format messages, plain text are properly getting signed.</p>
<p>I am curious exactly what command is executed when you double-click on a certificate file. I assume the <em>Keychain access </em>application makes underly calls to <em>security</em>, but I&#8217;d like to be able to trace the steps it takes.</p>
<p>Side note, I&#8217;m going to do an opinion piece of certificate authorities in general and digital certificates, SSL, S/MIME, and all that rot. There are some great options for small companies and individuals to get certificates at a cheap or free price. No Verisign or GTE Cybertrust (err Verizon Business) $$$$$ prices need apply!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gavinadams.org/blog/2010/01/05/snow-leopard-certificate-sillyness/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>

