tpm2-pkcs11/tpm2-pkcs11.spec

117 lines
3.5 KiB
RPMSpec
Raw Normal View History

#
# spec file for package tpm2-pkcs11
#
# Copyright (c) 2021 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define so_ver 0
%define pythons python3
Name: tpm2-pkcs11
Accepting request 926517 from home:aplanas:branches:security - Update to 1.7.0 + DB Schema Change from 5 to 7. * Backup your DB before upgrading + Fixed compilation issues with GCC11. + Fixed errors on releases due to newer compilers from failing by only adding -Werror for non-release builds. + Fixed error message when the DB is too new in tpm2_ptool. + Added support for tpm2_ptool import with ssh-keygen format keys. Note: Requires cryptography >= 3.0. + Changed default long level from error to warning. + Added better error message for FAPI backend errors along with docs/FAPI.md document. + Changed tpm2_ptool make --algorithm optional. + Fixed error message of wrong attribute name on expected attribute check to be false. + Added support for ECDSA 256, 384 and 512. + Fixed a bug in the Python code DB upgrade path from 4 to 5 where it didn't add AES mode CTR to CKA_ALLOWED_MECHANISMS. + Added tpm2_ptool support for ECC key size 192. + Added support passwordless login for tokens, ie not setting CKF_LOGIN_REQUIRED. + Fixed Running integration tests when Java version has the -ea, like on Debian 11 and OpenJDK 17. + Added support for HMAC keys using tpm2_ptool and the C_Sign and C_Verify interfaces. The following interfaces in ptool have support: * addkey: previous working versions of tpm2-tools will support this. * link: previous working versions of tpm2-tools will support this. * import: requires tpm2-tools 5.2+ for support. + Fixed leaking of temp file descriptors in tpm2_ptool. + Fixed wrong free in tpm code, should use Esys_Free. + Fixed a space formatting issue in tpm2_ptool verify. + Fixed leaked file descriptor in tpm2_ptool. + Fixed a few suspicious sizeof usages in str_padded_copy + Fixed a memory leak of the token list on a failure condition in initialization. OBS-URL: https://build.opensuse.org/request/show/926517 OBS-URL: https://build.opensuse.org/package/show/security/tpm2-pkcs11?expand=0&rev=8
2021-10-20 12:28:43 +02:00
Version: 1.7.0
Release: 0
Summary: A PKCS#11 interface for TPM2 hardware
License: BSD-2-Clause
Group: Productivity/Security
URL: https://github.com/tpm2-software/tpm2-pkcs11
Source0: %{url}/releases/download/%{version}/%{name}-%{version}.tar.gz
BuildRequires: autoconf
BuildRequires: autoconf-archive >= 2017.03.21
BuildRequires: automake
Accepting request 926517 from home:aplanas:branches:security - Update to 1.7.0 + DB Schema Change from 5 to 7. * Backup your DB before upgrading + Fixed compilation issues with GCC11. + Fixed errors on releases due to newer compilers from failing by only adding -Werror for non-release builds. + Fixed error message when the DB is too new in tpm2_ptool. + Added support for tpm2_ptool import with ssh-keygen format keys. Note: Requires cryptography >= 3.0. + Changed default long level from error to warning. + Added better error message for FAPI backend errors along with docs/FAPI.md document. + Changed tpm2_ptool make --algorithm optional. + Fixed error message of wrong attribute name on expected attribute check to be false. + Added support for ECDSA 256, 384 and 512. + Fixed a bug in the Python code DB upgrade path from 4 to 5 where it didn't add AES mode CTR to CKA_ALLOWED_MECHANISMS. + Added tpm2_ptool support for ECC key size 192. + Added support passwordless login for tokens, ie not setting CKF_LOGIN_REQUIRED. + Fixed Running integration tests when Java version has the -ea, like on Debian 11 and OpenJDK 17. + Added support for HMAC keys using tpm2_ptool and the C_Sign and C_Verify interfaces. The following interfaces in ptool have support: * addkey: previous working versions of tpm2-tools will support this. * link: previous working versions of tpm2-tools will support this. * import: requires tpm2-tools 5.2+ for support. + Fixed leaking of temp file descriptors in tpm2_ptool. + Fixed wrong free in tpm code, should use Esys_Free. + Fixed a space formatting issue in tpm2_ptool verify. + Fixed leaked file descriptor in tpm2_ptool. + Fixed a few suspicious sizeof usages in str_padded_copy + Fixed a memory leak of the token list on a failure condition in initialization. OBS-URL: https://build.opensuse.org/request/show/926517 OBS-URL: https://build.opensuse.org/package/show/security/tpm2-pkcs11?expand=0&rev=8
2021-10-20 12:28:43 +02:00
BuildRequires: fdupes
BuildRequires: libtool
BuildRequires: pkgconfig
Accepting request 926517 from home:aplanas:branches:security - Update to 1.7.0 + DB Schema Change from 5 to 7. * Backup your DB before upgrading + Fixed compilation issues with GCC11. + Fixed errors on releases due to newer compilers from failing by only adding -Werror for non-release builds. + Fixed error message when the DB is too new in tpm2_ptool. + Added support for tpm2_ptool import with ssh-keygen format keys. Note: Requires cryptography >= 3.0. + Changed default long level from error to warning. + Added better error message for FAPI backend errors along with docs/FAPI.md document. + Changed tpm2_ptool make --algorithm optional. + Fixed error message of wrong attribute name on expected attribute check to be false. + Added support for ECDSA 256, 384 and 512. + Fixed a bug in the Python code DB upgrade path from 4 to 5 where it didn't add AES mode CTR to CKA_ALLOWED_MECHANISMS. + Added tpm2_ptool support for ECC key size 192. + Added support passwordless login for tokens, ie not setting CKF_LOGIN_REQUIRED. + Fixed Running integration tests when Java version has the -ea, like on Debian 11 and OpenJDK 17. + Added support for HMAC keys using tpm2_ptool and the C_Sign and C_Verify interfaces. The following interfaces in ptool have support: * addkey: previous working versions of tpm2-tools will support this. * link: previous working versions of tpm2-tools will support this. * import: requires tpm2-tools 5.2+ for support. + Fixed leaking of temp file descriptors in tpm2_ptool. + Fixed wrong free in tpm code, should use Esys_Free. + Fixed a space formatting issue in tpm2_ptool verify. + Fixed leaked file descriptor in tpm2_ptool. + Fixed a few suspicious sizeof usages in str_padded_copy + Fixed a memory leak of the token list on a failure condition in initialization. OBS-URL: https://build.opensuse.org/request/show/926517 OBS-URL: https://build.opensuse.org/package/show/security/tpm2-pkcs11?expand=0&rev=8
2021-10-20 12:28:43 +02:00
BuildRequires: python-rpm-generators
BuildRequires: python3-base
BuildRequires: python3-setuptools
Accepting request 926517 from home:aplanas:branches:security - Update to 1.7.0 + DB Schema Change from 5 to 7. * Backup your DB before upgrading + Fixed compilation issues with GCC11. + Fixed errors on releases due to newer compilers from failing by only adding -Werror for non-release builds. + Fixed error message when the DB is too new in tpm2_ptool. + Added support for tpm2_ptool import with ssh-keygen format keys. Note: Requires cryptography >= 3.0. + Changed default long level from error to warning. + Added better error message for FAPI backend errors along with docs/FAPI.md document. + Changed tpm2_ptool make --algorithm optional. + Fixed error message of wrong attribute name on expected attribute check to be false. + Added support for ECDSA 256, 384 and 512. + Fixed a bug in the Python code DB upgrade path from 4 to 5 where it didn't add AES mode CTR to CKA_ALLOWED_MECHANISMS. + Added tpm2_ptool support for ECC key size 192. + Added support passwordless login for tokens, ie not setting CKF_LOGIN_REQUIRED. + Fixed Running integration tests when Java version has the -ea, like on Debian 11 and OpenJDK 17. + Added support for HMAC keys using tpm2_ptool and the C_Sign and C_Verify interfaces. The following interfaces in ptool have support: * addkey: previous working versions of tpm2-tools will support this. * link: previous working versions of tpm2-tools will support this. * import: requires tpm2-tools 5.2+ for support. + Fixed leaking of temp file descriptors in tpm2_ptool. + Fixed wrong free in tpm code, should use Esys_Free. + Fixed a space formatting issue in tpm2_ptool verify. + Fixed leaked file descriptor in tpm2_ptool. + Fixed a few suspicious sizeof usages in str_padded_copy + Fixed a memory leak of the token list on a failure condition in initialization. OBS-URL: https://build.opensuse.org/request/show/926517 OBS-URL: https://build.opensuse.org/package/show/security/tpm2-pkcs11?expand=0&rev=8
2021-10-20 12:28:43 +02:00
BuildRequires: tpm2.0-tools
BuildRequires: pkgconfig(libcrypto) >= 1.0.2g
BuildRequires: pkgconfig(p11-kit-1)
BuildRequires: pkgconfig(sqlite3)
BuildRequires: pkgconfig(tss2-esys) >= 2.0
BuildRequires: pkgconfig(tss2-mu)
BuildRequires: pkgconfig(tss2-rc)
BuildRequires: pkgconfig(tss2-tctildr)
BuildRequires: pkgconfig(yaml-0.1)
%{?python_enable_dependency_generator}
%description
PKCS #11 is a Public-Key Cryptography Standard that defines a standard method to
access cryptographic services from tokens/devices such as hardware security
modules (HSM), smart cards, etc. This project uses a TPM2 device
as the cryptographic token.
%package -n libtpm2_pkcs11-0
Summary: A PKCS#11 interface for TPM2 hardware
Group: System/Libraries
Requires: %{name} = %{version}
%description -n libtpm2_pkcs11-0
PKCS #11 is a Public-Key Cryptography Standard that defines a standard method to
access cryptographic services from tokens/devices such as hardware security
modules (HSM), smart cards, etc. This project uses a TPM2 device
as the cryptographic token.
%package devel
Summary: Development files for %{name}
Group: Development/Libraries/C and C++
Requires: libtpm2_pkcs11-0 = %{version}
Provides: libtpm2_pkcs11-devel = %{version}-%{release}
%description devel
Headers and libraries to build software against %{name}.
%prep
%autosetup
%build
autoreconf -fiv
%configure --disable-static
%make_build
cd tools
%python_build
%install
%make_install
find %{buildroot} -type f -name "*.la" -delete -print
mkdir -p %{buildroot}%{_sysconfdir}/tpm2_pkcs11
cd tools
%python_install
%fdupes -s %{buildroot}
%post -n libtpm2_pkcs11-0 -p /sbin/ldconfig
%postun -n libtpm2_pkcs11-0 -p /sbin/ldconfig
%files
%license LICENSE
%doc docs/*
%dir %{_datadir}/p11-kit/modules
%dir %{_datadir}/p11-kit
%{_datadir}/p11-kit/modules/tpm2_pkcs11.module
%{_sysconfdir}/tpm2_pkcs11
%{_bindir}/tpm2_ptool
%{python_sitelib}/tpm2_pkcs11
%{python_sitelib}/*.egg-info
%files -n libtpm2_pkcs11-0
%dir %{_libdir}/pkcs11
%{_libdir}/pkcs11/libtpm2_pkcs11.so.%{so_ver}*
%files devel
%dir %{_libdir}/pkcs11
%{_libdir}/pkgconfig/tpm2-pkcs11.pc
%{_libdir}/pkcs11/libtpm2_pkcs11.so
%changelog