<?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>Heimdal &#187; hx509</title>
	<atom:link href="http://www.h5l.org/blog/index.php/category/heimdal/hx509/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.h5l.org/blog</link>
	<description>The Kerberos 5, PKIX, CMS, GSS-API, SPNEGO, NTLM, Digest-MD5 and, SASL implementation</description>
	<lastBuildDate>Sat, 21 Nov 2009 16:21:19 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Support for ECDSA and ECDH in PK-INIT</title>
		<link>http://www.h5l.org/blog/index.php/2009/02/support-for-ecdsa-and-ecdh-in-pk-init/</link>
		<comments>http://www.h5l.org/blog/index.php/2009/02/support-for-ecdsa-and-ecdh-in-pk-init/#comments</comments>
		<pubDate>Sat, 14 Feb 2009 20:31:49 +0000</pubDate>
		<dc:creator>lha</dc:creator>
				<category><![CDATA[Heimdal]]></category>
		<category><![CDATA[hx509]]></category>

		<guid isPermaLink="false">http://www.h5l.org/blog/?p=209</guid>
		<description><![CDATA[Heimdal now support support for ECDSA (Elliptic curve, signature mode) and ECDH (Elliptic curve, key exchange mode) when compiled with OpenSSL, no hcrypto support yet. Using ECDSA is turned on when using EC certificates, both the signature verification and CMS is done using EC certificate.
ECDH is turned used when using ECDSA, so also its also used when using EC certificates [...]]]></description>
			<content:encoded><![CDATA[<p>Heimdal now support support for ECDSA (Elliptic curve, signature mode) and ECDH (Elliptic curve, key exchange mode) when compiled with OpenSSL, no hcrypto support yet. Using ECDSA is turned on when using EC certificates, both the signature verification and CMS is done using EC certificate.</p>
<p>ECDH is turned used when using ECDSA, so also its also used when using EC certificates on the client. There is missing negotiation of EC curves, so the code is not future safe, but its something that we&#8217;ll add in the future.  Part of the regression test now uses the EC certificate. hxtool needs support for generating EC keys and exporting the SubjectPublicKeyInfo before its can sign certificates, neither of them too hard.</p>
<p>Too much of the OpenSSL EC implementation is hidden, so right now its not possible to load plugins. So no support for PKCS11 or Keychain based private keys.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.h5l.org/blog/index.php/2009/02/support-for-ecdsa-and-ecdh-in-pk-init/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>hx509 and hcrypto</title>
		<link>http://www.h5l.org/blog/index.php/2007/01/hx509-and-hcrypto/</link>
		<comments>http://www.h5l.org/blog/index.php/2007/01/hx509-and-hcrypto/#comments</comments>
		<pubDate>Thu, 11 Jan 2007 22:00:00 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[hx509]]></category>

		<guid isPermaLink="false">http://blogs.su.se/lha/Heimdal/lha-ON5zPSCP</guid>
		<description><![CDATA[hx509 and hcrypto have both in the last two months been given an overhaul and are now self bootstraping. Needless to say, neither of the two packages are perfect, but we are getting to closer to same level of functionality as the rest of the Heimdal suite of applications and libraries.
hxtool can now both read [...]]]></description>
			<content:encoded><![CDATA[<p>hx509 and hcrypto have both in the last two months been given an overhaul and are now self bootstraping. Needless to say, neither of the two packages are perfect, but we are getting to closer to same level of functionality as the rest of the Heimdal suite of applications and libraries.</p>
<p>hxtool can now both read and create PEM and PKCS11 files containing both certificates and private keys. Neither of formats will end up containing encrypted keys (ie shrouded PKCS8 keys), so that is a feature that must be added.</p>
<p>And talking about private keys, hcrypto now uses RSA key blinding and CRT for private key operations, makes quite a lot difference in performance and security. I also added RSA key generation, that is really the last two missing bits that makes hcrypto useful.</p>
<p>The coolest feature is also the most basic in the X.509 world. libhx509 and hxtool now can print certificates. It would be boastful to call is a CA software because some important tools are not there yet, for example a CRL and OSCP generation tools and certificate store handling.</p>
<p>There is two reason why I wrote this extension to hx509. First reason was I wanted a simple way to setup a PK-INIT realm and using OpenSSL as a CA only causes pain for most users, its very hard to get the generated certificates right and openssl lets you get away with it too. Second reason is that I needed a simple way to generate certificates for another part of Heimdal, kca (more about that later).</p>
<p>What hxtool do for us then ? It will let you issue certificates with a simple interface using default templates.</p>
<p>To generate a CA certifiate with RSA key that is valid for 10 years, this is the command you would use.</p>
<p>hxtool issue-certificate \<br />
    &#8211;self-signed \<br />
    &#8211;issue-ca \<br />
    &#8211;generate-key=rsa \<br />
    &#8211;subject=&#8221;CN=CA,DC=h5l,DC=se&#8221; \<br />
    &#8211;lifetime=10years \<br />
    &#8211;certificate=&#8221;FILE:ca.pem&#8221;</p>
<p>Now you have a CA certificate with its private key in the PEM file ca.pem. Now you say, what makes this hx509 so much simpler to use then OpenSSL. The answer is the default values and builtin profiles, let take the example with the KDC PK-INIT certificate. It needs to have this EKU (extended key usage) and a special SAN (Subject Alternative Name) for PK-INIT. hxtool will help you generate that certificate with some simple command options, it wont give you total control over the certificate creation process, but for most users that is not really interesting, they just want to have certificates.</p>
<p>hxtool issue-certificate \<br />
    &#8211;ca-certificate=FILE:ca.pem \<br />
    &#8211;generate-key=rsa \<br />
    &#8211;type=&#8221;pkinit-kdc&#8221; \<br />
    &#8211;pk-init-principal=&#8221;krbtgt/H5L.SE@H5L.SE&#8221; \<br />
    &#8211;subject=&#8221;uid=kdc,DC=h5l,DC=se&#8221; \<br />
    &#8211;certificate=&#8221;FILE:kdc.pem&#8221;</p>
<p>Writing a certificate issuing code when you have a X509 verifier, a crypto library and a sane ASN.1 compiler is very simple. It took me about 3 days from no code to a somewhat working software, now, 12 days later while also working with other thing, its good enough to tell people about it.</p>
<p>Next item will be to write a sane manual how to use this software. Since hxtool is such a small tool the manual will be short too, it will be another texinfo manual about how to use hxtool to serve your basic CA needs. Creating a CA and issueing certificates to user and services.</p>
<p>There will always be missing functionallity to hx509, the PKIX people have started to write standard too long ago for me to catch up.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.h5l.org/blog/index.php/2007/01/hx509-and-hcrypto/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PK-INIT and hx509</title>
		<link>http://www.h5l.org/blog/index.php/2006/04/pk-init-and-hx509/</link>
		<comments>http://www.h5l.org/blog/index.php/2006/04/pk-init-and-hx509/#comments</comments>
		<pubDate>Sun, 30 Apr 2006 22:00:00 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Heimdal]]></category>
		<category><![CDATA[hx509]]></category>

		<guid isPermaLink="false">http://blogs.su.se/lha/Heimdal/lha-mewSeL41</guid>
		<description><![CDATA[Last two weeks I&#8217;ve cleaned up the the final big issues with PK-INIT code. Soon usb dongles will arrive and we can do testing for other people then me. There is only really one issue left with PK-INIT code, more error message must be generated and the correct error code must be returned.
The other part [...]]]></description>
			<content:encoded><![CDATA[<p>Last two weeks I&#8217;ve cleaned up the the final big issues with PK-INIT code. Soon usb dongles will arrive and we can do testing for other people then me. There is only really one issue left with PK-INIT code, more error message must be generated and the correct error code must be returned.</p>
<p>The other part of PK-INIT is the hx509 library that I&#8217;ve been tweeking on last last year or so when I have had time. On it there is two major issues left. First there must be error string generated. There is currect two error codes, but that doesn&#8217;t help you if you get the &#8220;signature incorrect&#8221; error-code. What signature, on the CMS SignedData message, the signing certificate, or maybe some certificates in the chain. The second issue is that there is no policy mappings yet, that that is a major flaw when verifying chains that go though bridge-ca&#8217;s. I find the policy mappings to be badly written in the PKIX (rfc3280), its spread out over then whole document and no clear view how to implement it, or even how to use it!</p>
<p>Anyway, the last week I add proxy certificate support to hx509, so now Heimdal can use proxy certificates generated by the grid folks again.</p>
<p>I&#8217;ve also written more tests for the Heimdal regression suite. Both for the hx509 library and Heimdal as a system. Now as part of &#8220;make check&#8221; a kerberos database is created, kdc started, kinit run (both using Encrypted Timestamp pre-authentication and PK-INIT) and , as a client is authenticated (testing both mutual authentication and not) to a application server using krb5_mk_req API (ap-req/ap-rep).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.h5l.org/blog/index.php/2006/04/pk-init-and-hx509/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cache iteration, PK-INIT, and documentation changes.</title>
		<link>http://www.h5l.org/blog/index.php/2005/10/cache-iteration-pk-init-and-documentation-changes/</link>
		<comments>http://www.h5l.org/blog/index.php/2005/10/cache-iteration-pk-init-and-documentation-changes/#comments</comments>
		<pubDate>Fri, 21 Oct 2005 22:00:00 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Heimdal]]></category>
		<category><![CDATA[hx509]]></category>

		<guid isPermaLink="false">http://blogs.su.se/lha/Heimdal/1129911904771</guid>
		<description><![CDATA[Lately there have been lots minor changes to the tree, many of them
documentation changes. Feedback how to improve the documentation, both
the info documentation and the manual pages are much appreciated. I
especially like comments that some text in the documentation is hard to understand. Its so
easy for me to become blind to bad text when I&#8217;ve [...]]]></description>
			<content:encoded><![CDATA[<p>Lately there have been lots minor changes to the tree, many of them<br />
documentation changes. Feedback how to improve the documentation, both<br />
the info documentation and the manual pages are much appreciated. I<br />
especially like comments that some text in the documentation is hard to understand. Its so<br />
easy for me to become blind to bad text when I&#8217;ve written both the code<br />
and text. The brain fills in the missing bits and I don&#8217;t see the problems.</p>
<p>Of the latest changes I like the the credential cache iteration code the<br />
most. It allows the user to list all caches available.  It only works<br />
for API and MEMORY caches though, some day there will be support for<br />
KCM and FILE caches.</p>
<p> </p>
<pre>$ klist --list-caches
Principal      Cache name     Status
lha@SU.SE        0              Valid
lha@E.KTH.SE     1              Valid</pre>
<p> </p>
<p>This glued together with support in GSS-API&#8217;s <strong>gss_aquire_cred</strong><br />
allow applications to select the source principal is a bliss. I&#8217;ve<br />
modified push (the pop-client included in Heimdal) to use SASL and<br />
now I can tell is to use <strong>lha@KTH.SE</strong> when talking to<br />
<strong>mail1.kth.se</strong> even though the current selected cache is<br />
<strong>lha@SU.SE</strong>. No more kswitch (MIT application for API credential<br />
cache) or using wrapper shellscripts setting the KRB5CCNAME<br />
enviroment variable. It makes my life much easier, no more wondering<br />
why I&#8217;ve not received any mail for whole day just because I selected<br />
the wrong credential at the begining of the day.</p>
<p>The outstanding question is how to handle support for automatic<br />
selection of credentials. What parameters can you accept from the<br />
server ? How should you store the local configuration ? How should the<br />
user influence the selection ?  How to avoid privacy issues (avoid<br />
doing TGS-REQ to KDC that you don&#8217;t want to expose your actions too) ?<br />
These are all very interesting issues, but causes a lot of squishy<br />
noise when you hits your head agaist the wall.</p>
<p>I&#8217;ve also cleaned up DH support in PK-INIT, now it will check the<br />
parameters choosen by the client, and there is a moduli files that<br />
allows the administrator to add new group parameters. I also wrote a<br />
fix for the PK-INIT-09 windows problem with binding the answer to the<br />
request as presented by <a><br />
href=&#8221;http://www.cis.upenn.edu/~scedrov/&#8221;&gt;Andrew Scedrow et al</a> at<br />
IETF63 in Paris.  The fix from Microsoft can be found <a><br />
href=&#8221;http://www.microsoft.com/technet/security/bulletin/MS05-042.mspx&#8221;&gt;<br />
here</a>.</p>
<p>Now there is only parts of the KDC certificate verification code<br />
missing and documentation on how to use PK-INIT that is missing before<br />
I&#8217;m happy enough to make a release including PK-INIT. There are of<br />
course major issues left, like PAM support, certificate handling and<br />
CMS support, but those can be cleaned up later. There is of course the<br />
rewrite of the ASN.1 compiler, but that seems to be the default state<br />
of ASN.1 compilers so I&#8217;m not too worried about that.</p>
<p>Technorati tag: <a href="http://technorati.com/tag/Heimdal">Heimdal</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.h5l.org/blog/index.php/2005/10/cache-iteration-pk-init-and-documentation-changes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>hx509 &#8211; X.509 and CMS for Heimdal</title>
		<link>http://www.h5l.org/blog/index.php/2005/07/hx509-x509-and-cms-for-heimdal/</link>
		<comments>http://www.h5l.org/blog/index.php/2005/07/hx509-x509-and-cms-for-heimdal/#comments</comments>
		<pubDate>Mon, 25 Jul 2005 22:00:00 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[hx509]]></category>

		<guid isPermaLink="false">http://blogs.su.se/lha/Heimdal/1122302833158</guid>
		<description><![CDATA[This morning I commited a X.509 and CMS implementation to the CVS repository that Heimdal uses. Its not added to Heimdal yet, for that it needs more work. The implementation is based on the CMS framework from the PK-INIT code in Heimdal and uses the ASN.1 library from Heimdal. This, together with the PK-INIT and [...]]]></description>
			<content:encoded><![CDATA[<p>This morning I commited a X.509 and CMS implementation to the CVS repository that Heimdal uses. Its not added to Heimdal yet, for that it needs more work. The implementation is based on the CMS framework from the PK-INIT code in Heimdal and uses the ASN.1 library from Heimdal. This, together with the PK-INIT and SPNEGO, have been the driving force behind the update of the ASN.1 library.</p>
<p>It diffrent from the other common free implementation (read OpenSSL) because it centers around the certificate instead of the public/private keys.</p>
<p>Right now it have support for PKCS12, PEM, DER certificate stores, I&#8217;ll soon add PKCS11 support.</p>
<p>The CMS interface is somewhat raw, but produces and decodes/verifies SignedData and EnvelopedData. Talking about the interface, I&#8217;ll update the API for sure, there needs to be a context variable to pass back errors to the user, com_err might be good, but its not that good.</p>
<p>The reason I started this work is that I found the choices I had to use CMS in PK-INIT was bad and very strange to use. They also didn&#8217;t support the operations I need to do, for example search certificates for diffrent critera, use random oids as content types in CMS messages or interface with PKCS11 in a sane way.</p>
<p>Adding PKCS11 support is going to be the intresting part, then I&#8217;ll see how much of the API I made up really works with keys that are hiddes inside other devices.</p>
<p>A choice I have to make is what crypto libary I want to support, one way to do it is to use PKCS11 for everything, this way the X.509 and CMS libary will be independent of the crypto support, and the user can choose what crypto provider to use.</p>
<p>The real work is of course adding more tests, its really great to have a large regression testsuite, makes you feel warm inside. Right now there is a small one, but it needs improvements (and for me to commit it).</p>
<p>Technorati tag: <a rel="tag" href="http://technorati.com/tag/Heimdal">Heimdal</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.h5l.org/blog/index.php/2005/07/hx509-x509-and-cms-for-heimdal/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
