#1012485 barbican: autopkgtests fail under OpenSSL 3

#1012485#5
Date:
2022-06-08 08:11:47 UTC
From:
To:
In sid, with OpenSSL 3, the following barbican test fails in the
autopkgtest:

======================================================================
FAIL: barbican.tests.common.test_validators.WhenTestingSimpleCMCOrderValidator.test_should_raise_with_unsigned_pkcs10_data
barbican.tests.common.test_validators.WhenTestingSimpleCMCOrderValidator.test_should_raise_with_unsigned_pkcs10_data
----------------------------------------------------------------------
testtools.testresult.real._StringException: Traceback (most recent call last):
  File "/tmp/autopkgtest.QMCrjK/build.2Gf/src/barbican/tests/common/test_validators.py", line 1435, in test_should_raise_with_unsigned_pkcs10_data
    certs.create_csr_that_has_not_been_signed())
  File "/tmp/autopkgtest.QMCrjK/build.2Gf/src/barbican/tests/certificate_utils.py", line 53, in create_csr_that_has_not_been_signed
    pem = crypto.dump_certificate_request(crypto.FILETYPE_PEM, csr)
  File "/usr/lib/python3/dist-packages/OpenSSL/crypto.py", line 2969, in dump_certificate_request
    _openssl_assert(result_code != 0)
  File "/usr/lib/python3/dist-packages/OpenSSL/_util.py", line 71, in openssl_assert
    exception_from_error_queue(error)
  File "/usr/lib/python3/dist-packages/OpenSSL/_util.py", line 57, in exception_from_error_queue
    raise exception_type(errors)
OpenSSL.crypto.Error: [('asn1 encoding routines', '', 'illegal zero content'), ('PEM routines', '', 'ASN1 lib')]
----------------------------------------------------------------------
Ran 1488 tests in 38.966s

FAILED (failures=1, skipped=56)

Looks like the test was relying on unsupported behaviour in OpenSSL to
create at unsigned CSR in the past.

SR

#1012485#10
Date:
2022-06-14 09:21:31 UTC
From:
To:
Hello,

Bug #1012485 in barbican reported by you has been fixed in the
Git repository and is awaiting an upload. You can see the commit
message below and you can check the diff of the fix at:

https://salsa.debian.org/openstack-team/services/barbican/-/commit/f2c7b9aa8b4be6fd1d0fece40ecdf85a6e51f5bd
------------------------------------------------------------------------
* Also blacklist test_should_raise_with_unsigned_pkcs10_data() in
    autopkgtest (Closes: #1012485).
------------------------------------------------------------------------

(this message was generated automatically)
-- 
Greetings

https://bugs.debian.org/1012485

#1012485#17
Date:
2022-06-14 09:33:55 UTC
From:
To:
We believe that the bug you reported is fixed in the latest version of
barbican, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1012485@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Thomas Goirand <zigo@debian.org> (supplier of updated barbican package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
Format: 1.8
Date: Tue, 14 Jun 2022 10:58:03 +0200
Source: barbican
Architecture: source
Version: 1:14.0.0-3
Distribution: unstable
Urgency: medium
Maintainer: Debian OpenStack <team+openstack@tracker.debian.org>
Changed-By: Thomas Goirand <zigo@debian.org>
Closes: 1012485
Changes:
 barbican (1:14.0.0-3) unstable; urgency=medium
 .
   * Also blacklist test_should_raise_with_unsigned_pkcs10_data() in
     autopkgtest (Closes: #1012485).
Checksums-Sha1:
 6d6c8ce5e9d31655c90c5ce1dd092021d04fe828 3660 barbican_14.0.0-3.dsc
 7b6524196c23a3e7e653069f158770f4baaeeffa 10048 barbican_14.0.0-3.debian.tar.xz
 9f298c05edfce290ab9c03b2ccc4bd0c998e717a 21640 barbican_14.0.0-3_amd64.buildinfo
Checksums-Sha256:
 5e29b14d255bc8a31f883f518293a73def151c2bf55f4d77863bae46ea6f0bb3 3660 barbican_14.0.0-3.dsc
 79547dbd62cfb268223f30df6e5eace370cbe2c2cdb161fd7e586b3027b2bffd 10048 barbican_14.0.0-3.debian.tar.xz
 73f7c734fb3c4bc97850135892fc0e2cf491ca67ed745a2d5e91421e8a784637 21640 barbican_14.0.0-3_amd64.buildinfo
Files:
 e3b995621de558afee4fc7638278955c 3660 net optional barbican_14.0.0-3.dsc
 032edc48164f8c6b0cedb304fc7ae438 10048 net optional barbican_14.0.0-3.debian.tar.xz
 148b523e8f1cc7a3d74647ae73f7bce7 21640 net optional barbican_14.0.0-3_amd64.buildinfo
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEoLGp81CJVhMOekJc1BatFaxrQ/4FAmKoUxoACgkQ1BatFaxr
Q/5Y5RAAkm069+G6fq28muxNAxUqqHQ+oCwB6LWEPAwciLDOXKl8H2G1gWl9ZI+B
W/8gVeVZThUwruiWu39A570pkhYlvIwhJxA7O9UWHZe34t6PU5R7nn73yiXH7inZ
Bo1fpcUCg9nSkQcNrxQSZCVl05b82lehGII6shxNRx0qP/nbfFQ+kw2ZMZXeuNaP
5QqRRHgaMGTSWkU2BE37WNP546X+JTexlFPZ2PEzU0x5DSeztiMjf1Rr8UzikID4
1BjeuXLyPhjsHPBBWP2rl1jZVTCmwfM3gLQTyYT29PXXTOSun2OHyge/pV54mZW5
nHFK45gCOGk805Q1ODqpZ8lBelTXwbe0T1L+sARSHZ8JA/NFDdriDu9YFRLuOZMC
s+gEgGoaHqxfcMjw2nZ3TADtJoTpAVWZ/Ux8Exmh/xyPQstQvD6ddfBX96FGiAMR
0ch6JUC/mvx9bx7Xj33YTp5n0ZqD0TJi2Wg2Mf+eCqfMWILqFY+Xf18DGOZaAwVY
k9X/blA/a1ToikD1MAPD9/ioCZ3o7Y/X9TZH+Ks7LUll1j9c2w3d6bf4LGmaIMPn
UgzYcS/0FDAkc9WbpeFvy1gXQs0vh0C/Kq0WIruKDW+ls55bgrFAuVWs6MF4VJdk
ggfpxODaf7qKzYY274QwciHXJKSZ+ExEunNbo5EW3msiU4fMJ2s=
=WepD
-----END PGP SIGNATURE-----