#!/bin/bash ##CageFS proxyexec wrapper - ver 16 if [[ $EUID -eq 0 ]]; then echo 'Cannot be run as root' exit 1 fi USR=`/usr/bin/whoami` TOKEN=`/bin/cat /var/.cagefs/.cagefs.token` # It's user's tmp directory and write to it is secure procedure # because this script is running only under usual user PIDFILE="/tmp/.cagefs.proxy.$$" USER_INTERRUPT=13 CWD=`pwd` ctrl_c_handler() { if [[ -f "$PIDFILE" ]]; then pid=`/bin/cat $PIDFILE` /bin/rm -f $PIDFILE > /dev/null 2>&1 /bin/kill -s SIGINT "$pid" > /dev/null 2>&1 fi exit $USER_INTERRUPT } if [[ -e /var/.cagefs/origin ]]; then ORIGIN=`/bin/cat /var/.cagefs/origin` REMOTE="/usr/bin/ssh -F /etc/ssh/cagefs-rexec_config $USR@$ORIGIN" $REMOTE CAGEFS_TOKEN="$TOKEN" /usr/sbin/proxyexec -c cagefs.sock "$USR" "$CWD" EXIM $$ "$@" RETVAL=$? else trap 'ctrl_c_handler' 2 CAGEFS_TOKEN="$TOKEN" /usr/sbin/proxyexec -c cagefs.sock "$USR" "$CWD" EXIM $$ "$@" RETVAL=$? /bin/rm -f $PIDFILE > /dev/null 2>&1 fi exit $RETVAL
Name | Type | Size | Permission | Actions |
---|---|---|---|---|
chroot | File | 41.52 KB | 0755 |
|
cloudlinux-selector | File | 654 B | 0755 |
|
consoletype | File | 11.86 KB | 0755 |
|
cracklib-check | File | 13.05 KB | 0755 |
|
cracklib-format | File | 251 B | 0755 |
|
cracklib-packer | File | 13.05 KB | 0755 |
|
cracklib-unpacker | File | 9.03 KB | 0755 |
|
create-cracklib-dict | File | 990 B | 0755 |
|
ddns-confgen | File | 20.46 KB | 0755 |
|
dnssec-checkds | File | 936 B | 0755 |
|
dnssec-coverage | File | 938 B | 0755 |
|
dnssec-dsfromkey | File | 60.84 KB | 0755 |
|
dnssec-importkey | File | 60.84 KB | 0755 |
|
dnssec-keyfromlabel | File | 64.76 KB | 0755 |
|
dnssec-keygen | File | 72.84 KB | 0755 |
|
dnssec-keymgr | File | 934 B | 0755 |
|
dnssec-revoke | File | 56.74 KB | 0755 |
|
dnssec-settime | File | 60.84 KB | 0755 |
|
dnssec-signzone | File | 117.2 KB | 0755 |
|
dnssec-verify | File | 52.84 KB | 0755 |
|
exim | File | 1.02 KB | 0755 |
|
faillock | File | 20.52 KB | 0755 |
|
genrandom | File | 12.38 KB | 0755 |
|
ip | File | 693.3 KB | 0755 |
|
isc-hmac-fixup | File | 11.86 KB | 0755 |
|
ldconfig | File | 986.02 KB | 0755 |
|
mkhomedir_helper | File | 24.43 KB | 0755 |
|
named-checkzone | File | 36.63 KB | 0755 |
|
named-compilezone | File | 36.63 KB | 0755 |
|
nsec3hash | File | 12.29 KB | 0755 |
|
pam_console_apply | File | 45.2 KB | 0755 |
|
pam_timestamp_check | File | 11.87 KB | 0755 |
|
pluginviewer | File | 20.57 KB | 0755 |
|
proxyexec | File | 21.17 KB | 0555 |
|
pwhistory_helper | File | 20.44 KB | 0755 |
|
saslauthd | File | 94.42 KB | 0755 |
|
sasldblistusers2 | File | 20.77 KB | 0755 |
|
saslpasswd2 | File | 16.42 KB | 0755 |
|
sendmail | File | 1.02 KB | 0755 |
|
snmpd | File | 32.45 KB | 0755 |
|
snmptrapd | File | 32.6 KB | 0755 |
|
testsaslauthd | File | 16.66 KB | 0755 |
|
tmpwatch | File | 35.47 KB | 0755 |
|
tsig-keygen | File | 20.46 KB | 0755 |
|
unix_chkpwd | File | 36.86 KB | 0755 |
|
unix_update | File | 36.87 KB | 0700 |
|