Invert check for ssh hardening config

configureSsh() was never actually doing anything, as the hardening config does not exist in a default ssh setup.
This commit is contained in:
bom 2022-07-13 10:56:44 +02:00
parent a94cbc24b0
commit 93933af0d0

View file

@ -25,7 +25,7 @@ fun Prov.isSshdHardeningConfigExisting(): Boolean {
}
fun Prov.configureSsh() = task {
if(isSshdConfigExisting() && isSshConfigExisting() && isSshdHardeningConfigExisting() && isPackageInstalled(packageNameSshServer)) {
if(isSshdConfigExisting() && isSshConfigExisting() && !isSshdHardeningConfigExisting() && isPackageInstalled(packageNameSshServer)) {
createFileFromResource(
pathSshConfig,
"ssh_config",