From: Jack Hill <jackhill@jackhill.us>
To: Christopher Baines <mail@cbaines.net>
Cc: 55335@debbugs.gnu.org
Subject: bug#55335: [PATCH] services: Allow shepherd to listen for IPv6 connections to openssh.
Date: Fri, 13 May 2022 11:25:51 -0400 (EDT) [thread overview]
Message-ID: <alpine.DEB.2.21.2205131125260.11587@marsh.hcoop.net> (raw)
In-Reply-To: <alpine.DEB.2.21.2205131110120.11587@marsh.hcoop.net>
On Fri, 13 May 2022, Jack Hill wrote:
> Thanks for looking into this! Does this fix work for you (I assume so)? I
> tried a simpler patch to use a v6 socket:
>
>
> --- a/gnu/services/ssh.scm
> +++ b/gnu/services/ssh.scm
> @@ -535,7 +535,7 @@ (define openssh-command
> (start #~(if (defined? 'make-inetd-constructor)
> (make-inetd-constructor
> (append #$openssh-command '("-i"))
> - (make-socket-address AF_INET INADDR_ANY
> + (make-socket-address AF_INET6 INADDR_ANY
> #$port-number)
> #:max-connections #$max-connections)
> (make-forkexec-constructor #$openssh-command
>
> and that does indeed produce a v6 socket that also accepts v4 connection. The
> output of `ss -tulpen`:
>
> tcp LISTEN 0 10 *:22 *:*
> users:(("shepherd",pid=1,fd=29)) ino:1522146 sk:2001 cgroup:/ v6only:0 <->
>
> However, while ssh is now able to connect to the socket, something is going
> wrong in the handoff to sshd. I see the following message printed on the
> console when trying to connect:
>
> Uncaught exception in task:
> In fibers.scm:
> 150:8 4 (_)
> In shepherd/service.scm:
> 1435:21 3 (_)
> 1280:30 2 (socket-address->string #(10 # 37896 0 0))
> In unknown file:
> 1 (inet-ntop 2 42540578165178177408896616697074944157)
> In ice-9/boot-9.scm:
> 1685:16 0 (raise-exception _ #:continualbe? _)
> ice-9/boot-9.scm:1685:16: In procecure raise-exception:
> Value our of range 0 to 18446744073709551615:
> 42540578165178177408896616697074944157
>
> Best,
> Jack
I should have specified: now neither v4 or v6 work.
Best,
Jack
next prev parent reply other threads:[~2022-05-13 15:27 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-09 10:39 bug#55335: openssh-service no longer listens on IPv6 Christopher Baines
2022-05-13 12:21 ` Christopher Baines
2022-05-13 14:23 ` bug#55335: [PATCH] services: Allow shepherd to listen for IPv6 connections to openssh Christopher Baines
2022-05-13 15:23 ` Jack Hill
2022-05-13 15:25 ` Jack Hill [this message]
2022-05-14 8:42 ` bug#55335: openssh-service no longer listens on IPv6 Ludovic Courtès
2022-05-14 14:16 ` Ludovic Courtès
2022-05-18 14:06 ` bug#55335: [PATCH Shepherd 0/3] Endpoints for inetd services + IPv6-only endpoints Ludovic Courtès
2022-05-18 14:06 ` bug#55335: [PATCH Shepherd 1/3] service: 'make-inetd-constructor' accepts a list of endpoints Ludovic Courtès
2022-05-18 14:06 ` bug#55335: [PATCH Shepherd 2/3] tests: Update inetd tests to pass " Ludovic Courtès
2022-05-18 14:06 ` bug#55335: [PATCH Shepherd 3/3] Interpret AF_INET6 endpoints as IPv6-only Ludovic Courtès
2022-05-18 14:28 ` bug#55335: openssh-service no longer listens on IPv6 Ludovic Courtès
2022-05-22 20:08 ` Ludovic Courtès
2022-05-22 22:35 ` Jack Hill
2022-05-23 13:30 ` Ludovic Courtès
2022-05-23 15:29 ` Simon Streit
2022-05-14 15:49 ` Ludovic Courtès
2022-05-14 19:09 ` Jack Hill
2022-05-17 21:33 ` Christopher Baines
2022-05-18 9:30 ` Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://guix.gnu.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.DEB.2.21.2205131125260.11587@marsh.hcoop.net \
--to=jackhill@jackhill.us \
--cc=55335@debbugs.gnu.org \
--cc=mail@cbaines.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).