Procmail: Edit .procmailrc
Jump to navigation
Jump to search
Check Shell
Check shell
which sh
akan keluar
/bin/sh
Buat ~/.procmailrc
Edit file ~/.procmailrc
vi ~/.procmailrc
#Preliminaries SHELL=/bin/sh #Use the Bourne shell (check your path!) MAILDIR=/var/spool/mail/ #First check what your mail directory is! LOGFILE=${MAILDIR}/procmail.log LOG="--- Logging ${LOGFILE} for ${LOGNAME}, " #Whatever recipes you'll use #The order of the recipes is significant :0 * ^From: scam@cyberspam\.com /dev/null # Accept all the rest to your default mailbox :0: ${DEFAULT}
Pastikan spamreport bisa membaca file tersebut
chmod u+r ~/.procmailrc
Check lokasi procmail dan ID myid
Cek lokasi procmail
which procmail
keluar
/usr/bin/procmail
Cek ID myid
whoami
Keluar
myid
Konfigurasi .forward
Edit .forward
vi ~/.forward
masukan kalimat
"|IFS=' ' && exec /usr/bin/procmail || exit 75 #myid"
Ubah permission .forward
chmod 644 ~/.forward
Cek permission myid
Cek permission home directory myid
ls -lFd ~/
pastikan keluar
drwx--s--x
atau
drwxr-xr-x
Jika tidak lakukan
chmod u+rwx ~/ chmod og+x ~/ ls -lFd ~/