macolo
07.02.03, 23:24
hallo, ich möchte, dass ssh-user eine limitierte bash kriegen. ich dachte, das lös ich so:
#!/bin/bash
exec /bin/bash --login --rcfile /leviathan/dmf/.restricted/bash.conf --noprofil
export PATH=/leviathan/dmf/.restricted/bin/
umask 000
set -r
echo "restricted"
echo "hello $USER"
echo "bash instance $SHLVL"
HERE
funktioniert ganz schön, ausser dass am schluss dieses skriptes die bash sich die bash scheinbar beendet: :( :mad:
x1a2p7:/leviathan/dmf/.restricted # ssh -l dmf localhost
dmf@localhost's password:
Last login: Fri Feb 7 23:28:04 2003 from localhost
Have a lot of fun...
No mail.
restricted
hello dmf
bash instance 1
Connection to localhost closed.
und --rcfile /leviathan/dmf/.restricted/bash.conf wird auch nicht ausgeführt! und nirgends ne doku! :(
weiss jemand, wieso?
tia, greets
macolo
#!/bin/bash
exec /bin/bash --login --rcfile /leviathan/dmf/.restricted/bash.conf --noprofil
export PATH=/leviathan/dmf/.restricted/bin/
umask 000
set -r
echo "restricted"
echo "hello $USER"
echo "bash instance $SHLVL"
HERE
funktioniert ganz schön, ausser dass am schluss dieses skriptes die bash sich die bash scheinbar beendet: :( :mad:
x1a2p7:/leviathan/dmf/.restricted # ssh -l dmf localhost
dmf@localhost's password:
Last login: Fri Feb 7 23:28:04 2003 from localhost
Have a lot of fun...
No mail.
restricted
hello dmf
bash instance 1
Connection to localhost closed.
und --rcfile /leviathan/dmf/.restricted/bash.conf wird auch nicht ausgeführt! und nirgends ne doku! :(
weiss jemand, wieso?
tia, greets
macolo