mirror of
https://github.com/termux/proot.git
synced 2024-11-11 13:49:26 +00:00
26 lines
918 B
Bash
26 lines
918 B
Bash
if [ -z `which id` ] || [ -z `which uname` ] || [ -z `which grep` ]; then
|
|
exit 125;
|
|
fi
|
|
|
|
! ${PROOT} ${PROOT_RAW} /bin/true
|
|
if [ $? -eq 0 ]; then
|
|
exit 125;
|
|
fi
|
|
|
|
${PROOT} ${PROOT_RAW} -0 id -u | grep ^0$
|
|
${PROOT} ${PROOT_RAW} -i 123:456 id -u | grep ^123$
|
|
${PROOT} ${PROOT_RAW} -k 3.33.333 uname -r | grep ^3\.33\.333$
|
|
|
|
${PROOT} -0 ${PROOT_RAW} id -u | grep ^0$
|
|
${PROOT} -i 123:456 ${PROOT_RAW} id -u | grep ^123$
|
|
${PROOT} -k 3.33.333 ${PROOT_RAW} uname -r | grep ^3\.33\.333$
|
|
|
|
${PROOT} -0 ${PROOT_RAW} -k 3.33.333 id -u | grep ^0$
|
|
${PROOT} -0 ${PROOT_RAW} -k 3.33.333 uname -r | grep ^3\.33\.333$
|
|
|
|
${PROOT} -k 3.33.333 ${PROOT_RAW} -0 id -u | grep ^0$
|
|
${PROOT} -k 3.33.333 ${PROOT_RAW} -0 uname -r | grep ^3\.33\.333$
|
|
|
|
${PROOT} -i 123:456 ${PROOT_RAW} -k 3.33.333 id -u | grep ^123$
|
|
${PROOT} -k 3.33.333 ${PROOT_RAW} -i 123:456 id -u | grep ^123$
|