Merge ~enr0n/ubuntu/+source/openssh:generator-v3 into ubuntu/+source/openssh:ubuntu/devel

Proposed by Nick Rosbrook
Status: Merged
Merged at revision: f29f3057cc20e93124eef7e1034d72026601d3f1
Proposed branch: ~enr0n/ubuntu/+source/openssh:generator-v3
Merge into: ubuntu/+source/openssh:ubuntu/devel
Diff against target: 1585 lines (+572/-621)
29 files modified
debian/README.Debian (+12/-13)
debian/changelog (+27/-0)
debian/control (+1/-0)
debian/openssh-server.install (+2/-0)
debian/openssh-server.postinst (+27/-171)
debian/openssh-server.postrm (+0/-4)
debian/openssh-server.templates (+0/-12)
debian/openssh-server.ucf-md5sum (+6/-0)
debian/patches/series (+1/-1)
debian/patches/sshd-socket-generator.patch (+363/-0)
debian/po/cs.po (+1/-26)
debian/po/da.po (+1/-26)
debian/po/de.po (+1/-26)
debian/po/es.po (+1/-26)
debian/po/fr.po (+1/-26)
debian/po/it.po (+1/-26)
debian/po/ja.po (+1/-26)
debian/po/nl.po (+1/-26)
debian/po/pt.po (+1/-26)
debian/po/pt_BR.po (+1/-26)
debian/po/ru.po (+3/-28)
debian/po/sv.po (+1/-26)
debian/po/templates.pot (+2/-27)
debian/po/tr.po (+2/-27)
debian/rules (+1/-1)
debian/systemd/ssh.socket (+3/-1)
debian/tests/control (+6/-0)
debian/tests/sshd-socket-generator (+105/-0)
dev/null (+0/-50)
Reviewer Review Type Date Requested Status
Steve Langasek (community) Approve
Review via email: mp+460543@code.launchpad.net

Description of the change

Add sshd-socket-generator, which generates ListenStream= overrides by parsing sshd_config, rather than writing the override once on package upgrade.

To post a comment you must log in.
Revision history for this message
Steve Langasek (vorlon) :
review: Needs Fixing
Revision history for this message
Nick Rosbrook (enr0n) wrote :

Thanks for reviewing, Steve. Replied to inline comments.

Revision history for this message
Nick Rosbrook (enr0n) wrote :

And pushed new changes.

Revision history for this message
Steve Langasek (vorlon) wrote :

