Commit Graph

9 Commits

Author SHA1 Message Date
Lena Voytek
3d2747a1be debian: Add swtpm apparmor profile
An apparmor profile was added for Debian-based distributions in order to
increase security. This blocks swtpm from accessing restricted and unnecessary
files, folders, and network interfaces. swtpm works as normal alongside libvirt
and its configurations, however users may run into issues when using swtpm on
its own when providing it with a restricted directory. The apparmor profile can
be modified to include additional permissions by creating and adding to the
file /etc/apparmor.d/local/usr.bin.swtpm.

Signed-off-by: Lena Voytek <lena.voytek@canonical.com>
2022-05-05 20:58:30 -04:00
Nick Chevsky
3d5ae5e1d6 Change swtpm-localca to swtpm_localca in manpages
- Move content of swtpm-localca(8) manual page to swtpm_localca(8)
  and make swtpm-localca(8) an alias for swtpm_localca(8), mirroring
  the fact that /usr/bin/swtpm_localca is the actual program and
  /usr/share/swtpm/swtpm-localca a wrapper for it.
- Change references to `swtpm-localca` in manual pages' content to
  `swtpm_localca`, reflecting the actual name of the program they are
  meant to document.

Signed-off-by: Nick Chevsky <nchevsky@users.noreply.github.com>
2021-07-27 20:05:41 -04:00
Nick Chevsky
4eb47cb0ca Debian packaging improvements
- debian/clean: Add files that were not being automatically cleaned
  up by dh(1)'s `clean` target.
- debian/control:
  - Add new recommended/required fields and bump Standards-Version.
  - Remove redundant build dependencies that are implied transitively.
  - Bump debhelper dependency version to match debian/compat.
  - Move swtpm-libs's ${misc:Pre-Depends} dependency to `Pre-Depends`.
    Resolves `depends-on-misc-pre-depends` Lintian warning.
  - Sort packages and dependency lists alphabetically as per
    wrap-and-sort(1).
- debian/not-installed: List deliberately non-installed files to
  avoid dh_missing(1) warnings.
- debian/rules:
  - Pass --no-scripts to dh_makeshlibs(1) in order to keep a
    ldconfig(8) trigger from being implicitly added, which for
    this package was redundant and triggered Lintian warning
    `package-has-unnecessary-activation-of-ldconfig-trigger`.
  - Remove redundant --parallel dh flag.
  - Remove redundant dh_usrlocal override.
- debian/*.install:
  - Add swtpm-create-tpmca(8) and its manpage, which were missing.
  - Remove redundant `#! /usr/bin/dh-exec` lines.
  - Sort entries alphabetically as per wrap-and-sort(1).
- debian/swtpm-tools.postinst.in: Add `set -e` to fail in case of
  error. Fixes `maintainer-script-ignores-errors` Lintian warning.

Signed-off-by: Nick Chevsky <nchevsky@users.noreply.github.com>
2021-07-26 17:22:41 -04:00
Stefan Berger
27d3fc877b Debian: Remove CUSE TPM from build and adjust rules file
Remove the CUSE TPM from the build and adjust the rules file
so that the build works on Ubuntu servers for example.

Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
2020-02-17 12:11:31 -05:00
Stefan Berger
9e8e018145 debian: Fix libtpms0 dependency and force gnutls availability
Libtpms is now libtpms0 as a dependency.
Gnutls is neede for swtpm_cert to create the certs. Force it to
be available.

Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
2019-01-28 17:03:26 -05:00
Stefan Berger
dea49eb3e6 debian: Use autogen.sh
Use autogen.sh when building a Debian package.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2018-09-13 09:28:15 -04:00
Stefan Berger
2cd10cee2f build: fix Debian packaging if swtpm_cert is missing
Fix the Debian packaging if swtpm_cert is missing. We convert
swtpm-tools.install into an executable shell script that displays
all files to package.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2016-09-27 17:26:08 -04:00
Stefan Berger
699c204323 build: Exclude swtpm_cert from Debian package if not found
Exclude the swtpm_cert tool and its man page if it is not found
due to it not being compiled due to backlevel gnutls library.

Signed-off-by: Stefan Berger <stefanb@linux.vnet.ibm.com>
2016-01-13 16:23:08 -05:00
Stefan Berger
dcbb1181fb build: Enable building of Debian package
Add debian build files to enable building of Debian package using for exampl

debuild -b   or   dpkg-buildpackage -us -uc

Extend the .gitignore.

The debhelper checks show warnings and errors that will need to be addressed
some other time. For some I don't know how to solve them at the moment.

Signed-off-by: Stefan Berger <stefanb@linux.watson.ibm.com>
2016-01-12 19:56:00 -05:00