From f1eb043eac659b118457eaefe3030c13f5b3b1ac Mon Sep 17 00:00:00 2001 From: steering7253 Date: Fri, 10 Apr 2026 02:01:42 +0000 Subject: fix creating account from ipv6 --- authorized_keys.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/authorized_keys.sh b/authorized_keys.sh index f64fc72..ec82497 100755 --- a/authorized_keys.sh +++ b/authorized_keys.sh @@ -6,7 +6,7 @@ user="$1" if [ "$1" = "new" ]; then type="$2" key="$3" - connection="$4" + connection="$(echo "$4" | tr : _)" if user="$(grep -l -s -r -P '^\s*auth:\s*\Q'"$type"'\E\s+\Q'"$key"'\E$' /opt/autopeer/dn42-registry/data/mntner/ | perl -ne 's@^.*/@@; s@-MNT$@@; print lc;' | head -1)"; then perl -ne 'print if s@^\s*auth:\s*ssh-@restrict,pty ssh-@'