Thanks, you've addressed the fails-to-start-on-boot issue brilliantly, I didn't realize there was a solution for this in systemd unit syntax (and wonder whether FreeBind=yes shouldn't be the default?)

I can't think of any other blockers for this to be an unconditional switch to socket activation as multiple listen addresses was the only case where we didn't already do the upgrade automatically.

I'm going to tag in Robie from server for an additional review since he had good feedback on the first iteration of this and would be a good second set of eyes.

I have not done an in-depth review of the C code. Do you want that from me here?

Revision history for this message
Nick Rosbrook (enr0n) wrote :

> I have not done an in-depth review of the C code. Do you want that from me
> here?

The more review the better, but I understand your time is valuable :D

Revision history for this message
Nick Rosbrook (enr0n) :
Revision history for this message
Steve Langasek (vorlon) wrote :

Marking approved, others in the team can also review C code if you need it (and I know Debian upstream will give you a solid review when you forward this)

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/debian/README.Debian b/debian/README.Debian
index 8067852..70c588f 100644
--- a/debian/README.Debian
+++ b/debian/README.Debian
@@ -186,27 +186,26 @@ Socket-based activation with systemd
186186
187By default, socket-based activation is used on systems that use systemd.187By default, socket-based activation is used on systems that use systemd.
188188
189The provided ssh.socket unit file sets ListenStream=22. If you need to have189The provided ssh.socket unit file sets ListenStream=22. A systemd generator,
190it listen on a different address or port, then you will need to do this as190sshd-socket-generator, parses the sshd configuration and, if non-default
191follows (modifying ListenStream to match your requirements):191ListenAddress(s) or Port(s) are configured, generates corresponding
192192ListenStream= lines in a drop-in configration file for ssh.socket. To change
193 mkdir -p /etc/systemd/system/ssh.socket.d193the port or address ssh.socket is listening on, edit /etc/ssh/sshd_config (or
194 cat >/etc/systemd/system/ssh.socket.d/listen.conf <<EOF194add a drop-in file to /etc/ssh/sshd_config.d/) as usual and then run:
195 [Socket]195
196 ListenStream=2222
197 EOF
198 systemctl daemon-reload196 systemctl daemon-reload
199 systemctl restart ssh.socket197 systemctl restart ssh.socket
200198
201See systemd.socket(5) for details.199See systemd.socket(5) for details.
202200
203If you do not want to use socket activation for ssh on your system, you201If you do not want to use socket activation for ssh on your system, you
204can disable socket activation by running:202can disable socket activation by masking the generator and re-enabling
203ssh.service:
205204
206 systemctl disable --now ssh.socket205 mkdir -p /etc/systemd/system-generators/
207 rm -f /etc/systemd/system/ssh.service.d/00-socket.conf206 ln -s /dev/null /etc/systemd/system-generators/sshd-socket-generator
208 rm -f /etc/systemd/system/ssh.socket.d/addresses.conf
209 systemctl daemon-reload207 systemctl daemon-reload
208 systemctl disable --now ssh.socket
210 systemctl enable --now ssh.service209 systemctl enable --now ssh.service
211210
212Terminating SSH sessions cleanly on shutdown/reboot with systemd211Terminating SSH sessions cleanly on shutdown/reboot with systemd
diff --git a/debian/changelog b/debian/changelog
index eaaedcc..68dc34f 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,30 @@
1openssh (1:9.6p1-3ubuntu3) noble; urgency=medium
2
3 * Add sshd-socket-generator to generate ssh.socket drop-in configuration
4 instead of doing one-time generation on package upgrade:
5 - debian/control: Build-Depends: systemd-dev
6 - d/p/sshd-socket-generator.patch: add generator for socket activation
7 - debian/openssh-server.install: install sshd-socket-generator
8 - debian/openssh-server.postinst: handle migration to sshd-socket-generator
9 - d/t/sshd-socket-generator: add dep8 test for sshd-socket-generator
10 - ssh.socket: adjust unit for socket activation by default
11 - debian/README.Debian: update ssh.socket documentation
12 - debian/rules: explicitly enable LTO
13 The armhf build was not using LTO, which made sshd-socket-generator FTBFS.
14 This change ensures that all arches are using LTO.
15 * Drop the following changes related to previous ssh socket activation approach:
16 - debian/openssh-server.postrm: remove systemd drop-ins for
17 socket-activated sshd on purge
18 - debian/openssh-server.templates: include debconf prompt explaining
19 when migration cannot happen due to multiple ListenAddress values
20 - debian/openssh-server.postinst: handle migration of sshd_config options
21 to systemd socket options on upgrade.
22 - debian/patches/socket-activation-documentation.patch: Document in
23 sshd_config(5) that ListenAddress and Port no longer work.
24 * debian/openssh-server.ucf-md5sum: update for new Ubuntu delta
25
26 -- Nick Rosbrook <enr0n@ubuntu.com> Wed, 21 Feb 2024 12:51:30 -0500
27
1openssh (1:9.6p1-3ubuntu2) noble; urgency=medium28openssh (1:9.6p1-3ubuntu2) noble; urgency=medium
229
3 [ Marco Trevisan (Treviño) ]30 [ Marco Trevisan (Treviño) ]
diff --git a/debian/control b/debian/control
index e93b516..58e9a89 100644
--- a/debian/control
+++ b/debian/control
@@ -20,6 +20,7 @@ Build-Depends: debhelper (>= 13.1~),
20 libwrap0-dev | libwrap-dev,20 libwrap0-dev | libwrap-dev,
21 pkg-config,21 pkg-config,
22 zlib1g-dev,22 zlib1g-dev,
23 systemd-dev,
23Standards-Version: 4.6.224Standards-Version: 4.6.2
24Uploaders: Colin Watson <cjwatson@debian.org>,25Uploaders: Colin Watson <cjwatson@debian.org>,
25 Matthew Vernon <matthew@debian.org>,26 Matthew Vernon <matthew@debian.org>,
diff --git a/debian/openssh-server.install b/debian/openssh-server.install
index cf86dce..9942604 100755
--- a/debian/openssh-server.install
+++ b/debian/openssh-server.install
@@ -19,3 +19,5 @@ debian/systemd/ssh-session-cleanup usr/lib/openssh
19# dh_apport would be neater, but at the time of writing it isn't in unstable19# dh_apport would be neater, but at the time of writing it isn't in unstable
20# yet.20# yet.
21debian/openssh-server.apport => usr/share/apport/package-hooks/openssh-server.py21debian/openssh-server.apport => usr/share/apport/package-hooks/openssh-server.py
22
23usr/lib/systemd/system-generators/sshd-socket-generator
diff --git a/debian/openssh-server.postinst b/debian/openssh-server.postinst
index cb9a301..251f11c 100644
--- a/debian/openssh-server.postinst
+++ b/debian/openssh-server.postinst
@@ -17,87 +17,6 @@ get_config_option() {
17 /usr/sbin/sshd -G | sed -n "s/^$option //Ip"17 /usr/sbin/sshd -G | sed -n "s/^$option //Ip"
18}18}
1919
20get_config_option_all() {
21 option="$1"
22 file="$2"
23
24 if [ -z "$file" ]; then
25 file=/etc/ssh/sshd_config
26 fi
27
28 [ -f "$file" ] || return 0
29 # ListenAddress and Port only take a single word argument so anything
30 # after this must be a comment
31 while read option2 value junk; do
32 case $option2 in
33 $option)
34 echo $value
35 ;;
36 Include)
37 # globs
38 for f in $value; do
39 get_config_option_all "$option" "$f"
40 done
41 ;;
42 esac
43 done < $file
44}
45
46hostnames_to_addresses() {
47 addresses="$1"
48 for address in $addresses; do
49 address_no_port="$(address_strip_port $address)"
50 if echo "$address_no_port" | grep -q '^[0-9a-f:]\+$\|^[0-9.]\+$'; then
51 numeric_addresses="$numeric_addresses $address"
52 else
53 new_addresses=$( (getent ahostsv4 $address_no_port;
54 getent ahostsv6 $address_no_port) \
55 | awk '$1 ~ /^::ffff:/ || $2 != "STREAM" { next; }
56 $1 ~ /:/ { print "[" $1 "]"; next; }
57 { print $1 }' \
58 | sort -u)
59 port="$(port_from_address $address)"
60 if [ -n "$port" ]; then
61 new_addresses="$(for addr in $new_addresses; do echo $addr:$port; done)"
62 fi
63 numeric_addresses="$numeric_addresses $new_addresses"
64 fi
65 done
66 echo "$numeric_addresses"
67}
68
69port_from_address() {
70 address="$1"
71 if echo $address | grep -q '^\[[0-9a-f:]*\]:'; then
72 # This is an IPv6 address with a port.
73 port="$(echo $address | awk -F':' '{print $NF}')"
74 elif echo $address | grep -q '^\[[0-9a-f:]*\]\+$\|^[0-9a-f:]\+$'; then
75 # This is an IPv6 address without a port.
76 port=""
77 else
78 # This is an IPv4 address or hostname, where the port
79 # may or may not be specified.
80 port="$(echo $address | awk -F':' '{print $2}')"
81 fi
82 echo "$port"
83}
84
85address_strip_port() {
86 address="$1"
87 if echo $address | grep -q '^\[[0-9a-f:]*\]\(:\|$\)'; then
88 # This is an IPv6 address in brackets, with or without a port.
89 address_no_port="$(echo $address | awk -F '[][]' '{print $2}')"
90 elif echo $address | grep -q '^[0-9a-f:]\+$'; then
91 # This is an IPv6 address with no brackets and no port.
92 address_no_port="$address"
93 else
94 # This is an IPv4 address or hostname, where the port
95 # may or may not be specified.
96 address_no_port="$(echo $address | awk -F':' '{print $1}')"
97 fi
98 echo "$address_no_port"
99}
100
10120
102create_key() {21create_key() {
103 msg="$1"22 msg="$1"
@@ -211,102 +130,39 @@ if [ "$action" = configure ]; then
211 # which we now move back into place.130 # which we now move back into place.
212 mv /etc/ssh/moduli.dpkg-bak /etc/ssh/moduli131 mv /etc/ssh/moduli.dpkg-bak /etc/ssh/moduli
213 fi132 fi
214 if dpkg --compare-versions "$2" lt-nl 1:9.0p1-1ubuntu8~133 if dpkg --compare-versions "$2" lt-nl 1:9.6p1-3ubuntu3~; then
215 then134 # Remove old socket activation drop-in configurations, if they exist.
216 # migrate to systemd socket activation.135 if [ -d /etc/systemd/system/ssh.socket.d ]; then
217 addresses=$(get_config_option_all ListenAddress)136 rm -f /etc/systemd/system/ssh.socket.d/addresses.conf
218 addresses=$(hostnames_to_addresses "$addresses")137 rmdir --ignore-fail-on-non-empty /etc/systemd/system/ssh.socket.d
219 ports=$(get_config_option_all Port)138 fi
220 if [ -n "$addresses$ports" ]139 if [ -d /etc/systemd/system/ssh.service.d ]; then
221 then140 rm -f /etc/systemd/system/ssh.service.d/00-socket.conf
222 override_dir=/etc/systemd/system/ssh.socket.d141 rmdir --ignore-fail-on-non-empty /etc/systemd/system/ssh.service.d
223 mkdir -p "$override_dir"142 fi
224 echo '[Socket]' > "$override_dir"/addresses.conf.new143 if [ -d /run/systemd/system ]; then
225 echo 'ListenStream=' >> "$override_dir"/addresses.conf.new144 # Make sure ssh.service is disabled.
226 fi145 systemctl unmask ssh.service
227 if [ -n "$addresses" ]; then146 systemctl disable --now ssh.service > /dev/null 2>&1
228 [ -n "$ports" ] || ports=22147
229 count=0148 # sshd-socket-generator is invoked on daemon-reload.
230 for address in $addresses; do149 systemctl daemon-reload
231 count=$((count+1))150 systemctl enable ssh.socket
232 port_from_address="$(port_from_address $address)"151 fi
233 if [ -z "$port_from_address" ]; then
234 for port in $ports; do
235 echo "ListenStream=$address:$port" \
236 >> "$override_dir"/addresses.conf.new
237 done
238 else
239 echo "ListenStream=$address" \
240 >> "$override_dir"/addresses.conf.new
241 fi
242 done
243 if [ $count -gt 1 ]; then
244 db_input critical openssh-server/listenstream-may-fail || true
245 db_go || true
246 rm -f "$override_dir"/addresses.conf.new
247 rmdir --ignore-fail-on-non-empty "$override_dir"
248 NO_SOCKET_MIGRATION=1
249 fi
250 elif [ -n "$ports" ]; then
251 for port in $ports; do
252 echo "ListenStream=$port" \
253 >> "$override_dir"/addresses.conf.new
254 done
255 fi
256
257 if [ -z "$NO_SOCKET_MIGRATION" ] && [ -n "$addresses$ports" ]
258 then
259 mv "$override_dir"/addresses.conf.new \
260 "$override_dir"/addresses.conf
261 fi
262 fi
263 if dpkg --compare-versions "$2" lt 1:9.0p1-1ubuntu5~; then
264 if [ -z "$NO_SOCKET_MIGRATION" ]; then
265 override_dir=/etc/systemd/system/ssh.service.d
266 mkdir -p "$override_dir"
267 echo '[Unit]' > "$override_dir"/00-socket.conf
268 echo 'After=ssh.socket' >> "$override_dir"/00-socket.conf
269 echo 'Requires=ssh.socket' >> "$override_dir"/00-socket.conf
270
271 # deb-systemd-helper is inadequate for the task of
272 # changing policy for the units on upgrade
273 if [ -d /run/systemd/system ]; then
274 systemctl daemon-reload
275 systemctl disable ssh.service
276 systemctl unmask ssh.service
277 systemctl stop ssh.service
278 systemctl enable ssh.socket
279 fi
280 fi
281 fi
282
283 # Revert socket migration if we can determine the user hit
284 # LP: #1993478.
285 if dpkg --compare-versions "$2" lt-nl 1:9.0p1-1ubuntu7~ \
286 && [ -e /etc/systemd/system/ssh.socket.d/addresses.conf ] \
287 && [ -e /etc/systemd/system/ssh.service.d/00-socket.conf ] \
288 && [ -n "$NO_SOCKET_MIGRATION" ]; then
289 rm /etc/systemd/system/ssh.socket.d/addresses.conf
290 rmdir --ignore-fail-on-non-empty /etc/systemd/system/ssh.socket.d
291 rm /etc/systemd/system/ssh.service.d/00-socket.conf
292 rmdir --ignore-fail-on-non-empty /etc/systemd/system/ssh.service.d
293 if [ -d /run/systemd/system ]; then
294 systemctl daemon-reload
295 systemctl disable ssh.socket
296 systemctl stop ssh.socket
297 systemctl enable ssh.service
298 fi
299 fi152 fi
300fi153fi
301154
302#DEBHELPER#155#DEBHELPER#
303156
304if [ -d /run/systemd/system ]; then157if [ -d /run/systemd/system ]; then
305 if deb-systemd-helper --quiet was-enabled ssh.socket; then158 # sshd-socket-generator is invoked on daemon-reload.
306 deb-systemd-invoke restart ssh.socket159 systemctl daemon-reload
307 elif deb-systemd-helper --quiet was-enabled ssh.service; then160
308 deb-systemd-invoke restart ssh.service161 if deb-systemd-helper --quiet was-enabled ssh.socket; then
309 fi162 deb-systemd-invoke restart ssh.socket
163 elif deb-systemd-helper --quiet was-enabled ssh.service; then
164 deb-systemd-invoke restart ssh.service
165 fi
310fi166fi
311167
312db_stop168db_stop
diff --git a/debian/openssh-server.postrm b/debian/openssh-server.postrm
index 46798dd..fbaeb17 100644
--- a/debian/openssh-server.postrm
+++ b/debian/openssh-server.postrm
@@ -23,10 +23,6 @@ case $1 in
23 if command -v ucfr >/dev/null 2>&1; then23 if command -v ucfr >/dev/null 2>&1; then
24 ucfr --purge openssh-server /etc/ssh/sshd_config24 ucfr --purge openssh-server /etc/ssh/sshd_config
25 fi25 fi
26 rm -f /etc/systemd/system/ssh.service.d/00-socket.conf
27 rm -f /etc/systemd/system/ssh.socket.d/addresses.conf
28 rmdir /etc/systemd/system/ssh.service.d || true
29 rmdir /etc/systemd/system/ssh.socket.d || true
30 rm -f /etc/ssh/sshd_not_to_be_run26 rm -f /etc/ssh/sshd_not_to_be_run
31 [ ! -d /etc/ssh ] || rmdir --ignore-fail-on-non-empty /etc/ssh27 [ ! -d /etc/ssh ] || rmdir --ignore-fail-on-non-empty /etc/ssh
3228
diff --git a/debian/openssh-server.templates b/debian/openssh-server.templates
index 31f2935..e071fe3 100644
--- a/debian/openssh-server.templates
+++ b/debian/openssh-server.templates
@@ -21,15 +21,3 @@ Description: Allow password authentication?
21 By default, the SSH server will allow authenticating using a password.21 By default, the SSH server will allow authenticating using a password.
22 You may want to change this if all users on this system authenticate using22 You may want to change this if all users on this system authenticate using
23 a stronger authentication method, such as public keys.23 a stronger authentication method, such as public keys.
24
25Template: openssh-server/listenstream-may-fail
26Type: error
27_Description: Not migrating to socket activation
28 This version of openssh-server uses socket-based activation by default.
29 However, because you have more than one ListenAddress configured in
30 sshd_config, it is impossible to determine at upgrade time if migrating
31 you to socket-based activation would cause the starting of sshd at boot
32 to be unreliable.
33 .
34 Because a failure to start ssh may make it impossible to admininister a
35 system, you will not be migrated to socket-based activation at this time.
diff --git a/debian/openssh-server.ucf-md5sum b/debian/openssh-server.ucf-md5sum
index 9a8efb6..b2c0ac3 100644
--- a/debian/openssh-server.ucf-md5sum
+++ b/debian/openssh-server.ucf-md5sum
@@ -132,3 +132,9 @@ fac56840f6697a357368bb878dd8fb87
132d01da8c9de75176095712d4e37d5dcd5132d01da8c9de75176095712d4e37d5dcd5
133e4898846045f33b8d99d3263d6f6fd81133e4898846045f33b8d99d3263d6f6fd81
134ec46dc59ba9c9e9458add405264fcedd134ec46dc59ba9c9e9458add405264fcedd
135
136# From 1:9.6p1-3ubuntu3
137b8e751f62cf86a18bc30cdaae494b03f
138b89c8626d43128cdb233536439e00566
1395f589fb3658df8cb7cce8505cf821e40
1408d7588b06f81ef23bea8d84442af8e68
diff --git a/debian/patches/series b/debian/patches/series
index aba5430..3d5c5c8 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -26,10 +26,10 @@ maxhostnamelen.patch
26conch-ssh-rsa.patch26conch-ssh-rsa.patch
27systemd-socket-activation.patch27systemd-socket-activation.patch
28broken-zero-call-used-regs.patch28broken-zero-call-used-regs.patch
29socket-activation-documentation.patch
30test-set-UsePAM-no-on-some-tests.patch29test-set-UsePAM-no-on-some-tests.patch
31auth-Add-KbdintResult-definition-to-define-result-values-.patch30auth-Add-KbdintResult-definition-to-define-result-values-.patch
32auth-pam-Add-an-enum-to-define-the-PAM-done-status.patch31auth-pam-Add-an-enum-to-define-the-PAM-done-status.patch
33auth-pam-Add-debugging-information-when-we-receive-PAM-me.patch32auth-pam-Add-debugging-information-when-we-receive-PAM-me.patch
34auth-pam-Immediately-report-interactive-instructions-to-c.patch33auth-pam-Immediately-report-interactive-instructions-to-c.patch
35sshconnect2-Write-kbd-interactive-service-info-and-instru.patch34sshconnect2-Write-kbd-interactive-service-info-and-instru.patch
35sshd-socket-generator.patch
diff --git a/debian/patches/socket-activation-documentation.patch b/debian/patches/socket-activation-documentation.patch
36deleted file mode 10064436deleted file mode 100644
index 9afde55..0000000
--- a/debian/patches/socket-activation-documentation.patch
+++ /dev/null
@@ -1,50 +0,0 @@
1Index: openssh-9.0p1/sshd_config.5
2===================================================================
3--- openssh-9.0p1.orig/sshd_config.5
4+++ openssh-9.0p1/sshd_config.5
5@@ -1069,6 +1069,15 @@
6 Multiple
7 .Cm ListenAddress
8 options are permitted.
9+.Pp
10+.Cm Note:
11+On Ubuntu, the openssh-server package is configured to use systemd
12+socket-based activation by default. Therefore if you are using systemd with
13+the default configuration,
14+.Cm ListenAddress
15+options will not be honored. Address configuration must be handled in
16+.Pa /etc/systemd/system/ssh.socket.d
17+instead.
18 .It Cm LoginGraceTime
19 The server disconnects after this time if the user has not
20 successfully logged in.
21@@ -1520,6 +1529,15 @@
22 Multiple options of this type are permitted.
23 See also
24 .Cm ListenAddress .
25+.Pp
26+.Cm Note:
27+On Ubuntu, the openssh-server package is configured to use systemd
28+socket-based activation by default. Therefore if you are using systemd with
29+the default configuration,
30+.Cm Port
31+options will not be honored. Address configuration must be handled in
32+.Pa /etc/systemd/system/ssh.socket.d
33+instead.
34 .It Cm PrintLastLog
35 Specifies whether
36 .Xr sshd 8
37Index: openssh-9.0p1/sshd_config
38===================================================================
39--- openssh-9.0p1.orig/sshd_config
40+++ openssh-9.0p1/sshd_config
41@@ -12,6 +12,9 @@
42
43 Include /etc/ssh/sshd_config.d/*.conf
44
45+# Port and ListenAddress options are not used when sshd is socket-activated,
46+# which is now the default in Ubuntu. See sshd_config(5) and
47+# /usr/share/doc/openssh-server/README.Debian.gz for details.
48 #Port 22
49 #AddressFamily any
50 #ListenAddress 0.0.0.0
diff --git a/debian/patches/sshd-socket-generator.patch b/debian/patches/sshd-socket-generator.patch
51new file mode 1006440new file mode 100644
index 0000000..ae3692c
--- /dev/null
+++ b/debian/patches/sshd-socket-generator.patch
@@ -0,0 +1,363 @@
1--- /dev/null
2+++ b/sshd-socket-generator.c
3@@ -0,0 +1,290 @@
4+#include <errno.h>
5+#include <linux/limits.h>
6+#include <netdb.h>
7+#include <stdbool.h>
8+#include <stdio.h>
9+#include <stdlib.h>
10+#include <string.h>
11+#include <sys/socket.h>
12+#include <sys/stat.h>
13+#include <sys/types.h>
14+
15+#include "includes.h"
16+
17+#include "hostfile.h" /* Needs to be included before auth.h */
18+#include "auth.h"
19+#include "kex.h"
20+#include "log.h"
21+#include "misc.h"
22+#include "monitor.h"
23+#include "ssh-gss.h" /* Needs to be included before monitor_wrap.h */
24+#include "monitor_wrap.h"
25+#include "pathnames.h"
26+#include "servconf.h"
27+#include "sshbuf.h"
28+
29+#define MAX_LISTEN_STREAMS (16)
30+#define MAX_LISTEN_STREAM_LEN (NI_MAXHOST + NI_MAXSERV + sizeof("ListenAddress=[:]") + 1)
31+typedef char listen_stream_set[MAX_LISTEN_STREAMS][MAX_LISTEN_STREAM_LEN];
32+
33+/* Global variables required for sshd config parsing. */
34+ServerOptions options = {};
35+struct sshbuf *cfg = NULL;
36+struct include_list includes = TAILQ_HEAD_INITIALIZER(includes);
37+
38+/* Other global variables that are required for this to build, because of their
39+ * use throughout the codebase. We do NOT use these variables for the
40+ * generator. */
41+Authctxt *the_authctxt = NULL;
42+int privsep_is_preauth = 1;
43+int use_privsep = -1;
44+struct monitor *pmonitor = NULL;
45+struct ssh *the_active_state = NULL;
46+struct sshauthopt *auth_opts = NULL;
47+struct sshbuf *loginmsg = NULL;
48+
49+static int listen_stream_set_append(listen_stream_set set, const char *listen_stream) {
50+ size_t n;
51+
52+ if (!set)
53+ return -EINVAL;
54+
55+ n = strnlen(listen_stream, MAX_LISTEN_STREAM_LEN);
56+ if (n == MAX_LISTEN_STREAM_LEN)
57+ return -EINVAL;
58+
59+ for (int i = 0; i < MAX_LISTEN_STREAMS; i++) {
60+ if (strcmp(set[i], listen_stream) == 0)
61+ return 0;
62+
63+ if (strnlen(set[i], MAX_LISTEN_STREAM_LEN) > 0)
64+ continue;
65+
66+ memcpy(set[i], listen_stream, n);
67+
68+ return 0;
69+ }
70+
71+ return -E2BIG;
72+}
73+
74+static int listen_stream_set_len(listen_stream_set set) {
75+ int r = 0;
76+
77+ if (!set)
78+ return 0;
79+
80+ for (int i = 0; i < MAX_LISTEN_STREAMS; i++) {
81+ if (strnlen(set[i], MAX_LISTEN_STREAM_LEN) > 0)
82+ r++;
83+ else
84+ break;
85+ }
86+
87+ return r;
88+}
89+
90+static char *path_append(const char *base, const char *append) {
91+ bool add_slash;
92+ size_t n = 0, len_base, len_append;
93+ char *path = NULL;
94+
95+ len_base = strnlen(base, PATH_MAX);
96+ len_append = strnlen(append, PATH_MAX);
97+ add_slash = base[len_base - 1] != '/';
98+
99+ path = calloc(len_base + len_append + (add_slash ? 2 : 1), sizeof(char));
100+ if (!path)
101+ return NULL;
102+
103+ memcpy(path, base, len_base);
104+ n += len_base;
105+
106+ if (add_slash)
107+ path[n++] = '/';
108+
109+ memcpy(path + n, append, len_append);
110+ n += len_append;
111+ path[n] = '\0';
112+
113+ return path;
114+}
115+
116+static int fflush_and_check(FILE *f) {
117+ errno = 0;
118+ fflush(f);
119+
120+ if (ferror(f))
121+ return errno > 0 ? -errno : -EIO;
122+
123+ return 0;
124+}
125+
126+static int write_systemd_socket_file(const char *destdir) {
127+ listen_stream_set listen_streams = {};
128+ int num_listen_streams;
129+ char *conf = NULL, *overridedir = NULL;
130+ FILE *f = NULL;
131+ int r;
132+
133+ overridedir = path_append(destdir, "ssh.socket.d");
134+ if (!overridedir) {
135+ r = -ENOMEM;
136+ goto out;
137+ }
138+
139+ if (mkdir(overridedir, 0755) < 0 && errno != EEXIST) {
140+ r = -errno;
141+ goto out;
142+ }
143+
144+ conf = path_append(overridedir, "addresses.conf");
145+ if (!conf) {
146+ r = -ENOMEM;
147+ goto out;
148+ }
149+
150+ f = fopen(conf, "we");
151+ if (!f) {
152+ r = -errno;
153+ goto out;
154+ }
155+
156+ fprintf(f,
157+ "# Automatically generated by sshd-socket-generator\n"
158+ "\n[Socket]\n"
159+ "ListenStream=\n");
160+
161+ for (u_int i = 0; i < options.num_listen_addrs; i++) {
162+ for (struct addrinfo *ai = options.listen_addrs[i].addrs; ai; ai = ai->ai_next) {
163+ char addr[NI_MAXHOST] = {}, port[NI_MAXSERV] = {},
164+ listen_stream[MAX_LISTEN_STREAM_LEN] = {};
165+
166+ r = getnameinfo(ai->ai_addr, ai->ai_addrlen,
167+ addr, sizeof(addr),
168+ port, sizeof(port),
169+ NI_NUMERICHOST|NI_NUMERICSERV);
170+ if (r != 0) {
171+ fprintf(stderr, "%s\n", gai_strerror(r));
172+ r = r == EAI_SYSTEM ? -errno : -EINVAL;
173+ goto out;
174+ }
175+
176+ if (strcmp(addr, "0.0.0.0") == 0 || strcmp(addr, "::") == 0) {
177+ if (strcmp(port, "22") == 0)
178+ /* No need to override. This is the
179+ * default in ssh.socket. */
180+ continue;
181+
182+ /* If ListenAddress is 0.0.0.0 or ::, only
183+ * write the port in ListenStream=. */
184+ snprintf(listen_stream,
185+ MAX_LISTEN_STREAM_LEN,
186+ "ListenStream=%s",
187+ port);
188+ } else
189+ snprintf(listen_stream,
190+ MAX_LISTEN_STREAM_LEN,
191+ "ListenStream=%s%s%s:%s",
192+ ai->ai_family == AF_INET6 ? "[" : "",
193+ addr,
194+ ai->ai_family == AF_INET6 ? "]" : "",
195+ port);
196+
197+ r = listen_stream_set_append(listen_streams, listen_stream);
198+ if (r < 0)
199+ goto out;
200+ }
201+ }
202+
203+ num_listen_streams = listen_stream_set_len(listen_streams);
204+
205+ if (num_listen_streams <= 0) {
206+ /* We didn't generate anything useful, so clean up and leave
207+ * ssh.socket as-is. */
208+ r = -ENODATA;
209+ goto out;
210+ }
211+
212+ for (int i = 0; i < num_listen_streams; i++)
213+ fprintf(f, "%s\n", listen_streams[i]);
214+
215+ r = fflush_and_check(f);
216+ if (r < 0)
217+ goto out;
218+
219+out:
220+ if (f)
221+ fclose(f);
222+
223+ if (r < 0) {
224+ (void) remove(conf);
225+ (void) remove(overridedir);
226+ }
227+
228+ free(overridedir);
229+ free(conf);
230+
231+ return r;
232+}
233+
234+static int parse_sshd_config_options() {
235+ struct connection_info *connection_info;
236+
237+ cfg = sshbuf_new();
238+ if (!cfg)
239+ return -ENOMEM;
240+
241+ initialize_server_options(&options);
242+ load_server_config(_PATH_SERVER_CONFIG_FILE, cfg);
243+ parse_server_config(&options, _PATH_SERVER_CONFIG_FILE, cfg, &includes, NULL, 0);
244+ fill_default_server_options(&options);
245+
246+ connection_info = get_connection_info(NULL, 0, 0);
247+ connection_info->test = 1;
248+
249+ parse_server_match_config(&options, &includes, connection_info);
250+
251+ return 0;
252+}
253+
254+int main(int argc, char **argv) {
255+ const char *destdir = NULL;
256+ int r;
257+
258+ if (argc < 2) {
259+ fprintf(stderr, "Expected at least one argument.\n");
260+
261+ return EXIT_FAILURE;
262+ }
263+
264+ destdir = argv[1];
265+
266+ r = parse_sshd_config_options();
267+ if (r < 0) {
268+ fprintf(stderr, "Faild to parse sshd config: %s\n", strerror(-r));
269+
270+ return EXIT_FAILURE;
271+ }
272+
273+ if (options.num_listen_addrs <= 0) {
274+ /* No listen addresses configured? Don't generate anything. */
275+ fprintf(stderr, "No listen addresses configured. Will not generate anything.\n");
276+
277+ return EXIT_SUCCESS;
278+ }
279+
280+ r = write_systemd_socket_file(destdir);
281+ if (r == -ENODATA) {
282+ fprintf(stderr, "No custom listen addresses configured. Will not generated anything.\n");
283+
284+ return EXIT_SUCCESS;
285+ }
286+ if (r < 0) {
287+ fprintf(stderr, "Failed to generate ssh.socket: %s\n", strerror(-r));
288+
289+ return EXIT_FAILURE;
290+ }
291+
292+ return EXIT_SUCCESS;
293+}
294--- a/Makefile.in
295+++ b/Makefile.in
296@@ -17,6 +17,7 @@
297 top_srcdir=@top_srcdir@
298 abs_top_srcdir=@abs_top_srcdir@
299 abs_top_builddir=@abs_top_builddir@
300+systemd_system_generator_dir=$(shell pkg-config --variable=systemd_system_generator_dir systemd)
301
302 DESTDIR=
303 VPATH=@srcdir@
304@@ -69,7 +70,7 @@
305
306 .SUFFIXES: .lo
307
308-TARGETS=ssh$(EXEEXT) sshd$(EXEEXT) ssh-add$(EXEEXT) ssh-keygen$(EXEEXT) ssh-keyscan${EXEEXT} ssh-keysign${EXEEXT} ssh-pkcs11-helper$(EXEEXT) ssh-agent$(EXEEXT) scp$(EXEEXT) sftp-server$(EXEEXT) sftp$(EXEEXT) ssh-sk-helper$(EXEEXT)
309+TARGETS=ssh$(EXEEXT) sshd$(EXEEXT) ssh-add$(EXEEXT) ssh-keygen$(EXEEXT) ssh-keyscan${EXEEXT} ssh-keysign${EXEEXT} ssh-pkcs11-helper$(EXEEXT) ssh-agent$(EXEEXT) scp$(EXEEXT) sftp-server$(EXEEXT) sftp$(EXEEXT) ssh-sk-helper$(EXEEXT) sshd-socket-generator$(EXEEXT)
310
311 XMSS_OBJS=\
312 ssh-xmss.o \
313@@ -134,6 +135,16 @@
314 sandbox-seccomp-filter.o sandbox-capsicum.o sandbox-pledge.o \
315 sandbox-solaris.o uidswap.o $(SKOBJS)
316
317+SSHD_SOCKET_GEN_OBJS=sshd-socket-generator.o \
318+ platform.o servconf.o groupaccess.o audit.o audit-linux.o \
319+ auth2.o auth2-none.o auth2-gss.o \
320+ auth2-passwd.o auth2-kbdint.o auth2-hostbased.o \
321+ auth-options.o uidswap.o auth2-pubkey.o auth.o \
322+ auth2-pubkeyfile.o auth-rhosts.o auth-passwd.o \
323+ gss-serv.o auth2-chall.o auth-pam.o gss-serv-krb5.o \
324+ loginrec.o auth-krb5.o auth-shadow.o \
325+ monitor.o monitor_wrap.o
326+
327 SFTP_CLIENT_OBJS=sftp-common.o sftp-client.o sftp-glob.o
328
329 SCP_OBJS= scp.o progressmeter.o $(SFTP_CLIENT_OBJS)
330@@ -210,6 +221,9 @@
331 sshd$(EXEEXT): libssh.a $(LIBCOMPAT) $(SSHDOBJS)
332 $(LD) -o $@ $(SSHDOBJS) $(LDFLAGS) -lssh -lopenbsd-compat $(SSHDLIBS) $(LIBS) $(GSSLIBS) $(K5LIBS) $(CHANNELLIBS)
333
334+sshd-socket-generator$(EXEEXT): libssh.a $(LIBCOMPAT) $(SSHD_SOCKET_GEN_OBJS)
335+ $(LD) -o $@ $(SSHD_SOCKET_GEN_OBJS) $(LDFLAGS) -lssh -lopenbsd-compat $(SSHDLIBS) $(LIBS) $(GSSLIBS) $(K5LIBS) $(CHANNELLIBS)
336+
337 scp$(EXEEXT): $(LIBCOMPAT) libssh.a $(SCP_OBJS)
338 $(LD) -o $@ $(SCP_OBJS) $(LDFLAGS) -lssh -lopenbsd-compat $(LIBS)
339
340@@ -392,6 +406,7 @@
341 $(MKDIR_P) $(DESTDIR)$(mandir)/$(mansubdir)5
342 $(MKDIR_P) $(DESTDIR)$(mandir)/$(mansubdir)8
343 $(MKDIR_P) $(DESTDIR)$(libexecdir)
344+ $(MKDIR_P) $(DESTDIR)$(systemd_system_generator_dir)
345 $(MKDIR_P) -m 0755 $(DESTDIR)$(PRIVSEP_PATH)
346 $(INSTALL) -m 0755 $(STRIP_OPT) ssh$(EXEEXT) $(DESTDIR)$(bindir)/ssh$(EXEEXT)
347 $(INSTALL) -m 0755 $(STRIP_OPT) scp$(EXEEXT) $(DESTDIR)$(bindir)/scp$(EXEEXT)
348@@ -421,6 +436,7 @@
349 $(INSTALL) -m 644 ssh-keysign.8.out $(DESTDIR)$(mandir)/$(mansubdir)8/ssh-keysign.8
350 $(INSTALL) -m 644 ssh-pkcs11-helper.8.out $(DESTDIR)$(mandir)/$(mansubdir)8/ssh-pkcs11-helper.8
351 $(INSTALL) -m 644 ssh-sk-helper.8.out $(DESTDIR)$(mandir)/$(mansubdir)8/ssh-sk-helper.8
352+ $(INSTALL) -m 0755 $(STRIP_OPT) sshd-socket-generator$(EXEEXT) $(DESTDIR)$(systemd_system_generator_dir)/sshd-socket-generator$(EXEEXT)
353
354 install-sysconf:
355 $(MKDIR_P) $(DESTDIR)$(sysconfdir)
356@@ -478,6 +494,7 @@
357 -rm -f $(DESTDIR)$(bindir)/ssh-keyscan$(EXEEXT)
358 -rm -f $(DESTDIR)$(bindir)/sftp$(EXEEXT)
359 -rm -f $(DESTDIR)$(sbindir)/sshd$(EXEEXT)
360+ -rm -f $(DESTDIR)$(systemd_system_generator_dir)/sshd-socket-generator$(EXEEXT)
361 -rm -r $(DESTDIR)$(SFTP_SERVER)$(EXEEXT)
362 -rm -f $(DESTDIR)$(SSH_KEYSIGN)$(EXEEXT)
363 -rm -f $(DESTDIR)$(SSH_PKCS11_HELPER)$(EXEEXT)
diff --git a/debian/po/cs.po b/debian/po/cs.po
index 21b4c7b..d01e0ff 100644
--- a/debian/po/cs.po
+++ b/debian/po/cs.po
@@ -7,7 +7,7 @@ msgid ""
7msgstr ""7msgstr ""
8"Project-Id-Version: openssh 1:6.6p1-1\n"8"Project-Id-Version: openssh 1:6.6p1-1\n"
9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
10"POT-Creation-Date: 2022-09-23 19:34+0000\n"10"POT-Creation-Date: 2014-03-20 02:06+0000\n"
11"PO-Revision-Date: 2014-06-12 12:25+0200\n"11"PO-Revision-Date: 2014-06-12 12:25+0200\n"
12"Last-Translator: Michal Simunek <michal.simunek@gmail.com>\n"12"Last-Translator: Michal Simunek <michal.simunek@gmail.com>\n"
13"Language-Team: Czech <debian-l10n-czech@lists.debian.org>\n"13"Language-Team: Czech <debian-l10n-czech@lists.debian.org>\n"
@@ -53,28 +53,3 @@ msgstr ""
53"poškodit systémy, které jsou nastaveny s předpokladem, že bude možné se "53"poškodit systémy, které jsou nastaveny s předpokladem, že bude možné se "
54"přihlašovat přes SSH jako root pomocí ověřování heslem. Změnu této volby "54"přihlašovat přes SSH jako root pomocí ověřování heslem. Změnu této volby "
55"byste měli provést pouze pokud ověřování heslem potřebujete."55"byste měli provést pouze pokud ověřování heslem potřebujete."
56
57#. Type: error
58#. Description
59#: ../openssh-server.templates:3001
60msgid "Not migrating to socket activation"
61msgstr ""
62
63#. Type: error
64#. Description
65#: ../openssh-server.templates:3001
66msgid ""
67"This version of openssh-server uses socket-based activation by default. "
68"However, because you have more than one ListenAddress configured in "
69"sshd_config, it is impossible to determine at upgrade time if migrating you "
70"to socket-based activation would cause the starting of sshd at boot to be "
71"unreliable."
72msgstr ""
73
74#. Type: error
75#. Description
76#: ../openssh-server.templates:3001
77msgid ""
78"Because a failure to start ssh may make it impossible to admininister a "
79"system, you will not be migrated to socket-based activation at this time."
80msgstr ""
diff --git a/debian/po/da.po b/debian/po/da.po
index a08ca3b..70d576d 100644
--- a/debian/po/da.po
+++ b/debian/po/da.po
@@ -7,7 +7,7 @@ msgid ""
7msgstr ""7msgstr ""
8"Project-Id-Version: openssh\n"8"Project-Id-Version: openssh\n"
9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
10"POT-Creation-Date: 2022-09-23 19:34+0000\n"10"POT-Creation-Date: 2014-03-20 02:06+0000\n"
11"PO-Revision-Date: 2014-03-21 23:51+0200\n"11"PO-Revision-Date: 2014-03-21 23:51+0200\n"
12"Last-Translator: Joe Hansen <joedalton2@yahoo.dk>\n"12"Last-Translator: Joe Hansen <joedalton2@yahoo.dk>\n"
13"Language-Team: Danish <debian-l10n-danish@lists.debian.org>\n"13"Language-Team: Danish <debian-l10n-danish@lists.debian.org>\n"
@@ -53,28 +53,3 @@ msgstr ""
53"Det kan dog ødelægge systemer, som er opsat med forventning om at kunne SSH "53"Det kan dog ødelægge systemer, som er opsat med forventning om at kunne SSH "
54"som root via brug af adgangskodegodkendelse. Du skal kun lave denne ændring, "54"som root via brug af adgangskodegodkendelse. Du skal kun lave denne ændring, "
55"hvis du ikke har brug for dette."55"hvis du ikke har brug for dette."
56
57#. Type: error
58#. Description
59#: ../openssh-server.templates:3001
60msgid "Not migrating to socket activation"
61msgstr ""
62
63#. Type: error
64#. Description
65#: ../openssh-server.templates:3001
66msgid ""
67"This version of openssh-server uses socket-based activation by default. "
68"However, because you have more than one ListenAddress configured in "
69"sshd_config, it is impossible to determine at upgrade time if migrating you "
70"to socket-based activation would cause the starting of sshd at boot to be "
71"unreliable."
72msgstr ""
73
74#. Type: error
75#. Description
76#: ../openssh-server.templates:3001
77msgid ""
78"Because a failure to start ssh may make it impossible to admininister a "
79"system, you will not be migrated to socket-based activation at this time."
80msgstr ""
diff --git a/debian/po/de.po b/debian/po/de.po
index 2536ea4..ecba54b 100644
--- a/debian/po/de.po
+++ b/debian/po/de.po
@@ -8,7 +8,7 @@ msgid ""
8msgstr ""8msgstr ""
9"Project-Id-Version: openssh_1:6.6p1-1\n"9"Project-Id-Version: openssh_1:6.6p1-1\n"
10"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"10"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
11"POT-Creation-Date: 2022-09-23 19:34+0000\n"11"POT-Creation-Date: 2014-03-20 02:06+0000\n"
12"PO-Revision-Date: 2014-03-24 22:21+0100\n"12"PO-Revision-Date: 2014-03-24 22:21+0100\n"
13"Last-Translator: Stephan Beck <sbeck@mailbox.org>\n"13"Last-Translator: Stephan Beck <sbeck@mailbox.org>\n"
14"Language-Team: Debian German translation team <debian-l10n-german@lists."14"Language-Team: Debian German translation team <debian-l10n-german@lists."
@@ -59,28 +59,3 @@ msgstr ""
59"in der Absicht konfiguriert wurden, die Anmeldung als »root« über SSH unter "59"in der Absicht konfiguriert wurden, die Anmeldung als »root« über SSH unter "
60"Verwendung von Passwort-Authentifizierung zuzulassen. Sie sollten diese "60"Verwendung von Passwort-Authentifizierung zuzulassen. Sie sollten diese "
61"Änderung nur vornehmen, wenn Sie auf Letzteres verzichten können."61"Änderung nur vornehmen, wenn Sie auf Letzteres verzichten können."
62
63#. Type: error
64#. Description
65#: ../openssh-server.templates:3001
66msgid "Not migrating to socket activation"
67msgstr ""
68
69#. Type: error
70#. Description
71#: ../openssh-server.templates:3001
72msgid ""
73"This version of openssh-server uses socket-based activation by default. "
74"However, because you have more than one ListenAddress configured in "
75"sshd_config, it is impossible to determine at upgrade time if migrating you "
76"to socket-based activation would cause the starting of sshd at boot to be "
77"unreliable."
78msgstr ""
79
80#. Type: error
81#. Description
82#: ../openssh-server.templates:3001
83msgid ""
84"Because a failure to start ssh may make it impossible to admininister a "
85"system, you will not be migrated to socket-based activation at this time."
86msgstr ""
diff --git a/debian/po/es.po b/debian/po/es.po
index 14550d6..de8a67a 100644
--- a/debian/po/es.po
+++ b/debian/po/es.po
@@ -28,7 +28,7 @@ msgid ""
28msgstr ""28msgstr ""
29"Project-Id-Version: openssh\n"29"Project-Id-Version: openssh\n"
30"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"30"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
31"POT-Creation-Date: 2022-09-23 19:34+0000\n"31"POT-Creation-Date: 2014-03-20 02:06+0000\n"
32"PO-Revision-Date: 2014-03-23 20:43-0300\n"32"PO-Revision-Date: 2014-03-23 20:43-0300\n"
33"Last-Translator: Matías Bellone <matiasbellone+debian@gmail.com>\n"33"Last-Translator: Matías Bellone <matiasbellone+debian@gmail.com>\n"
34"Language-Team: Debian l10n Spanish <debian-l10n-spanish@lists.debian.org>\n"34"Language-Team: Debian l10n Spanish <debian-l10n-spanish@lists.debian.org>\n"
@@ -78,28 +78,3 @@ msgstr ""
78"configuración permite que el usuario root inicie sesión a través de SSH "78"configuración permite que el usuario root inicie sesión a través de SSH "
79"utilizando una contraseña. Sólo debería realizar este cambio si no necesita "79"utilizando una contraseña. Sólo debería realizar este cambio si no necesita "
80"este comportamiento."80"este comportamiento."
81
82#. Type: error
83#. Description
84#: ../openssh-server.templates:3001
85msgid "Not migrating to socket activation"
86msgstr ""
87
88#. Type: error
89#. Description
90#: ../openssh-server.templates:3001
91msgid ""
92"This version of openssh-server uses socket-based activation by default. "
93"However, because you have more than one ListenAddress configured in "
94"sshd_config, it is impossible to determine at upgrade time if migrating you "
95"to socket-based activation would cause the starting of sshd at boot to be "
96"unreliable."
97msgstr ""
98
99#. Type: error
100#. Description
101#: ../openssh-server.templates:3001
102msgid ""
103"Because a failure to start ssh may make it impossible to admininister a "
104"system, you will not be migrated to socket-based activation at this time."
105msgstr ""
diff --git a/debian/po/fr.po b/debian/po/fr.po
index 7d7093b..f7125e9 100644
--- a/debian/po/fr.po
+++ b/debian/po/fr.po
@@ -7,7 +7,7 @@ msgid ""
7msgstr ""7msgstr ""
8"Project-Id-Version: openssh_1:6.5p1-6\n"8"Project-Id-Version: openssh_1:6.5p1-6\n"
9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
10"POT-Creation-Date: 2022-09-23 19:34+0000\n"10"POT-Creation-Date: 2014-03-20 02:06+0000\n"
11"PO-Revision-Date: 2014-03-22 08:26+0100\n"11"PO-Revision-Date: 2014-03-22 08:26+0100\n"
12"Last-Translator: Étienne Gilli <etienne.gilli@gmail.com>\n"12"Last-Translator: Étienne Gilli <etienne.gilli@gmail.com>\n"
13"Language-Team: French <debian-l10n-french@lists.debian.org>\n"13"Language-Team: French <debian-l10n-french@lists.debian.org>\n"
@@ -57,28 +57,3 @@ msgstr ""
57"inutilisables les systèmes reposant sur la possibilité de se connecter au "57"inutilisables les systèmes reposant sur la possibilité de se connecter au "
58"compte « root » par SSH avec authentification par mot de passe. Vous ne "58"compte « root » par SSH avec authentification par mot de passe. Vous ne "
59"devriez appliquer cette modification que si ce n’est pas votre cas."59"devriez appliquer cette modification que si ce n’est pas votre cas."
60
61#. Type: error
62#. Description
63#: ../openssh-server.templates:3001
64msgid "Not migrating to socket activation"
65msgstr ""
66
67#. Type: error
68#. Description
69#: ../openssh-server.templates:3001
70msgid ""
71"This version of openssh-server uses socket-based activation by default. "
72"However, because you have more than one ListenAddress configured in "
73"sshd_config, it is impossible to determine at upgrade time if migrating you "
74"to socket-based activation would cause the starting of sshd at boot to be "
75"unreliable."
76msgstr ""
77
78#. Type: error
79#. Description
80#: ../openssh-server.templates:3001
81msgid ""
82"Because a failure to start ssh may make it impossible to admininister a "
83"system, you will not be migrated to socket-based activation at this time."
84msgstr ""
diff --git a/debian/po/it.po b/debian/po/it.po
index 5390795..dd71060 100644
--- a/debian/po/it.po
+++ b/debian/po/it.po
@@ -6,7 +6,7 @@ msgid ""
6msgstr ""6msgstr ""
7"Project-Id-Version: openssh\n"7"Project-Id-Version: openssh\n"
8"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"8"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
9"POT-Creation-Date: 2022-09-23 19:34+0000\n"9"POT-Creation-Date: 2014-03-20 02:06+0000\n"
10"PO-Revision-Date: 2014-03-28 11:12+0200\n"10"PO-Revision-Date: 2014-03-28 11:12+0200\n"
11"Last-Translator: Beatrice Torracca <beatricet@libero.it>\n"11"Last-Translator: Beatrice Torracca <beatricet@libero.it>\n"
12"Language-Team: Italian <debian-l10n-italian@lists.debian.org>\n"12"Language-Team: Italian <debian-l10n-italian@lists.debian.org>\n"
@@ -56,28 +56,3 @@ msgstr ""
56"impostati facendo affidamento sulla possibilità di autenticazione SSH come "56"impostati facendo affidamento sulla possibilità di autenticazione SSH come "
57"root usando la password. Si dovrebbe fare questo cambiamento solo se non si "57"root usando la password. Si dovrebbe fare questo cambiamento solo se non si "
58"ha bisogno di tale comportamento."58"ha bisogno di tale comportamento."
59
60#. Type: error
61#. Description
62#: ../openssh-server.templates:3001
63msgid "Not migrating to socket activation"
64msgstr ""
65
66#. Type: error
67#. Description
68#: ../openssh-server.templates:3001
69msgid ""
70"This version of openssh-server uses socket-based activation by default. "
71"However, because you have more than one ListenAddress configured in "
72"sshd_config, it is impossible to determine at upgrade time if migrating you "
73"to socket-based activation would cause the starting of sshd at boot to be "
74"unreliable."
75msgstr ""
76
77#. Type: error
78#. Description
79#: ../openssh-server.templates:3001
80msgid ""
81"Because a failure to start ssh may make it impossible to admininister a "
82"system, you will not be migrated to socket-based activation at this time."
83msgstr ""
diff --git a/debian/po/ja.po b/debian/po/ja.po
index b48d281..db382f1 100644
--- a/debian/po/ja.po
+++ b/debian/po/ja.po
@@ -7,7 +7,7 @@ msgid ""
7msgstr ""7msgstr ""
8"Project-Id-Version: openssh\n"8"Project-Id-Version: openssh\n"
9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
10"POT-Creation-Date: 2022-09-23 19:34+0000\n"10"POT-Creation-Date: 2014-03-20 02:06+0000\n"
11"PO-Revision-Date: 2014-03-20 11:06+0900\n"11"PO-Revision-Date: 2014-03-20 11:06+0900\n"
12"Last-Translator: victory <victory.deb@gmail.com>\n"12"Last-Translator: victory <victory.deb@gmail.com>\n"
13"Language-Team: Japanese <debian-japanese@lists.debian.org>\n"13"Language-Team: Japanese <debian-japanese@lists.debian.org>\n"
@@ -53,28 +53,3 @@ msgstr ""
53"ます。しかしパスワード認証により root で SSH 接続できることを前提として構成し"53"ます。しかしパスワード認証により root で SSH 接続できることを前提として構成し"
54"たシステムでは問題が発生する可能性があります。そういった必要のない場合にのみ"54"たシステムでは問題が発生する可能性があります。そういった必要のない場合にのみ"
55"この変更を行うようにしてください。"55"この変更を行うようにしてください。"
56
57#. Type: error
58#. Description
59#: ../openssh-server.templates:3001
60msgid "Not migrating to socket activation"
61msgstr ""
62
63#. Type: error
64#. Description
65#: ../openssh-server.templates:3001
66msgid ""
67"This version of openssh-server uses socket-based activation by default. "
68"However, because you have more than one ListenAddress configured in "
69"sshd_config, it is impossible to determine at upgrade time if migrating you "
70"to socket-based activation would cause the starting of sshd at boot to be "
71"unreliable."
72msgstr ""
73
74#. Type: error
75#. Description
76#: ../openssh-server.templates:3001
77msgid ""
78"Because a failure to start ssh may make it impossible to admininister a "
79"system, you will not be migrated to socket-based activation at this time."
80msgstr ""
diff --git a/debian/po/nl.po b/debian/po/nl.po
index eca9662..3afd617 100644
--- a/debian/po/nl.po
+++ b/debian/po/nl.po
@@ -7,7 +7,7 @@ msgid ""
7msgstr ""7msgstr ""
8"Project-Id-Version: openssh\n"8"Project-Id-Version: openssh\n"
9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
10"POT-Creation-Date: 2022-09-23 19:34+0000\n"10"POT-Creation-Date: 2014-03-20 02:06+0000\n"
11"PO-Revision-Date: 2014-10-03 23:54+0200\n"11"PO-Revision-Date: 2014-10-03 23:54+0200\n"
12"Last-Translator: Frans Spiesschaert <Frans.Spiesschaert@yucom.be>\n"12"Last-Translator: Frans Spiesschaert <Frans.Spiesschaert@yucom.be>\n"
13"Language-Team: Debian Dutch l10n Team <debian-l10n-dutch@lists.debian.org>\n"13"Language-Team: Debian Dutch l10n Team <debian-l10n-dutch@lists.debian.org>\n"
@@ -58,28 +58,3 @@ msgstr ""
58"ingesteld werden vanuit de verwachting dat de systeembeheerder SSH kan "58"ingesteld werden vanuit de verwachting dat de systeembeheerder SSH kan "
59"gebruiken met authenticatie via wachtwoord. Enkel wanneer u dit laatste niet "59"gebruiken met authenticatie via wachtwoord. Enkel wanneer u dit laatste niet "
60"nodig heeft, zou u deze wijziging kunnen doorvoeren."60"nodig heeft, zou u deze wijziging kunnen doorvoeren."
61
62#. Type: error
63#. Description
64#: ../openssh-server.templates:3001
65msgid "Not migrating to socket activation"
66msgstr ""
67
68#. Type: error
69#. Description
70#: ../openssh-server.templates:3001
71msgid ""
72"This version of openssh-server uses socket-based activation by default. "
73"However, because you have more than one ListenAddress configured in "
74"sshd_config, it is impossible to determine at upgrade time if migrating you "
75"to socket-based activation would cause the starting of sshd at boot to be "
76"unreliable."
77msgstr ""
78
79#. Type: error
80#. Description
81#: ../openssh-server.templates:3001
82msgid ""
83"Because a failure to start ssh may make it impossible to admininister a "
84"system, you will not be migrated to socket-based activation at this time."
85msgstr ""
diff --git a/debian/po/pt.po b/debian/po/pt.po
index 8f51af9..2dab84c 100644
--- a/debian/po/pt.po
+++ b/debian/po/pt.po
@@ -7,7 +7,7 @@ msgid ""
7msgstr ""7msgstr ""
8"Project-Id-Version: openssh 1:6.6p1-1\n"8"Project-Id-Version: openssh 1:6.6p1-1\n"
9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
10"POT-Creation-Date: 2022-09-23 19:34+0000\n"10"POT-Creation-Date: 2014-03-20 02:06+0000\n"
11"PO-Revision-Date: 2014-03-21 21:13+0000\n"11"PO-Revision-Date: 2014-03-21 21:13+0000\n"
12"Last-Translator: Américo Monteiro <a_monteiro@gmx.com>\n"12"Last-Translator: Américo Monteiro <a_monteiro@gmx.com>\n"
13"Language-Team: Portuguese <traduz@debianpt.org>\n"13"Language-Team: Portuguese <traduz@debianpt.org>\n"
@@ -57,28 +57,3 @@ msgstr ""
57"configurados com a expectativa de serem capazes de SSH como root usando "57"configurados com a expectativa de serem capazes de SSH como root usando "
58"autenticação por palavra-passe. Apenas deverá fazer esta alteração se não "58"autenticação por palavra-passe. Apenas deverá fazer esta alteração se não "
59"precisa de tal método de autenticação."59"precisa de tal método de autenticação."
60
61#. Type: error
62#. Description
63#: ../openssh-server.templates:3001
64msgid "Not migrating to socket activation"
65msgstr ""
66
67#. Type: error
68#. Description
69#: ../openssh-server.templates:3001
70msgid ""
71"This version of openssh-server uses socket-based activation by default. "
72"However, because you have more than one ListenAddress configured in "
73"sshd_config, it is impossible to determine at upgrade time if migrating you "
74"to socket-based activation would cause the starting of sshd at boot to be "
75"unreliable."
76msgstr ""
77
78#. Type: error
79#. Description
80#: ../openssh-server.templates:3001
81msgid ""
82"Because a failure to start ssh may make it impossible to admininister a "
83"system, you will not be migrated to socket-based activation at this time."
84msgstr ""
diff --git a/debian/po/pt_BR.po b/debian/po/pt_BR.po
index 98856bb..99b1182 100644
--- a/debian/po/pt_BR.po
+++ b/debian/po/pt_BR.po
@@ -8,7 +8,7 @@ msgid ""
8msgstr ""8msgstr ""
9"Project-Id-Version: openssh\n"9"Project-Id-Version: openssh\n"
10"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"10"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
11"POT-Creation-Date: 2022-09-23 19:34+0000\n"11"POT-Creation-Date: 2014-03-20 02:06+0000\n"
12"PO-Revision-Date: 2014-11-23 23:49-0200\n"12"PO-Revision-Date: 2014-11-23 23:49-0200\n"
13"Last-Translator: José de Figueiredo <deb.gnulinux@gmail.com>\n"13"Last-Translator: José de Figueiredo <deb.gnulinux@gmail.com>\n"
14"Language-Team: Brazilian Portuguese <debian-l10n-portuguese@lists.debian."14"Language-Team: Brazilian Portuguese <debian-l10n-portuguese@lists.debian."
@@ -55,28 +55,3 @@ msgstr ""
55"Entretanto, ela pode quebrar sistemas que foram configurados com a "55"Entretanto, ela pode quebrar sistemas que foram configurados com a "
56"expectativa de acesso SSH com root usando autenticação por senha. Você deve "56"expectativa de acesso SSH com root usando autenticação por senha. Você deve "
57"fazer esta mudança somente se você não precisa fazer isso."57"fazer esta mudança somente se você não precisa fazer isso."
58
59#. Type: error
60#. Description
61#: ../openssh-server.templates:3001
62msgid "Not migrating to socket activation"
63msgstr ""
64
65#. Type: error
66#. Description
67#: ../openssh-server.templates:3001
68msgid ""
69"This version of openssh-server uses socket-based activation by default. "
70"However, because you have more than one ListenAddress configured in "
71"sshd_config, it is impossible to determine at upgrade time if migrating you "
72"to socket-based activation would cause the starting of sshd at boot to be "
73"unreliable."
74msgstr ""
75
76#. Type: error
77#. Description
78#: ../openssh-server.templates:3001
79msgid ""
80"Because a failure to start ssh may make it impossible to admininister a "
81"system, you will not be migrated to socket-based activation at this time."
82msgstr ""
diff --git a/debian/po/ru.po b/debian/po/ru.po
index 3fa193c..f2e1daf 100644
--- a/debian/po/ru.po
+++ b/debian/po/ru.po
@@ -6,7 +6,7 @@ msgid ""
6msgstr ""6msgstr ""
7"Project-Id-Version: openssh 1:6.6p1-1\n"7"Project-Id-Version: openssh 1:6.6p1-1\n"
8"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"8"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
9"POT-Creation-Date: 2022-09-23 19:34+0000\n"9"POT-Creation-Date: 2014-03-20 02:06+0000\n"
10"PO-Revision-Date: 2014-03-22 10:04+0400\n"10"PO-Revision-Date: 2014-03-22 10:04+0400\n"
11"Last-Translator: Yuri Kozlov <yuray@komyakino.ru>\n"11"Last-Translator: Yuri Kozlov <yuray@komyakino.ru>\n"
12"Language-Team: Russian <debian-l10n-russian@lists.debian.org>\n"12"Language-Team: Russian <debian-l10n-russian@lists.debian.org>\n"
@@ -14,8 +14,8 @@ msgstr ""
14"MIME-Version: 1.0\n"14"MIME-Version: 1.0\n"
15"Content-Type: text/plain; charset=UTF-8\n"15"Content-Type: text/plain; charset=UTF-8\n"
16"Content-Transfer-Encoding: 8bit\n"16"Content-Transfer-Encoding: 8bit\n"
17"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && "17"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
18"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"18"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
19"X-Generator: Lokalize 1.4\n"19"X-Generator: Lokalize 1.4\n"
2020
21#. Type: boolean21#. Type: boolean
@@ -55,28 +55,3 @@ msgstr ""
55"атак). Однако, это вредит системам, в которых специально настроен вход для "55"атак). Однако, это вредит системам, в которых специально настроен вход для "
56"root по SSH с парольной аутентификацией. Если это не ваш случай, то ответьте "56"root по SSH с парольной аутентификацией. Если это не ваш случай, то ответьте "
57"утвердительно."57"утвердительно."
58
59#. Type: error
60#. Description
61#: ../openssh-server.templates:3001
62msgid "Not migrating to socket activation"
63msgstr ""
64
65#. Type: error
66#. Description
67#: ../openssh-server.templates:3001
68msgid ""
69"This version of openssh-server uses socket-based activation by default. "
70"However, because you have more than one ListenAddress configured in "
71"sshd_config, it is impossible to determine at upgrade time if migrating you "
72"to socket-based activation would cause the starting of sshd at boot to be "
73"unreliable."
74msgstr ""
75
76#. Type: error
77#. Description
78#: ../openssh-server.templates:3001
79msgid ""
80"Because a failure to start ssh may make it impossible to admininister a "
81"system, you will not be migrated to socket-based activation at this time."
82msgstr ""
diff --git a/debian/po/sv.po b/debian/po/sv.po
index 296e611..278b0cc 100644
--- a/debian/po/sv.po
+++ b/debian/po/sv.po
@@ -8,7 +8,7 @@ msgid ""
8msgstr ""8msgstr ""
9"Project-Id-Version: openssh\n"9"Project-Id-Version: openssh\n"
10"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"10"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
11"POT-Creation-Date: 2022-09-23 19:34+0000\n"11"POT-Creation-Date: 2014-03-20 02:06+0000\n"
12"PO-Revision-Date: 2014-03-21 21:36+0100\n"12"PO-Revision-Date: 2014-03-21 21:36+0100\n"
13"Last-Translator: Andreas Rönnquist <gusnan@gusnan.se>\n"13"Last-Translator: Andreas Rönnquist <gusnan@gusnan.se>\n"
14"Language-Team: Swedish\n"14"Language-Team: Swedish\n"
@@ -56,28 +56,3 @@ msgstr ""
56"sådana angrepp). Dock så kan detta förstöra system som förväntas kunna "56"sådana angrepp). Dock så kan detta förstöra system som förväntas kunna "
57"använda SSH som root med hjälp av lösenordsautentisering. Du skall endast "57"använda SSH som root med hjälp av lösenordsautentisering. Du skall endast "
58"göra denna förändring om du inte har ett behov av att kunna göra detta."58"göra denna förändring om du inte har ett behov av att kunna göra detta."
59
60#. Type: error
61#. Description
62#: ../openssh-server.templates:3001
63msgid "Not migrating to socket activation"
64msgstr ""
65
66#. Type: error
67#. Description
68#: ../openssh-server.templates:3001
69msgid ""
70"This version of openssh-server uses socket-based activation by default. "
71"However, because you have more than one ListenAddress configured in "
72"sshd_config, it is impossible to determine at upgrade time if migrating you "
73"to socket-based activation would cause the starting of sshd at boot to be "
74"unreliable."
75msgstr ""
76
77#. Type: error
78#. Description
79#: ../openssh-server.templates:3001
80msgid ""
81"Because a failure to start ssh may make it impossible to admininister a "
82"system, you will not be migrated to socket-based activation at this time."
83msgstr ""
diff --git a/debian/po/templates.pot b/debian/po/templates.pot
index c9dc5ba..47c9e36 100644
--- a/debian/po/templates.pot
+++ b/debian/po/templates.pot
@@ -1,6 +1,6 @@
1# SOME DESCRIPTIVE TITLE.1# SOME DESCRIPTIVE TITLE.
2# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER2# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
3# This file is distributed under the same license as the openssh package.3# This file is distributed under the same license as the PACKAGE package.
4# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.4# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
5#5#
6#, fuzzy6#, fuzzy
@@ -8,7 +8,7 @@ msgid ""
8msgstr ""8msgstr ""
9"Project-Id-Version: openssh\n"9"Project-Id-Version: openssh\n"
10"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"10"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
11"POT-Creation-Date: 2022-09-23 19:34+0000\n"11"POT-Creation-Date: 2014-03-20 02:06+0000\n"
12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"12"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"13"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14"Language-Team: LANGUAGE <LL@li.org>\n"14"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -44,28 +44,3 @@ msgid ""
44"able to SSH as root using password authentication. You should only make this "44"able to SSH as root using password authentication. You should only make this "
45"change if you do not need to do that."45"change if you do not need to do that."
46msgstr ""46msgstr ""
47
48#. Type: error
49#. Description
50#: ../openssh-server.templates:3001
51msgid "Not migrating to socket activation"
52msgstr ""
53
54#. Type: error
55#. Description
56#: ../openssh-server.templates:3001
57msgid ""
58"This version of openssh-server uses socket-based activation by default. "
59"However, because you have more than one ListenAddress configured in "
60"sshd_config, it is impossible to determine at upgrade time if migrating you "
61"to socket-based activation would cause the starting of sshd at boot to be "
62"unreliable."
63msgstr ""
64
65#. Type: error
66#. Description
67#: ../openssh-server.templates:3001
68msgid ""
69"Because a failure to start ssh may make it impossible to admininister a "
70"system, you will not be migrated to socket-based activation at this time."
71msgstr ""
diff --git a/debian/po/tr.po b/debian/po/tr.po
index fd6bde5..1ada041 100644
--- a/debian/po/tr.po
+++ b/debian/po/tr.po
@@ -7,15 +7,15 @@ msgid ""
7msgstr ""7msgstr ""
8"Project-Id-Version: openssh-server\n"8"Project-Id-Version: openssh-server\n"
9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"9"Report-Msgid-Bugs-To: openssh@packages.debian.org\n"
10"POT-Creation-Date: 2022-09-23 19:34+0000\n"10"POT-Creation-Date: 2014-03-20 02:06+0000\n"
11"PO-Revision-Date: 2014-08-01 14:44+0200\n"11"PO-Revision-Date: 2014-08-01 14:44+0200\n"
12"Last-Translator: Mert Dirik <mertdirik@gmail.com>\n"12"Last-Translator: Mert Dirik <mertdirik@gmail.com>\n"
13"Language-Team: Debian L10n Turkish <debian-l10n-turkish@lists.debian.org>\n"13"Language-Team: Debian L10n Turkish <debian-l10n-turkish@lists.debian.org>\n"
14"Language: tr\n"
15"MIME-Version: 1.0\n"14"MIME-Version: 1.0\n"
16"Content-Type: text/plain; charset=UTF-8\n"15"Content-Type: text/plain; charset=UTF-8\n"
17"Content-Transfer-Encoding: 8bit\n"16"Content-Transfer-Encoding: 8bit\n"
18"X-Generator: Poedit 1.5.4\n"17"X-Generator: Poedit 1.5.4\n"
18"Language: tr\n"
1919
20#. Type: boolean20#. Type: boolean
21#. Description21#. Description
@@ -56,28 +56,3 @@ msgstr ""
56"parola doğrulama yöntemiyle oturum açılabileceği varsayımıyla hareket eden "56"parola doğrulama yöntemiyle oturum açılabileceği varsayımıyla hareket eden "
57"sistemlerde eskiden çalışan düzenin bozulmasına sebep olacaktır. Bu "57"sistemlerde eskiden çalışan düzenin bozulmasına sebep olacaktır. Bu "
58"değişikliği yalnızca sorun çıkarmayacağından eminseniz yapın."58"değişikliği yalnızca sorun çıkarmayacağından eminseniz yapın."
59
60#. Type: error
61#. Description
62#: ../openssh-server.templates:3001
63msgid "Not migrating to socket activation"
64msgstr ""
65
66#. Type: error
67#. Description
68#: ../openssh-server.templates:3001
69msgid ""
70"This version of openssh-server uses socket-based activation by default. "
71"However, because you have more than one ListenAddress configured in "
72"sshd_config, it is impossible to determine at upgrade time if migrating you "
73"to socket-based activation would cause the starting of sshd at boot to be "
74"unreliable."
75msgstr ""
76
77#. Type: error
78#. Description
79#: ../openssh-server.templates:3001
80msgid ""
81"Because a failure to start ssh may make it impossible to admininister a "
82"system, you will not be migrated to socket-based activation at this time."
83msgstr ""
diff --git a/debian/rules b/debian/rules
index dff4713..54d82cb 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,6 +1,6 @@
1#!/usr/bin/make -f1#!/usr/bin/make -f
22
3export DEB_BUILD_MAINT_OPTIONS := hardening=+all3export DEB_BUILD_MAINT_OPTIONS := hardening=+all optimize=+lto
44
5include /usr/share/dpkg/default.mk5include /usr/share/dpkg/default.mk
66
diff --git a/debian/systemd/ssh.socket b/debian/systemd/ssh.socket
index 1de1280..69e93a0 100644
--- a/debian/systemd/ssh.socket
+++ b/debian/systemd/ssh.socket
@@ -1,11 +1,13 @@
1[Unit]1[Unit]
2Description=OpenBSD Secure Shell server socket2Description=OpenBSD Secure Shell server socket
3Before=sockets.target3Before=sockets.target ssh.service
4ConditionPathExists=!/etc/ssh/sshd_not_to_be_run4ConditionPathExists=!/etc/ssh/sshd_not_to_be_run
55
6[Socket]6[Socket]
7ListenStream=227ListenStream=22
8Accept=no8Accept=no
9FreeBind=yes
910
10[Install]11[Install]
11WantedBy=sockets.target12WantedBy=sockets.target
13RequiredBy=ssh.service
diff --git a/debian/tests/control b/debian/tests/control
index adef04c..dd8069d 100644
--- a/debian/tests/control
+++ b/debian/tests/control
@@ -15,3 +15,9 @@ Restrictions: needs-root allow-stderr
15Depends: openssh-client,15Depends: openssh-client,
16 openssh-server,16 openssh-server,
17 systemd,17 systemd,
18
19Tests: sshd-socket-generator
20Restrictions: needs-root allow-stderr
21Depends: openssh-client,
22 openssh-server,
23 systemd,
diff --git a/debian/tests/sshd-socket-generator b/debian/tests/sshd-socket-generator
18new file mode 10064424new file mode 100644
index 0000000..da6b4d6
--- /dev/null
+++ b/debian/tests/sshd-socket-generator
@@ -0,0 +1,105 @@
1#!/bin/bash
2
3test_default() (
4 set -xeuo pipefail
5
6 /usr/lib/systemd/system-generators/sshd-socket-generator "$testdir"
7
8 # Nothing should be generated in this case.
9 test ! -e "$testdir/ssh.socket.d"
10)
11
12test_custom_port() (
13 set -xeuo pipefail
14
15 echo "Port 1234" >> "$testconf"
16
17 /usr/lib/systemd/system-generators/sshd-socket-generator "$testdir"
18
19 grep -q "^ListenStream=1234" "$socket_override"
20)
21
22test_mutiple_custom_ports() (
23 set -xeuo pipefail
24
25 echo "Port 1234" >> "$testconf"
26 echo "Port 4321" >> "$testconf"
27
28 /usr/lib/systemd/system-generators/sshd-socket-generator "$testdir"
29
30 grep -q "^ListenStream=1234" "$socket_override"
31 grep -q "^ListenStream=4321" "$socket_override"
32)
33
34test_custom_listenaddress() (
35 set -xeuo pipefail
36
37 echo "ListenAddress 10.1.2.3" >> "$testconf"
38
39 /usr/lib/systemd/system-generators/sshd-socket-generator "$testdir"
40
41 grep -q "^ListenStream=10.1.2.3:22" "$socket_override"
42)
43
44test_custom_listenaddress_and_port() (
45 set -xeuo pipefail
46
47 echo "Port 1234" >> "$testconf"
48 echo "ListenAddress 10.1.2.3" >> "$testconf"
49
50 /usr/lib/systemd/system-generators/sshd-socket-generator "$testdir"
51
52 grep -q "^ListenStream=10.1.2.3:1234" "$socket_override"
53)
54
55test_custom_ipv6_listenaddress() (
56 set -xeuo pipefail
57
58 echo "ListenAddress 2001:db8:85a3::8a2e:370:7334" >> "$testconf"
59
60 /usr/lib/systemd/system-generators/sshd-socket-generator "$testdir"
61
62 grep -q "^ListenStream=\[2001:db8:85a3::8a2e:370:7334\]:22" "$socket_override"
63)
64
65tmpdir="$(mktemp -d)"
66testconf="/etc/ssh/sshd_config.d/test.conf"
67failed=
68
69mkdir -p /etc/ssh/sshd_config.d
70
71for test_fn in \
72 "test_default" \
73 "test_custom_port" \
74 "test_mutiple_custom_ports" \
75 "test_custom_listenaddress" \
76 "test_custom_listenaddress_and_port" \
77 "test_custom_ipv6_listenaddress"
78do
79 echo -n "$test_fn..."
80
81 testdir="${tmpdir}/${test_fn}"
82 socket_override="${testdir}/ssh.socket.d/addresses.conf"
83 mkdir -p "$testdir"
84
85 $test_fn > "${AUTOPKGTEST_ARTIFACTS}/${test_fn}.log" 2>&1
86 if [[ $? -eq 0 ]]; then
87 echo "PASS"
88 else
89 echo "FAIL"
90 failed="${failed:+$failed }$test_fn"
91 fi
92
93 >"$testconf"
94done
95
96if [[ -n "$failed" ]]; then
97 for t in $failed; do
98 echo "--------------------------------------------"
99 echo "FAIL: $t"
100 echo "--------------------------------------------"
101 cat "${AUTOPKGTEST_ARTIFACTS}/${t}.log"
102 done
103
104 exit 1
105fi

Subscribers

People subscribed via source and target branches