summaryrefslogtreecommitdiff
path: root/debian/openssh-server.config
diff options
context:
space:
mode:
Diffstat (limited to 'debian/openssh-server.config')
-rw-r--r--debian/openssh-server.config41
1 files changed, 0 insertions, 41 deletions
diff --git a/debian/openssh-server.config b/debian/openssh-server.config
deleted file mode 100644
index 3cbcf6ea6..000000000
--- a/debian/openssh-server.config
+++ /dev/null
@@ -1,41 +0,0 @@
1#!/bin/sh
2
3action=$1
4version=$2
5
6# Source debconf library.
7. /usr/share/debconf/confmodule
8db_version 2.0
9
10
11get_config_option() {
12 option="$1"
13
14 [ -f /etc/ssh/sshd_config ] || return
15
16 # TODO: actually only one '=' allowed after option
17 perl -ne 'print if s/^[[:space:]]*'"$option"'[[:space:]=]+//i' \
18 /etc/ssh/sshd_config 2>/dev/null
19}
20
21
22if [ -e /etc/ssh/sshd_config ]
23then
24 # An empty version means we're upgrading from before the package split,
25 # so check.
26 if dpkg --compare-versions "$version" lt 1:3.8.1p1-11
27 then
28 passwordauth="$(get_config_option PasswordAuthentication)"
29 crauth="$(get_config_option ChallengeResponseAuthentication)"
30 if [ "$passwordauth" = no ] && \
31 ([ -z "$crauth" ] || [ "$crauth" = yes ])
32 then
33 db_input critical ssh/disable_cr_auth || true
34 fi
35 fi
36fi
37
38
39db_go
40
41exit 0