Вы в основном ищете
find /tmp/mnt -iname '*.squashfs' -exec unsquashfs {} \;
{}
заменяется путем к соответствующему файлу.
Если вы хотите указать каталог для извлечения, передайте параметр -d
.
find /tmp/mnt -iname '*.squashfs' -exec unsquashfs -d /tmp/unsquashedfs/files {} \;
Вы пробовали управлять PAM sufficient
? Перpam.conf(5)
sufficient
if such a module succeeds and no prior required module has failed
the PAM framework returns success to the application or to the
superior PAM stack immediately without calling any further modules
in the stack. A failure of a sufficient module is ignored and
processing of the PAM module stack continues unaffected.
Это должно остановить обработку на вашей пользовательской строке:
auth sufficient pam_exec.so expose_authtok /usr/bin/custom-pam.sh
если он не терпит неудачу, что может быть обработано последующим nope -, отрицающим -вас -здесь.