| Revision History | ||
|---|---|---|
| Revision 0.05 | 2003-11-19 | Revised by: yh |
| Corrections regarding ssh. | ||
| Revision 0.04 | 2003-10-30 | Revised by: yh |
| Modification accordingly with the new interface. | ||
| Revision 0.03en | 2002-04-22 | Revised by: yh |
| English translation. | ||
| Revision 0.03 | 2002-03-26 | Revised by: yh |
| DocBook port, finalization. | ||
This document is an HOWTO about configuring your computer to retrieve mails using UUCP, using UUCP service helded by UUCPSSH.ORG (a service provided by LinuxFr association ).
UUCP is a unix to unix copy protocol. We use it here as a mail retrieval protocol, considered here as well as POP or IMAP (for it's IP usage). UUCP let you receive emails without having a permanent internet connexion, nor constraints regarding duration of mail keeping on the server.
Both usage of UUCP and SSH give you waranty about retrieval security, and UUCPSSH.ORG service has following points:
A backup MX is given in case of main computer failure
A backup of UUCP accounts is done every 10 minutes, preventing from an important mail loss in case of a global main computer failure.
Contributors to this document, direct or not, for their remarks, tests, add-ons and modifications are:
Fabien Penso <penso at linuxfr.org>
Laurent Vallar <vallar at linuxfr.org>
Pascal Terjan <pascal.terjan at free.fr>
Raphaël Enrici <blacknoz at club-internet.fr>
If when reading - or when applying informations given in this document -
you find vague items, particular cases to report, items to add or items
to be modified, or translation to correct, feel free to send an email:
<hirou at linuxfr.org>
This document describes some modifications that has to be done on the client computer, as root. Neither Author nor contributor can be responsible of bad effects of such commands, including but not limited to data loss and hardware failure. You will apply them at your own risks.
Usage of the LinuxFr association service through its site uucpssh.org, as described in this document, is subject to disclaimer acceptation, disclaimer available at: http://www.uucpssh.org/disclaimer.en.html
To begin, you have to indicate in the DNS configuration of yourdomain.org that your mailservers are these of UUCPSSH.ORG. So all mails for yourdomain.org will be received by UUCPSSH.ORG mail servers.
Next, it is necessary to configure UUCPSSH.ORG mail servers so they will accept mails for yourdomain.org.
At the end, you have to configure your client computer and UUCP server to let them authenticate each other, communicate and transfer mails.
LinuxFr offers an UUCP service using SSH, through it's site UUCPSSH.ORG. To use it, you need to:
subscribe, by creating an account on http://www.uucpssh.org/index.php/askaccount.en.html
configure your zone's DNS to put main.uucpssh.org. and mx-backup.uucpssh.org. computers as MX, with preference values equal to 10 for mx, and 20 for mx-backup. Created zones will be marked as active only if our servers are used as MX in the DNS configuration of your zone.
install and configure UUCP on your computer
install and configure a mail server on your computer
register yourdomain.org on http://www.uucpssh.org/index.php/admin.en.html, as well as your RSA key for ssh connexion.
Second point could be easily done if you can manage your DNS yourself. If not, ask your DNS hoster to add the MX records.
If you are looking for a free DNS server, some exists: XName.org, Secondary.com, GraniteCanyon.com for example. Our choice will go preferably on XName.org, but everyone is free :-). Your hosting choice does not modify UUCPSSH.ORG service, only MX records are needed.
If you do not have a domain name at this time, Gandi will permit you to buy one (under .com, .net, .org, .info) with interesting price. In this case, we recommend you to use XName.org as primary DNS server, and Gandi DNS server as secondary.
Points 3,4 and 5 are helded in next section.
First step: create an UUCP account on UUCPSSH.ORG (one per client computer). To do so, use the page https://www.uucpssh.org/index.php/askaccount.en.html.
Second step: configure your client computer.
Configure your local mail server to accept incoming mails for your zone.
If you are using postfix, adding yourdomain.org in $mydestination variable in the main.cf configuration file should be sufficient.
If you are using sendmail, adding DOMAIN('yourdomain.org') in m4 configuration file should be sufficient (do not forget to regenerate sendmail.cf)
If you are using an other mail server, thank you to contact me so the procedure could be added.
Edit file /etc/uucp/config to specify your computer name. WARNING: it is necessary the name of your UUCP account on uucpssh.org. But it is not necessary the real name of your computer, it is only the name that UUCP will send to our server to retrieve mails.
Edit file /etc/uucp/port and add at the end:
port SSH type pipe command /usr/bin/ssh -C -x -o batchmode=yes uucp@main.uucpssh.org |
Edit file /etc/uucp/sys and add at the end:
system uucpssh call-login * call-password * time any address main.uucpssh.org port SSH protocol t remote-send / remote-receive ~ |
Edit file /etc/uucp/call and add at the end:
uucpssh yourlogin password |
Generate your RSA key to be able to connect using SSH:
Become uucp user (su - uucp). If it does not exist, create it.
Execute ssh-keygen -t dsa
do not give any password.
Third step: add your zone and your DSA key on UUCPSSH.ORG, using your account administration page, http://www.uucpssh.org/index.php/admin.en.html.
Fourth and last step: once the mail confirming your zone integration has been received, test, and add a line in your crontab to retrieve mails at your wanted frequency. Warning, as server configuration is generated once per hour, we suggest you to wait one hour between mail confirmation receipt and tests.
Test: as uucp user, execute command ssh uucp@main.uucpssh.org -v and accept to save server's RSA key. You should then have UUCP prompt.
Next, execute /usr/sbin/uucico -f -suucpssh, it's the command used to retrieve mails.
Add following line in uucp user crontab, to retrieve mails each 10mn:
*/10 * * * * /usr/sbin/uucico -f -suucpssh |
Is it possible to have more than one UUCP-SSH account for different domains, hosted on different UUCP servers, but with mail retrieved on the same client computer?
Yes. You only have to be careful, and to use a different port name in /etc/uucp/port for each UUCP server, as well as in /etc/uucp/sys. For example, we can define in /etc/uucp/port a new port, named SSHLinuxfr, that we will use after in /etc/uucp/sys instead of the SSH port of our sample:
/etc/uucp/port: port SSHLinuxfr type pipe command /usr/bin/ssh -C -x -o batchmode=yes uucp@main.uucpssh.org |
/etc/uucp/sys: system uucpssh call-login * call-password * time any address main.uucpssh.org port SSHLinuxfr protocol t remote-send / remote-receive ~ |
Your computer name (your login) has to be the same for the different UUCP servers, in /etc/uucp/config.
Is it possible to have more than one UUCP-SSH account on UUCPSSH.ORG?
No. But one account can manage more than one zone.
I can not connect using ssh.
Try again forcing protocol, it means adding -1 option to ssh. Besides, you can also test with and without batchmode=yes parameter of ssh. Do not forget to modify file /etc/uucp/port accordingly.
I have created a zone, I have received validation email, but I can not connect.
Configuration files on the server are regenerated once
per hour. If the validation email has been sent less than
one hour ago, it is possible that your access is not already
open. If problem persists, contact technical team using
<uucpadmin at uucpssh.org>.
How to migrate from old system to new system, after 19/11/03 ?
Old users have to create a new account on http://www.uucpssh.org, and to switch MX for all zones from mx.uucpssh.org to main.uucpssh.org. It is highly recommended to use mx.uucpssh.org AND main.uucpssh.org as uucp server during one week, to be sure that no mail will be lost while DNS propagation. Refer to first point of this FAQ to see how to have multiple uucp servers (change port name, system name, and server name).