Bug 1235284

Summary: libp11: doesn't work for applications that do fork
Product: [Fedora] Fedora Reporter: Nikos Mavrogiannopoulos <nmavrogi>
Component: libp11Assignee: Nikos Mavrogiannopoulos <nmavrogi>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 22CC: dwmw2, gmazyland, kalevlember, tmraz
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-07-12 20:18:24 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1236526    

Description Nikos Mavrogiannopoulos 2015-06-24 13:13:57 UTC
Description of problem:
Engine_pkcs11 is simple to use for applications as it hides all the PKCS #11 stuff, but it doesn't cope with the case of applications that fork. That is PKCS #11 (v2.40) requires the reinitialization (C_Initialize) of any open modules after fork. That would also imply that open handles to objects have to be reopened again.

That is not done by the engine. See upstream issue:
https://github.com/OpenSC/engine_pkcs11/issues/16

Comment 1 Nikos Mavrogiannopoulos 2015-06-26 14:16:07 UTC
Reassigning to libp11, as this seems like the proper place to fix the issue.

https://github.com/OpenSC/libp11/pull/21

Comment 2 Kalev Lember 2015-06-29 11:26:55 UTC
Do you want commit access to push the fixes out yourself?

I don't use the pkcs11 stack myself any more and I'd be happy to hand it over to you, if you want - I've only been holding on to them so they don't get removed from the distro.

Comment 3 Nikos Mavrogiannopoulos 2015-06-29 12:04:14 UTC
I wouldn't really like to maintain this package. If David cannot handle as well, then we don't have a choice anyway. I'll apply.

Comment 4 David Woodhouse 2015-06-29 15:16:38 UTC
I'm somewhat reluctant to take on new packages, as I know I don't do an excellent job of maintaining them — my attention is fairly sporadic. I'm happy to comaintain, but as a provenpackager I tend to do that anyway.

Comment 5 Nikos Mavrogiannopoulos 2015-06-30 08:30:29 UTC
Ok. I'll apply for comaintainership.

Comment 6 Nikos Mavrogiannopoulos 2015-07-10 13:39:22 UTC
I've sent a pull request upstream, and applied it in rawhide for testing.
https://github.com/OpenSC/libp11/pull/25