summaryrefslogtreecommitdiff
path: root/src/openssh/AuthorizedKeysCommand
diff options
context:
space:
mode:
authorGordon GECOS <u@adam>2023-06-02 18:20:15 -0400
committerGordon GECOS <u@adam>2023-06-02 18:21:18 -0400
commit6c5b2b2f7c6ea156d5f71fa814d51c85466501d0 (patch)
tree52e960afb6d73a617add2ea651dcc3f80292e55d /src/openssh/AuthorizedKeysCommand
parent3e796eebdc1dd3ab96641bb147e4810d2fc41be5 (diff)
renamesHEADmaster
Diffstat (limited to 'src/openssh/AuthorizedKeysCommand')
-rw-r--r--src/openssh/AuthorizedKeysCommand11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/openssh/AuthorizedKeysCommand b/src/openssh/AuthorizedKeysCommand
new file mode 100644
index 0000000..de0732a
--- /dev/null
+++ b/src/openssh/AuthorizedKeysCommand
@@ -0,0 +1,11 @@
1#!/bin/sh
2username=$1
3shift
4
5[ "$username" ]
6cmd=/etc/ssh/user-$username.AnonymousForceCommand
7[ -x "$cmd" ] || exit
8
9key=$1
10shift
11printf 'restrict,pty,command="%s" %s\n' "$cmd" "$key"