swtpm/samples/Makefile.am
Stefan Berger cc410ca91b swtpm_setup: Switch over to new python tool and get rid of the bash script
Switch over to the new python implementation of swtpm_setup. We need to
also adjust test cases that involved the tcsd that otherwise fail for
various reasons. For in-place testing we need to adjust the PYTHONPATH
and PATH so that swtpm_setup.py can be found and so that swtpm_setup.py
then finds swtpm if it is not explicitly passed as parameter.

Adjust the man page for swtpm_setup to reflect the changes.

We now can run swtpm_setup as any user. However, libvirt still runs it
as tss:tss (for example), which is then creating the signing key as tss:tss
as well. Ideally libvirt would run it as tss:root or any other combination
since the tss group may be used for user wanting to access /dev/tpmrm0 for
example. We at least change the directory ownership of /var/lib/swtpm-localca
to tss:root and keep the world out of this directory.

Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
2020-08-28 16:27:15 -04:00

32 lines
728 B
Makefile

#
# samples/Makefile.am
#
# For the license, see the LICENSE file in the root directory.
#
samplesconfdir = $(datadir)/@PACKAGE@
samplessysconfdir = $(sysconfdir)
samplesconf_SCRIPTS = \
swtpm-create-tpmca \
swtpm-create-user-config-files \
swtpm-localca
samplessysconf_DATA = \
swtpm-localca.conf \
swtpm-localca.options
install-data-local:
$(MKDIR_P) $(DESTDIR)$(localstatedir)/lib/swtpm-localca
if test -z $(DESTDIR); then \
chown -R @TSS_USER@:root $(DESTDIR)$(localstatedir)/lib/swtpm-localca || true; \
chmod 0750 $(DESTDIR)$(localstatedir)/lib/swtpm-localca || true; \
fi
EXTRA_DIST= \
swtpm-create-tpmca \
swtpm-create-user-config-files \
swtpm-localca \
swtpm-localca.conf \
swtpm-localca.options