Have you read perlsec? There is plenty of wisdom there regarding running with elevated privileges.
[my script] needs to mount/umount the device
How does it do this? If it shells out, you can just run mount/umount with sudo and then your script won't need any elevated privileges in the first place.
🦛
In reply to Re: mounting device from a script
by hippo
in thread mounting device from a script
by geoffleach
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |