Subj : allow non root user access to ufw To : All From : Zylone Date : Fri Aug 27 2021 11:57 am Hello all, I wanted to share something with everyone. I am running Mystic on Linux, and did not want to run it under root for obvious reasons. So, with that said.. this means the IP blocked event will not run properly because the user mystic is running under does not have permission to run ufw. Let's assume the user account Mystic is running under is 'bbs'. Now, we could just add user bbs to the /etc/sudoers file, but now we are practically in the same boat as running Mystic as root! We only want the bbs user account to have access to ufw to add blocking rules! No other superuser access! Here is what I did.. (on Ubuntu 20.04) I added a file in /etc/sudoers.d/ and within that file I put the following: bbs ALL=(root) NOPASSWD:/usr/sbin/ufw This states give user bbs sudo access to ONLY ufw and run it as user root, and do not prompt for a password when executing sudo ufw. Try it, you can sudo ufw, but not any other command! Close and save said file, and then update file permissions: chmod 0440 This gives ONLY root read access to this file. (This is a stated requirement in the README file in the same directory). Now, go to your IP Blocked event in mystic -cfg, and prefix the Shell command with sudo. The shell command should now look like the following: sudo ufw deny from @IP@ That's it! :) |15Z|07ylone --- Mystic BBS v1.12 A47 2021/08/19 (Linux/64) * Origin: pLANET cARAVAN BBS (21:3/150) .