Using p11-kit for PKCS#11 support

Stef Walter stefw at
Thu Jun 9 11:06:53 CEST 2011

On 06/07/2011 08:22 PM, Nikos Mavrogiannopoulos wrote:
> On 06/07/2011 07:36 PM, Stef Walter wrote:
>> The attached patch ports gnutls to p11-kit. It's actually a combined set
>> of patches, and these are available in branch form:
> Thank you Stef. I've just commited it. But could you try compiling with
> the --enable-gcc-warnings configure flag?
> I had some uninitialized variables in
> 1. pkcs11.c:311 and 312
> 2. pkcs11.c:875
> which I have quickly solved, but probably not in a correct way.

Attached is another patch which fixes them a bit differently. Also fixes 
other warnings that GCC 4.6.0 complains about.

That said, for some reason the file lib/pkcs11_spec.h is missing from 
master. At least for me. This prevents gnutls master from building. I've 
attached it too.

>> [2]
> I installed p11-kit from the git and it tries to open
> "${prefix}/etc/pkcs11/pkcs11.conf"
> When I explicitly used:
> ../configure --sysconfdir=/etc/
> it worked ok.

Good catch. I've fixed that in p11-kit master. It now defaults to 
/etc/pkcs11. The directory can be changed by packagers if necessary with 
a --with-pkcs11-dir configure argument.

> btw. There is a typo in
> It should be: "module: The absolute path to the PKCS#11 module to load."

Thanks. Fixed.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Fix-up-compiler-warnings.patch
Type: text/x-patch
Size: 2935 bytes
Desc: not available
URL: </pipermail/attachments/20110609/ae8c0395/attachment.bin>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: pkcs11_spec.h
URL: </pipermail/attachments/20110609/ae8c0395/attachment.asc>

More information about the Gnutls-devel mailing list