[UBUNTU 19.04] opencryptoki 3.11 - usr/lib/ep11_stdll/ep11_specific.c Warning: Adapter has a different API version than the previous CEX6P adapters: 2

Bug #1847031 reported by bugproxy
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu on IBM z Systems
Fix Released
Critical
Canonical Foundations Team
opencryptoki (Ubuntu)
Fix Released
Undecided
Skipper Bug Screeners
Disco
Fix Released
Undecided
Unassigned
Eoan
Fix Released
Undecided
Unassigned
Focal
Fix Released
Undecided
Skipper Bug Screeners

Bug Description

Opencryptoki's EP11 token fails to initialize when CEX7P and CEX6P cards are available and thus do not show up with 'pkcsconf -t'. For CEX6P-only or CEX7P-only configurations the EP11 token is displayed as expected with 'pkcsconf'.

Root cause is that CEX7P uses a different API version and firmware version than CEX6P, but with CEX7 toleration support currently available in the distro only, a CEX7P card shows up as CEX6P. The EP11 token does not allow that 2 cards of the same generation use a different API version or firmware version. With CEX7P cards showing up as CEX6P cards this is the case, and opencryptoki rejects to initialize.

Machine Type = IBM Type: 8561 Model: 703 T01

---Steps to Reproduce---
1.) Install openCryptoki version 3.11 as delivered by the distribution

2.) Configure the EP11 token into the /etc/opencryptoki/opencryptoki.conf file as outlined in the Details section

3.) run: systemctl restart pkcsslotd

4.) run: pkcsconf -t -c <N>, where N is the EP11 token number
The EP11 token is unexpectedly not available
Error getting token info: 0xE0 (CKR_TOKEN_NOT_PRESENT)

5.) run: journalctl -r and encounter
pkcsconf[73735]: usr/lib/ep11_stdll/ep11_specific.c Warning: Adapter 02.0016 has a different API version than the previous CEX6P adapters: 2.
The EP11 token is not listed by pkcsconf -t.

Userspace tool common name: pkcsconf

Userspace rpm: openCryptoki-3.11

Patch should apply fine on top of Opencryptoki 3.11.

Upstream commit:
https://github.com/opencryptoki/opencryptoki/commit/d6ba9ff61743ce869a5a677f6f77339642efef4b
("EP11: Support tolerated new crypto cards")

bugproxy (bugproxy)
tags: added: architecture-s39064 bugnameltc-181793 severity-critical targetmilestone-inin1904
Changed in ubuntu:
assignee: nobody → Skipper Bug Screeners (skipper-screen-team)
affects: ubuntu → opencryptoki (Ubuntu)
Revision history for this message
Frank Heimes (fheimes) wrote :

@IBM I strongly assume that the patch is needed for Eoan too, right?
rmadison --arch=s390x opencryptoki | grep 3\.11
 opencryptoki | 3.11.0+dfsg-0ubuntu2 | disco/universe | s390x
 opencryptoki | 3.11.1+dfsg-0ubuntu2 | eoan/universe | s390x

Changed in ubuntu-z-systems:
status: New → Triaged
importance: Undecided → Critical
assignee: nobody → Canonical Foundations Team (canonical-foundations)
Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2019-10-07 04:41 EDT-------
This patch is also needed for Eoan , that is correct....

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package opencryptoki - 3.11.1+dfsg-0ubuntu3

---------------
opencryptoki (3.11.1+dfsg-0ubuntu3) focal; urgency=medium

  * Fix toleration of CEX7P and CEX6P cards, when both are present.
    (LP: #1847031)

 -- Dimitri John Ledkov <email address hidden> Tue, 22 Oct 2019 15:28:41 +0100

Changed in opencryptoki (Ubuntu Focal):
status: New → Fix Released
Frank Heimes (fheimes)
Changed in ubuntu-z-systems:
status: Triaged → In Progress
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

This seems good so I'll accept it, but it would be good if we could get some regression potential analysis before this goes into -updates. Could anyone add that to the description? Thanks.

Changed in opencryptoki (Ubuntu Eoan):
status: New → Fix Committed
tags: added: verification-needed verification-needed-eoan
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

Hello bugproxy, or anyone else affected,

Accepted opencryptoki into eoan-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/opencryptoki/3.11.1+dfsg-0ubuntu2.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-eoan to verification-done-eoan. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-eoan. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in opencryptoki (Ubuntu Disco):
status: New → Fix Committed
tags: added: verification-needed-disco
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

Hello bugproxy, or anyone else affected,

Accepted opencryptoki into disco-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/opencryptoki/3.11.0+dfsg-0ubuntu2.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-disco to verification-done-disco. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-disco. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Frank Heimes (fheimes)
Changed in ubuntu-z-systems:
status: In Progress → Fix Committed
Revision history for this message
Frank Heimes (fheimes) wrote :

I did regression tests on disco and eoan with proposed enabled and didn't faced any messages like the one mentioned in the bug title / description - but I only have access to CEX5 cards.

But I faced a different problem - that led to LP 1850293 (an IBM package that needs to be adjusted, hence the ticket is reversed mirrored to IBM's bugzilla system) and LP 1850294 (two further but small opencryptoki patches).
I'll leave this ticket and the verifications for now as they are and wait for IBM for a final feedback on the verifications.

Changed in ubuntu-z-systems:
status: Fix Committed → Incomplete
Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2019-10-29 14:15 EDT-------
Verifiedon a system providing CEX5P, CEX6P, and tolerated CEX7P EP11 co-processors, that the fixed opencryptoki package provided via -propsed that the message regarding different API version did not longer occur. The EP11 token is available and could be initialized.

# dpkg -l opencryptoki
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-==============-======================-============-=================================
ii opencryptoki 3.11.0+dfsg-0ubuntu2.1 s390x PKCS#11 implementation (daemon)

Revision history for this message
Frank Heimes (fheimes) wrote :

Based on my testing and the feedback on the verification from Christian in comment #8, I'm adjusting the tags accordingly.

tags: added: verification-done verification-done-disco verification-done-eoan
removed: verification-needed verification-needed-disco verification-needed-eoan
Changed in ubuntu-z-systems:
status: Incomplete → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package opencryptoki - 3.11.1+dfsg-0ubuntu2.1

---------------
opencryptoki (3.11.1+dfsg-0ubuntu2.1) eoan; urgency=medium

  * Fix toleration of CEX7P and CEX6P cards, when both are present.
    (LP: #1847031)

 -- Dimitri John Ledkov <email address hidden> Tue, 22 Oct 2019 16:57:24 +0100

Changed in opencryptoki (Ubuntu Eoan):
status: Fix Committed → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for opencryptoki has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package opencryptoki - 3.11.0+dfsg-0ubuntu2.1

---------------
opencryptoki (3.11.0+dfsg-0ubuntu2.1) disco; urgency=medium

  * Fix toleration of CEX7P and CEX6P cards, when both are present.
    (LP: #1847031)

 -- Dimitri John Ledkov <email address hidden> Tue, 22 Oct 2019 16:59:12 +0100

Changed in opencryptoki (Ubuntu Disco):
status: Fix Committed → Fix Released
Frank Heimes (fheimes)
Changed in ubuntu-z-systems:
status: Fix Committed → Fix Released
Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2019-11-04 11:49 EDT-------
IBM Bugzilla status -> closed, Fix Release with all requested Distros

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.