SHA256
1
0
forked from pool/tpm2.0-tools
tpm2.0-tools/tpm2.0-tools.spec
Alberto Planas Dominguez 67cb2ca5c3 Accepting request 1134440 from home:aplanas:branches:security
- Update to version 5.6
  + tpm2_eventlog:
    * add H-CRTM event support
    * add support of efivar versions less than 38
    * Add support to check for efivar/efivar.h manually
    * Minor formatting fixes
    * tpm2_eventlog: add support for replay with different
      StartupLocality
    * Fix pcr extension for EV_NO_ACTION
    * Extend test of yaml string representation
    * Use helper for printing a string dump
    * Fix upper bound on unique data size
    * Fix YAML string formatting
  + tpm2_policy:
    * Add support for parsing forward seal TPM values
    * Use forward seal values in creating policies
    * Move dgst_size in evaluate_populate_pcr_digests()
    * Allow more than 8 PCRs for sealing
    * Move dgst_size in evaluate_populate_pcr_digests
    * Allow more than 8 PCRs for sealing
    * Make __wrap_Esys_PCR_Read() more dynamic to enable testing more
      PCRs
  + tpm2_encryptdecrypt: Fix pkcs7 padding stripping
  + tpm2_duplicate:
    * Support -a option for attributes
    * Add --key-algorithm option
  + tpm2_encodeobject: Use the correct -O option instead of -C
  + tpm2_unseal: Add qualifier static to enhance the privacy of unseal
    function
  + tpm2_sign:
    * Remove -m option which was added mistakenly
    * Revert sm2 sign and verifysignature
  + tpm2_createek:
    * Correct man page example
    * Fix usage of nonce
    * Fix integrating nonce
  + tpm2_clear: add more details about the action
  + tpm2_startauthsession: allow the file attribute for policy
    authorization.
  + tpm2_getekcertificate: Add AMD EK support
  + tpm2_ecdhzgen: Add public-key parameter
  + tpm2_nvreadpublic: Prevent free of unallocated pointers on failure
  + Bug-fixes:
    * The readthedocs build failed with module 'jinja2' has no
      attribute 'contextfilter' a requirement file was added to fix
      this problem
    * An error caused by the flags -flto -_FORTIFY_SOURCE=3 in kdfa
      implementation. This error can be avoided by switching off the
      optimization with pragma
    * Changed wrong function name of "Esys_Load" to "Esys_Load"
    * Function names beginning with Esys_ are wrongly written as Eys_
    * Reading and writing a serialized persistent ESYS_TR handles
    * cirrus-ci update image-family to freebsd-13-2 from 13-1
  + misc:
    * Change the default Python version to Python3 in the helper's
      code
    * Skip test which uses the sign operator for comparison in
      abrmd_policynv.sh
    * tools/tr_encode: Add a tool that can encode serialized ESYS_TR
      for persistent handles from the TPM2B_PUBLIC and the raw
      persistent TPM2_HANDLE
    * Add safe directory in config

OBS-URL: https://build.opensuse.org/request/show/1134440
OBS-URL: https://build.opensuse.org/package/show/security/tpm2.0-tools?expand=0&rev=106
2023-12-21 12:30:18 +00:00

117 lines
3.8 KiB
RPMSpec

#
# spec file for package tpm2.0-tools
#
# Copyright (c) 2023 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 _lto_cflags %{nil}
%ifarch %{ix86} x86_64 aarch64 %{arm} ppc64le
# Disable the tests for now in all architectures
%bcond_with test
%else
# ppc ppc64 s390x: some code (tpm2_command_header_from_bytes) depend
# on the endianness of the architecture:
# gh#tpm2-software/tpm2-tools#3055
# gh#tpm2-software/tpm2-tools#3060
# gh#tpm2-software/tpm2-tools#3061
%bcond_with test
%endif
Name: tpm2.0-tools
Version: 5.6
Release: 0
Summary: Trusted Platform Module (TPM) 2.0 administration tools
License: BSD-3-Clause
Group: Productivity/Security
URL: https://github.com/tpm2-software/tpm2-tools/releases
Source0: https://github.com/tpm2-software/tpm2-tools/releases/download/%{version}/tpm2-tools-%{version}.tar.gz
Source1: https://github.com/tpm2-software/tpm2-tools/releases/download/%{version}/tpm2-tools-%{version}.tar.gz.asc
# git show william-roberts-pub javier-martinez-pub joshua-lock-pub idesai-pub > tpm2-tools.keyring
# The key can be accessed by "curl https://github.com/UNAME.gpg"
Source2: tpm2-tools.keyring
BuildRequires: gcc-c++
BuildRequires: libcurl-devel
BuildRequires: libopenssl-devel
BuildRequires: libtool
BuildRequires: libuuid-devel
BuildRequires: pkgconfig
BuildRequires: tpm2-0-tss-devel
BuildRequires: tpm2.0-abrmd-devel
BuildRequires: pkgconfig(efivar)
Recommends: tpm2.0-abrmd
# Pandoc is used for generating the man pages, but since 3.0.4 prebuilt man
# pages are shipped with the distribution tarball and we don't need to generate
# them any more. Pandoc is only available on openSUSE (not 32-bit x86) and not
# in Ring 1 (no haskell), so can't be used as build dependency here.
%if 0
%if 0%{?is_opensuse}
%ifnarch %{ix86}
BuildRequires: pandoc
%endif
%endif
%endif
%if %{with test}
# requirements for unit test suite (configure --enable-unit)
BuildRequires: dbus-1-daemon
BuildRequires: expect
BuildRequires: ibmswtpm2
BuildRequires: iproute2
BuildRequires: libcmocka-devel
BuildRequires: python3-PyYAML
BuildRequires: tpm2.0-abrmd
# for xxd, which is also required by the tests
BuildRequires: vim
%endif
%description
Trusted Computing is a set of specifications published by the Trusted
Computing Group (TCG). The Trusted Platform Module (TPM) is the
hardware component for Trusted Computing. The tpm2.0-tools package
provides tools for enablement and configuration of the TPM 2.0 and
associated interfaces.
%prep
%autosetup -p1 -n tpm2-tools-%{version}
%build
# help configure find required executables for testing
export PATH=$PATH:/usr/sbin:/usr/libexec/ibmtss
%configure --disable-static \
%{?with_test: --enable-unit}
%make_build
%install
%make_install
find %{buildroot} -type f -name "*.la" -delete -print
%if %{with test}
%check
# Do the tests sequentially to kill all tpm_server instances
# https://github.com/tpm2-software/tpm2-tools/issues/3042
%make_build check
%endif
%files
%doc docs/README.md docs/CHANGELOG.md
%license docs/LICENSE
%{_bindir}/tpm2*
%{_bindir}/tss2*
%{_mandir}/man1/tpm2*
%{_mandir}/man1/tss2*
%dir %{_datadir}/bash-completion
%dir %{_datadir}/bash-completion/completions
%{_datadir}/bash-completion/completions/*
%changelog