summaryrefslogtreecommitdiff
path: root/src/AuthorizedKeysCommand
diff options
context:
space:
mode:
authoru <u@billy>2023-05-29 06:30:11 -0400
committeru <u@billy>2023-05-29 06:30:11 -0400
commit3f7ac1f42b1ae91ec7ea07c0fae562cccd794e0b (patch)
treee47dee88a6df8de82ef62f9512694428bf32cae0 /src/AuthorizedKeysCommand
parent6b55a5205508ef7bb0fa17323e9cfafb4e98b48f (diff)
fix shell escaping to fix systemd
fix for filenames containing hyphens
Diffstat (limited to 'src/AuthorizedKeysCommand')
-rwxr-xr-xsrc/AuthorizedKeysCommand7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/AuthorizedKeysCommand b/src/AuthorizedKeysCommand
new file mode 100755
index 0000000..6bf0ec9
--- /dev/null
+++ b/src/AuthorizedKeysCommand
@@ -0,0 +1,7 @@
1#!/bin/sh
2cmd=/etc/ssh/user-d.AnonymousForceCommand
3[ -x "$cmd" ] || exit
4
5key=$1
6shift
7printf 'restrict,pty,command="%s" %s\n' "$cmd $*" "$key"