From fc88194eca412788a41ce048b09db2265fdbf7ef Mon Sep 17 00:00:00 2001 From: "kevin.tanguy" Date: Thu, 14 Feb 2019 14:22:55 +0100 Subject: [PATCH] properly purge remaining config files on purge --- debian/control | 4 ++-- debian/postrm | 18 ++++++++++++++++++ 2 files changed, 20 insertions(+), 2 deletions(-) create mode 100644 debian/postrm diff --git a/debian/control b/debian/control index 93a2e49..e6dcdd1 100644 --- a/debian/control +++ b/debian/control @@ -11,7 +11,7 @@ Vcs-Browser: https://github.com/ovh/debian-cis/ Package: cis-hardening Architecture: all Depends: ${misc:Depends}, bc, patch -Description: Suite of configurable scripts to audit or harden a Debian Wheezy or Jessie. - Modular Debian 7/8 security hardening scripts based on cisecurity.org +Description: Suite of configurable scripts to audit or harden a Debian. + Modular Debian security hardening scripts based on cisecurity.org ⟨cisecurity.org⟩ recommendations. We use it at OVH ⟨https://www.ovh.com⟩ to harden our PCI-DSS infrastructure. diff --git a/debian/postrm b/debian/postrm new file mode 100644 index 0000000..d2eefaf --- /dev/null +++ b/debian/postrm @@ -0,0 +1,18 @@ +#!/bin/sh +set -e + +case "$1" in + + purge) + rm -f /opt/cis-hardening/etc/conf.d/*.cfg + ;; + + remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear) + # nothing to do + ;; + + *) + echo "$0 called with unknown argument \`$1\`'" >&2 + exit 1 + ;; +esac