Most of this documentation is based on the pioneering work of Emory Lundberg. From a shell, run /root/tmda.setup.sh and you're done! Please browse through these instructions anyway if you want to do anything beyond the basics. If you run the tmda.setup.sh script, don't run the commands. That's what the script does.* *NEW! Non-Rupture user? You can download Rupture's configuration templates and setup script here. You will likely need to modify things to reflect your local environment. If you want, you can create a whitelist. This will allow the people you currently correspond with to email you without worrying about the initial confirmation. You probably don't want to type every one of your friends' email addresses manually. There is a script that will harvest your friends' addresses from your saved messages for you. *NOTE* This step is completely optional. If you don't put their address in the whitelist, they will be asked for confirmation upon their next email to you. generic@froody:~> cd ~/mail/ && /usr/local/share/examples/tmda/collectaddys >> ~/.tmda/lists/whitelist Let's get started. I'll use the user called 'generic.' Make sure to put your own info in when required. Copy and paste the commands. generic@froody:~> mkdir -p ~/.tmda/lists generic@froody:~> mkdir -p ~/.tmda/filters creates the main tmda directory in your home directory. creates the lists directory, where you store your whitelist, blacklists, etc. creates the filters directory, where you store your incoming, outgoing filters. tmda logs, the pending queue, configuration lists for incoming and outgoing mail will go here generic@froody:~> touch .procmailrc-tmda creates an empty procmailrc just for tmda generic@froody:~> touch .procmailrc if you don't have one already generic@froody:~> touch .tmda/config creates an empty config file for tmda generic@froody:~> touch ~/.tmda/lists/whitelist generic@froody:~> touch ~/.tmda/lists/whitelist_confirmed generic@froody:~> touch ~/.tmda/lists/whitelist_wildcards generic@froody:~> touch ~/.tmda/lists/blacklist generic@froody:~> touch .tmda/filters/outgoing creates empty outgoing filter file generic@froody:~> touch .tmda/filters/incoming creates empty incoming filter file If you have not setup procmail yet, you *MUST* set that up first. See Rupture Procmail for information. If you need more help with procmail, email the admin. generic@froody:~> cd generic@froody:~> cp /root/tmda/rupture.config .tmda/config generic@froody:~> chmod 600 .tmda/config makes nice permissions on that file. you can edit it, but nobody else can even look at it. Now you need a KEY to do the magic. generic@froody:~> tmda-keygen -b > .tmda/crypt_key generic@froody:~> chmod 600 .tmda/crypt_key You might want to change some things in ~/.tmda/config, including your FULLNAME: generic@froody:~> pico .tmda/config # FULLNAME = "Your Name" --> FULLNAME = "Roberto Clemente" See /usr/local/lib/python2.2/site-packages/TMDA/Defaults.py for all possible config items. One especially nice trick is to add spammers to your blacklist when their messages are deleted by tmda-pending. This means that future messages from this sender will be automatically dropped without going through the confirmation process. If you want to do this, uncomment this line in ~/.tmda/config : # PENDING_DELETE_APPEND = os.path.expanduser("~/.tmda/lists/blacklist") --> PENDING_DELETE_APPEND = os.path.expanduser("~/.tmda/lists/blacklist") Now create the incoming and outgoing filter files. generic@froody:~> cd generic@froody:~> cp /usr/local/share/doc/tmda/contrib/rupture.incoming .tmda/filters/incoming generic@froody:~> cp /usr/local/share/doc/tmda/contrib/rupture.outgoing .tmda/filters/outgoing Feel free to edit those files. They might prove confusing - don't touch anything you're not sure about. A good idea might be to copy/paste lines to copy the sytax. Ie, in .tmda/filters/incoming, make: # Accept all messages from rupture.net from *@=rupture.net ok --> # Accept all messages from rupture.net from *@=rupture.net ok from *@=bighoser.com ok from *@=bbglovepuppet.com ok from *@=flavorj.com ok This lets users @ bighoser.com, bbglovepuppet.com, and flavorj.com send email to you without require confirmation. The outgoing filters are only required if you want to send dated emails. They're not enabled by default, and you probably don't want to mess with them. At least not at first. They're also only for use with terminal-based mail clients like pine, or mutt. If you use TWIG or a desktop mail client (Outlook Express, Entourage), these are not for you. Now you should edit at ~/.tmda/lists/whitelist and make sure you really want all those people to send you unconfirmed emails. If you sort ~/mail/* into subfolders, cd into those subfolders and run the collectaddys script >> ~/.tmda/lists/whitelist from there too. Now import the rc.tmda file for procmail: generic@froody:~> cp /root/tmda/rupture.procmail.tmda.rc .procmail/rc.tmda Now edit your .procmailrc-tmda file you created in the beginning: DEFAULT=$HOME/mbox If you followed the Procmail Setup Instructions and have your ~/.procmailrc and ~/.procmail/rc.tmda files in place, edit ~/.procmailrc and allow rc.tmda to run: #INCLUDERC=$PMDIR/rc.tmda --> INCLUDERC=$PMDIR/rc.tmda This is also covered in the Procmail Setup Instructions. Make sure that rc.tmda is the last INCLUDERC file included. It goes at the VERY END because you want procmail to do whatever procmail does FIRST before hand-off to TMDA. For example, this lets you sort all your list mail to inboxes before TMDA gets involved. It also means, however, that you will need to specify rules for all your mailing list. Otherwise, all hell is likely to break loose. Every mailing list email will get a confirm request, and people on the list will not stand for that. Be careful that your mailing list email is properly sorted first. See the Rupture Procmail page for comprehensive help. Next, make sure you don't have a ~/.forward file: generic@froody:~> mv .forward .crap.forward With procmail as our Local Delivery Agent, a .forward pointing things to procmail actually breaks stuff. You're filtering mail with TMDA now. Should something go wrong, remove the .procmailrc file, or mv it to something else like .procmailrc-busted-as-shit. How do you know if something goes wrong? Look at the logs. generic@froody:~> tail ~/.tmda/debug.log generic@froody:~> tail ~/.tmda/incoming.log Date: Sat Apr 6 13:19:16 EST 2002 Sndr: error-1-2231807-126-643037@staff.theuseful.com From: Casino Elegance To: generic@rupture.net Subj: Deposit $1 and get $30 Free Cash Actn: CONFIRM pending 1018117156.14975.msg You never had to see that message. It is pending CONFIRMation from the sender, which will never happen. Ie you dodged a bullet of spam. You can also keep track of all the spam attempts. Run tmda-pending and see what you have: generic@froody:~> tmda-pending 1018375599.60935.msg (13 of 20 / 4009 bytes) >> Date: Tue, 09 Apr 2002 13:41:07 -0400 >> From: Unitek
Pass means leave it be. If you think there is a chance this is a
legitimate message and the sender will confirm, choose to pass. But the point is not to see these spams! If you reach the point where you're comnfident all pending messages are spam, you can delete them all: generic@froody:~> tmda-pending -b -d Or, just delete the messages that have been pending for more than 10 days or so (It might make sense to put this in your crontab): generic@froody:~> tmda-pending -q -b -d -O 10d Cron is tricky. Please see Rupture Cron for more information. Once you've read that, make this your crontab: # my happy cron jobs PATH="/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin:/home/generic/bin" 30 3 * * * tmda-pending -q -b -d -O 14d 30 15 * * * tmda-pending -C -b -s | mail -E -s 'TMDA pending summary' generic+keyword+summary.XXXXXX@rupture.net > /dev/null 2>&1 The second entry will send you a summary of new pending messages at 3:30PM daily. Make sure that this entry is all on one line. Also, you should probably use a keyword address as the recipient. Ie from the command line, do: generic@froody:~> tmda-address -k summary generic+keyword+summary.XXXXXX@rupture.net generic@froody:~> Insert this keyword address in the crontab entry above. Using a keyword recipient will ensure that the pending summary gets through to your mailbox. You can also try 'tmda-pending -h | more' or 'tmda-address -h | more' to see all the options. You can do a lot of cool stuff with it. If you got this far and would like to use dated or tagged email addresses, read the client document. |
<admin*rupture.net>
File
/tmda/setup.shtml
was last updated :
07:47 PM 08/17/15