forked from pool/ibmtss
Accepting request 453675 from home:michals
update of ibmtpm20tss OBS-URL: https://build.opensuse.org/request/show/453675 OBS-URL: https://build.opensuse.org/package/show/security/ibmtss?expand=0&rev=1
This commit is contained in:
commit
0afe6a6710
25
.gitattributes
vendored
Normal file
25
.gitattributes
vendored
Normal file
@ -0,0 +1,25 @@
|
||||
## Default LFS
|
||||
*.7z filter=lfs diff=lfs merge=lfs -text
|
||||
*.bsp filter=lfs diff=lfs merge=lfs -text
|
||||
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.gem filter=lfs diff=lfs merge=lfs -text
|
||||
*.gz filter=lfs diff=lfs merge=lfs -text
|
||||
*.jar filter=lfs diff=lfs merge=lfs -text
|
||||
*.lz filter=lfs diff=lfs merge=lfs -text
|
||||
*.lzma filter=lfs diff=lfs merge=lfs -text
|
||||
*.obscpio filter=lfs diff=lfs merge=lfs -text
|
||||
*.oxt filter=lfs diff=lfs merge=lfs -text
|
||||
*.pdf filter=lfs diff=lfs merge=lfs -text
|
||||
*.png filter=lfs diff=lfs merge=lfs -text
|
||||
*.rpm filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz filter=lfs diff=lfs merge=lfs -text
|
||||
*.tbz2 filter=lfs diff=lfs merge=lfs -text
|
||||
*.tgz filter=lfs diff=lfs merge=lfs -text
|
||||
*.ttf filter=lfs diff=lfs merge=lfs -text
|
||||
*.txz filter=lfs diff=lfs merge=lfs -text
|
||||
*.whl filter=lfs diff=lfs merge=lfs -text
|
||||
*.xz filter=lfs diff=lfs merge=lfs -text
|
||||
*.zip filter=lfs diff=lfs merge=lfs -text
|
||||
*.zst filter=lfs diff=lfs merge=lfs -text
|
||||
## Specific LFS patterns
|
||||
ibmtss713.tar filter=lfs diff=lfs merge=lfs -text
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
@ -0,0 +1 @@
|
||||
.osc
|
43
ibmtss
Normal file
43
ibmtss
Normal file
@ -0,0 +1,43 @@
|
||||
#!/bin/bash
|
||||
|
||||
function usage() {
|
||||
echo Usage: "$1" "<command>" "<arguments>"
|
||||
echo -e "\thelp" "\t\tprint this help"
|
||||
echo -e "\tlist" "\t\tlist commands"
|
||||
echo -e "\t<command> -h" "\tdisplay command help"
|
||||
}
|
||||
|
||||
function do_exec() {
|
||||
self="$1"
|
||||
shift
|
||||
case "$1" in
|
||||
help|""|*.*|*/*) usage "$self"
|
||||
return 1
|
||||
;;
|
||||
list) find %UTILDIR% -maxdepth 1 -type f -a -executable -a -printf "%P\n" | grep -vF . | sort | tr '\n' ' '
|
||||
echo
|
||||
return 0
|
||||
;;
|
||||
*) if [ -x "%UTILDIR%/$1" ] ; then
|
||||
%UTILDIR%/"$@"
|
||||
return $?
|
||||
else
|
||||
echo Unknown command "$1"
|
||||
return 1
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
}
|
||||
|
||||
if [ "$#" -eq 0 ] ; then
|
||||
while read -e -p "ibmtss> " -a line ; do
|
||||
if [ "${#line[@]}" -gt 0 ] ; then
|
||||
do_exec "" "${line[@]}"
|
||||
fi
|
||||
done
|
||||
echo
|
||||
else
|
||||
do_exec $0 "$@"
|
||||
exit $?
|
||||
fi
|
24
ibmtss.1
Normal file
24
ibmtss.1
Normal file
@ -0,0 +1,24 @@
|
||||
.TH IBMTSS 2.0 utilities \" -*- nroff -*-
|
||||
.SH NAME
|
||||
ibmtss \- call an IBM TSS 2.0 utility function
|
||||
.SH SYNOPSIS
|
||||
.B ibmtss [command [arguments]]
|
||||
.SH DESCRIPTION
|
||||
.B ibmtss
|
||||
includes over 100 subcommands.
|
||||
.PP
|
||||
To list avaialble command use the
|
||||
.B list
|
||||
command.
|
||||
.PP
|
||||
To obtain command help use the
|
||||
.B -h
|
||||
argument.
|
||||
.PP
|
||||
Run without a command to start a basic shell in which commands can be entered.
|
||||
.PP
|
||||
Accompanying certificates and policy files are available in
|
||||
.B %DATADIR%
|
||||
.SH "SEE ALSO"
|
||||
The documentation provided with the package is available in
|
||||
%DOCDIR%/ibmtss.doc
|
7
ibmtss.changes
Normal file
7
ibmtss.changes
Normal file
@ -0,0 +1,7 @@
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 27 11:44:04 UTC 2017 - msuchanek@suse.com
|
||||
|
||||
- Import v713
|
||||
- Move to libdir and add wrapper script.
|
||||
- repack source without makefile-beam which has incompatible
|
||||
license and is not used in build anyway
|
101
ibmtss.spec
Normal file
101
ibmtss.spec
Normal file
@ -0,0 +1,101 @@
|
||||
#
|
||||
# spec file for package ibmtss
|
||||
#
|
||||
# Copyright (c) 2017 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||
#
|
||||
# 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 http://bugs.opensuse.org/
|
||||
#
|
||||
%define suite ibmtss
|
||||
|
||||
Name: ibmtss
|
||||
Version: 713
|
||||
Release: 0
|
||||
License: BSD-3-Clause
|
||||
Summary: IBM's TPM 2.0 TSS
|
||||
Url: https://sourceforge.net/projects/ibmtpm20tss/
|
||||
Group: Productivity/Security
|
||||
Source: %{name}%{version}.tar
|
||||
Patch: makefile.patch
|
||||
Source1: %{name}
|
||||
Source2: %{name}.1
|
||||
BuildRequires: libopenssl-devel >= 1.0, libopenssl-devel <= 1.1
|
||||
%ifnarch s390x s390 ppc64 ppc
|
||||
BuildRequires: ibmswtpm2
|
||||
%define test 1
|
||||
%else
|
||||
%define test ""
|
||||
%endif
|
||||
Recommends: %{name}-base = %{version}
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
|
||||
%description
|
||||
This is a user space TSS for TPM 2.0. It implements the functionality equivalent to the TCG TSS working group's planned ESAPI, SAPI, and TCTI API's.
|
||||
|
||||
It comes with over 100 "TPM tools" that can be used for scripted apps, rapid prototyping, education, and debugging.
|
||||
|
||||
%prep
|
||||
%setup -c -q
|
||||
%patch -p 1
|
||||
|
||||
%build
|
||||
cd utils
|
||||
[ -n "%{test}" ] && { %{_libexecdir}/%{suite}/tpm_server & tpm_server="$!" ; }
|
||||
CCFLAGS="%{optflags}" make LNAFLAGS="-Wl,-rpath,%{_libexecdir}/%{suite}" %{?_smp_mflags}
|
||||
[ -n "%{test}" ] && { TPM_INTERFACE_TYPE=socsim LD_LIBRARY_PATH=. ./reg.sh || testfailed=$? ; }
|
||||
[ -n "%{test}" ] && kill "$tpm_server" || :
|
||||
[ -n "$testfailed" ] && return $testfailed
|
||||
|
||||
%install
|
||||
cd utils
|
||||
install -m 755 -D -t %{buildroot}/%{_libexecdir}/%{suite} libtss.so
|
||||
install -m 755 -D -t %{buildroot}/%{_libexecdir}/%{suite} activatecredential certify changeeps changepps clear clearcontrol clockrateadjust clockset contextload contextsave create createek createprimary dictionaryattacklockreset dictionaryattackparameters duplicate eccparameters encryptdecrypt eventextend eventsequencecomplete evictcontrol flushcontext getcapability getcommandauditdigest getrandom getsessionauditdigest gettime hash hashsequencestart hierarchychangeauth hierarchycontrol hmac hmacstart import load loadexternal makecredential nvcertify nvchangeauth nvdefinespace nvextend nvglobalwritelock nvincrement nvread nvreadlock nvreadpublic nvsetbits nvundefinespace nvundefinespacespecial nvwrite nvwritelock objectchangeauth pcrallocate pcrevent pcrextend pcrread pcrreset policyauthorize policyauthvalue policycommandcode policycountertimer policycphash policygetdigest policymaker policymakerpcr policynv policynvwritten policyor policypassword policypcr policyrestart policysecret policysigned policyticket powerup quote readclock readpublic returncode rewrap rsadecrypt rsaencrypt sequencecomplete sequenceupdate setprimarypolicy shutdown sign signapp startauthsession startup stirrandom unseal verifysignature writeapp
|
||||
mkdir -p %{buildroot}/%{_datadir}/%{suite}
|
||||
cp -a policies certificates %{buildroot}/%{_datadir}/%{suite}
|
||||
mkdir -p %{buildroot}/%{_includedir}/%{suite}
|
||||
cp -a tss2 *.h %{buildroot}/%{_includedir}/%{suite}
|
||||
install -p -D -m 755 %{SOURCE1} %{buildroot}/%{_bindir}/%{suite}
|
||||
install -p -D -m 644 %{SOURCE1}.1 %{buildroot}/%{_mandir}/man1/%{suite}.1
|
||||
sed -i -e s,%UTILDIR%,%{_libexecdir}/%{suite},g -e s,%DATADIR%,%{_datadir}/%{suite},g -e s,%DOCDIR%,%{_docdir}/%{name},g \
|
||||
%{buildroot}/%{_bindir}/%{suite} %{buildroot}/%{_mandir}/man1/%{suite}.1
|
||||
|
||||
%post
|
||||
|
||||
%postun
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%doc ibmtss.doc LICENSE
|
||||
%{_libexecdir}/%{suite}
|
||||
%{_bindir}/%{suite}
|
||||
%{_mandir}/man1/%{suite}.1*
|
||||
|
||||
%package base
|
||||
Summary: IBM's TPM 2.0 TSS shared files
|
||||
BuildArch: noarch
|
||||
%description base
|
||||
Includes IBM's TPM 2.0 TSS certificates and policy files.
|
||||
%files base
|
||||
%defattr(-,root,root)
|
||||
%doc LICENSE
|
||||
%{_datadir}/%{suite}
|
||||
|
||||
%package devel
|
||||
Summary: IBM's TPM 2.0 TSS headers
|
||||
Group: Development/Libraries
|
||||
Requires: %{suite} = %{version}
|
||||
%description devel
|
||||
Includes IBM's TPM 2.0 TSS certificates and policy files.
|
||||
%files devel
|
||||
%defattr(-,root,root)
|
||||
%doc LICENSE
|
||||
%{_includedir}/%{suite}
|
||||
|
3
ibmtss713.tar
Normal file
3
ibmtss713.tar
Normal file
@ -0,0 +1,3 @@
|
||||
version https://git-lfs.github.com/spec/v1
|
||||
oid sha256:4d464252a1fce8b2302887cc02e3864b15eb1d071ddf4e028d35c4ba08cd1b0f
|
||||
size 5447680
|
25
makefile.patch
Normal file
25
makefile.patch
Normal file
@ -0,0 +1,25 @@
|
||||
--- ibmtss713/utils/makefile-common~ 2016-08-09 22:28:08.000000000 +0200
|
||||
+++ ibmtss713/utils/makefile-common 2017-01-30 16:36:53.844633306 +0100
|
||||
@@ -43,7 +43,7 @@
|
||||
|
||||
CCFLAGS += \
|
||||
-Wall -W -Wmissing-declarations -Wmissing-prototypes -Wnested-externs \
|
||||
- -ggdb -O0 -c \
|
||||
+ -ggdb -fno-strict-aliasing -c \
|
||||
-DTPM_BITFIELD_LE \
|
||||
-DTPM_ENCRYPT_SESSIONS_DEFAULT="\"0\""
|
||||
|
||||
--- ibmtss713/utils/makefile~ 2016-08-09 22:28:08.000000000 +0200
|
||||
+++ ibmtss713/utils/makefile 2017-01-30 16:46:22.512727982 +0100
|
||||
@@ -44,9 +44,8 @@
|
||||
|
||||
# compile - common flags for TSS library and applications
|
||||
|
||||
-CCFLAGS = -DTPM_POSIX
|
||||
-
|
||||
-# -DTPM_INTERFACE_TYPE_DEFAULT="\"dev\""
|
||||
+CCFLAGS += -DTPM_POSIX \
|
||||
+ -DTPM_INTERFACE_TYPE_DEFAULT="\"dev\""
|
||||
|
||||
# compile - for TSS library
|
||||
|
Loading…
x
Reference in New Issue
Block a user