enamel - the mailserver for the B eOS
Contents [ enamel ] [ Introduction ] [ Licence ] [ Features ] [ Restrictions ] [ What's new? ] [ Future ] [ History ] [ Installation ] [ Configuration ] [ Usage ] [ Availability ] [ Known bugs and problems ] [ Thanks ] | Configuration Depending on what you want to do, you will need only some or all of these programs. You are able to configure everything from a simple single user email account to a full featured email server, including news. The main idea behind enamel is, that you have a single program for every job you want to do - and maybe some additional scripts that bring in the features that are missing to fulfill your personal needs. In a typical setup, pop3 will get your mail from your mailbox and store the new messages on the disk. pop3 might get some more mail from several other mailboxes, too. In theory, you could now start reading the mail. But in practice, it's time for MCP to do it's job. MCP notices that new messages came in, picks them up and processes them. It sorts the messages by certain cretaria, and moves them to their internal targets on you machine, sometimes even routing the same message to several targets. Such a target, this could be an end user like you and your girlfriend (You for sure want your mail separated!), it could be another deamon which checks your messages for encrypted content to decrypt it, or a deamon who sorts out spam or it could even be the smtp or pop3d who will pass that mail on to another machine. To read the messages that are yours, you can use one of the mightiest features BeOS has - the Query mechanism. With those queries you can search for your old mail, for your new mail, for mail in a specific mailinglist or whatever you want. To display and create messages, you can use hermes, enamels mail and newsreader. If you want to combine the flexibility of enamel with your common mailreader, just set enamel up to your own mailhost. Everything is linked by a standardized file format: message/rfc822. In these files, the whole message is stored in the common ascii format. Additional to that, the header fields and some special information is added as attributes. The header attribute names are constructed from the header field names prepended by "Message822:". For example the "To:" line is stored as "Message822:To". Additional to that, the following attributes are used by enamel: Enamel:status Currently, enamel only knows "New" for new messages and "Old" for old ones. But a mail reader could for example use "Postponed" for messages that are not yet ready to send, or an expire tool could use "Expired" or "Deleted" for messages that are marked to be removed. "Archived" could be used for messages that should not be deleted, etc... Enamel:recipients In the recipients field, the email addresses of all recipients who still have to get this message is stored. For example when you write a new message to yourself and someone else, both addresses will be put into the recipients field by the mail client. The next one to pick up this message normally is MCP. MCP (if configured right) then splits the message into two new messages, one with recipients set to your address, one with recipients set to the others address. Enamel:target The target is the most important field. A target is a kind of an internal address. smtpd for example sets the target of a recieved message to "MCP". MCP picks up all messages with the target "MCP" and the status "New". Depending on the configuration and the recipients field (see above), the message is copied (once or more) with a new target field and the original message's status is set to "Old". smtp can be configured to pick up messages with a given target field and send them to a given host. The same goes for pop3d, with the exception that pop3d waits for a client to connect and identify itself as the recipient for that target. With this concept, you could for example tell MCP to set all outgoing messages target field to "outgoing". Another application could pick up these messages and filter them for spam (in this case, spam is mail that is coming from an outside host and is going to an outside host, where your system is used as a relay only). All valid messages get their target field set to "valid.outside" and are picked up by smtp and are sent out. Enamel:source The source is very similar to target. Normally you will only need this if you use nntp to read news with enamel. Every application of the enamel package is able to set the Enamel:source attribute. This way MCP is able to route depending on where the message came from. This becomes really important if you read news with enamel: Normally, all articles that come in via nntp will be sent out via nntp again, because those articles are new and they match MCP's routing pattern for news. The same goes for emails you recieve that have a Newsgroups: header. You can use this trick to post articles by sending an email to your own email address with a Newsgroups: header set. But the bad thing is, that anyone could do that. So this is what the source attribute is for. You just tell hermes for example to add the source "hermes" to all articles that are written by you. And then you tell MCP to route only articles with the source "hermes" set to nntp. Enamel:folder The folder is normally set by MCP. If no folder is set, the attribute is set to "None". The folder attribute is an easy way to sort your messages by a certain creteria. You can use MCP to set the folder depending on queries, write your own scripts to do that or just set them by hand. Enamel:fromname This is the realname part from the "From:" field. It's not here for technical reasons, just to have the realname for display in Tracker queries. Enamel:fromaddress This is the email address part from the "From:" field. Same reasons as above. Before we have a look at how to configure the enamel components, one important remark: All these applications work a lot with queries or live queries. These queries are heavily based on the configuration you set, sometimes you can even define the complete query by yourself. To make you save from accidently cleaning up your hard disk, all these queries are bound to work with files of the type "message/rfc822" only. MCP smtp smtpd pop3 pop3d nntp hermes