summaryrefslogtreecommitdiff
path: root/src/opt/vyatta/bin/restricted-shell
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2024-06-30 07:35:25 +0200
committerChristian Breunig <christian@breunig.cc>2024-06-30 22:12:57 +0200
commit72a704d2e2b06bfedc4f1ee841814f983fc34baa (patch)
treefaa4cf1ea5fb58d414f426622ce255256e4a3ec6 /src/opt/vyatta/bin/restricted-shell
parent7d91768a746a000bf26d737eb1612536d0454ad1 (diff)
downloadvyos-1x-72a704d2e2b06bfedc4f1ee841814f983fc34baa.tar.gz
vyos-1x-72a704d2e2b06bfedc4f1ee841814f983fc34baa.zip
T6527: add legacy Vyatta interpreter files still in use
Diffstat (limited to 'src/opt/vyatta/bin/restricted-shell')
-rwxr-xr-xsrc/opt/vyatta/bin/restricted-shell11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/opt/vyatta/bin/restricted-shell b/src/opt/vyatta/bin/restricted-shell
new file mode 100755
index 000000000..ffcbb53b7
--- /dev/null
+++ b/src/opt/vyatta/bin/restricted-shell
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+if [ $# != 0 ]; then
+ echo "Remote command execution is not allowed for operator level users"
+ args=($@)
+ args_str=$(IFS=" " ; echo "${args[*]}")
+ logger "Operator level user $USER attempted remote command execution: $args_str"
+ exit 1
+fi
+
+exec vbash