Bringing cheap email to the masses using Linux

208

Author: JT Smith

By Russell Pavlicek

Some of us spend a large amount of time trying to convince the corporate
world that Open Source software is ready for business. But every once in
while, it is refreshing to remember that Open Source can be used to do
things for people who have very little money, like my
recent experimentation with a CIDCO
Mailstation
.

The hardware

For those of you who have not seen the device, the Mailstation (also known
as a Mivo 100) is an email appliance for people who do not have — or do
not want — access to a PC. It is literally an attempt at making an email
appliance that your grandmother could use. And it does a pretty good job
of hitting that target.

The unit is smaller than a laptop, weighs about two pounds, and normally
sells at about USD $100 for the cheaper models. The concept is simple: through this basic push-button appliance, you can send and retrieve email (without
HTML, graphics, or attachments) for USD $9.95 per month.

If you have been on eBay lately or visited your local used computer parts
vendor, you may have noticed there’s a significant supply
of refurbished Mailstations on the market. For around US $20,
you can pick up one of these units. But there is a catch: CIDCO will not
allow you to use its Earthlink ISP service with the unit. It’s up to you to
locate an ISP that is compatible with one of these babies.

The scenario

As I considered the fate of these re-tread gizmos, a thought occurred to
me: these items could be the key to email services for cash-strapped
organizations. There are still many people with small
budgets and/or little technical confidence who could benefit from these
devices. And, not so coincidentally, many of these folks come together in
groups, including churches, local theater companies, community centers,
charitable organizations, and senior citizens’ groups.

Refurbished Mailstations could be invaluable for these people — if they
only had access to a cost-effective ISP providing the mail services.
Paying an ISP fee of US $10 to $20 per month per member does not sit well with
groups on a strict budget. If, however, an old PC could be turned into a
simple mail server, even a large group could exchange email for no more
than the cost of one phone line. Because each Mailstation connects with the
server for only a minute or so, one phone line could potentially service
dozens of users. If they need Internet email, then add the cost of a
single monthly fee for ISP services. As all the users will be sending and
retrieving mail through the server, only one ISP account is needed to feed
the server periodically.

Could this be done using a Windows PC? Probably. But then you
would have to deal with the cost of the Microsoft operating system, as
well as the cost of the minimum hardware required to get the system to run
well. Because the problem requires an inexpensive solution for both
hardware and software, the best way to go is Open Source.

The solution

It does not take much to load a first-generation Pentium with Linux and
turn it into a Mailstation server. I suspect an old 486 would probably
work as well, but I did not have a chance to test that scenario.
Furthermore, when I had hardware trouble with the modem on my Linux box, I
quickly replicated the feat on my Pentium 75 NetBSD laptop, so you have
plenty of options here. Described here are the changes I implemented to
my Mandrake 7.2 box to get the link to work. There are other ways of
getting the job done, but this is the approach I used for this problem.

First, add a separate username and password for each Mailstation to be
used. In this case, we will use the username “mailuser” and the password
“mailpass:”

useradd mailuser
passwd mailuser
Changing password for mailuser
(new) UNIX password: mailpass

Then edit the /etc/inittab file to add an entry something like this:

# Mailstation entry:
m0:2345:respawn:/sbin/mgetty -s 115200 /dev/modem

This will create the getty process to service the incoming Mailstation
phone calls. In this instance, /dev/modem is a link to the serial port, which connects to the modem.

Next, edit /etc/ppp/options to include the following parameters for use by
pppd. The list is divided in three groups: parameters you should use,
parameters you might use, and parameters useful for debugging purposes:

# Parameters you should include:
# These options will insist that the Mailstation authenticate itself
# against the user accounts on the server. The PAP protocol will be used
# instead of the CHAP.
login
auth
passive
proxyarp
+pap
-chap
server.ip.address.here:mailstation.ip.address.here

# Parameters that the Mailstation will apparently demand through the
# negotiation phase, so you might want to set them now and save time:
default-asyncmap
default-mru
nomagic
novj

# Parameters which you should consider using when debugging the link:
debug
kdebug 7

Now, edit the /etc/ppp/pap-secrets file. This provides the Mailstation
with the permission needed to authenticate against the server for login
purposes. In the instance below, we are using the username “mailuser”.
The password in this file is blank, because we are authenticating against
the login username and password contained on the server.

# Secrets for authentication using PAP
# client server secret IP address
mailuser * “” 16.72.184.49

We will need to edit /etc/mgetty+sendfax/login.config so that pppd will be
started once the Mailstation dials up. Since the Mailstation does not use
a Unix-like username and password prompt, we will start pppd and have the
Mailstation authenticate using the PAP protocol.

/AutoPPP/ – a_ppp /usr/sbin/pppd 115200

Also, make sure the popd service is uncommented in the /etc/services
files. At this point, you should be able to issue the command “telnet
localhost 110” and see a banner from the POP3 server.

Mailstation settings used:

User Name: YourNameHere
Dial-Up No: phone-number-here
E-Mail Address: mailuser@server.name.here
E-Mail Password: mailpass
POP3 Server: server.name.here
SMTP Server: server.name.here
ISP Account: mailuser
ISP Password: mailpass
Primary DNS: dns.server.number.here
Reply-To:

If you are using a single server, all the server names above should be the
same. If your server does not have a DNS server on it, use IP addresses,
rather than names, for the POP3 and SMTP servers. My testing indicates
that use of numeric IP addresses will eliminate the need for an actual DNS
server.

If you are accessing a single server which will perform all functions, you
are essentially done. If you are using more than one system, such as a
separate DNS server or a separate server for mail functions, you will need
to enable IP forwarding. Under IPV4 on Linux, this can be accomplished
by:

echo 1 > /proc/sys/net/ipv4/ip_forward

Under NetBSD, the equivalent command is:

sysctl -w net.inet.ip.forwarding=1

If you are fortunate enough to have the server connected to the Internet
full time, you do have the opportunity to substitute the email information
for some free email service with POP3 access. For instance, I discovered
that the free email service at nettaxi.com works in this manner. In that
case, you could substitute the following elements in the Mailstation setup
to access the Internet-based email:

E-Mail Address: myemailname@nettaxi.com
E-Mail Password: myemailpassword
POP3 Server: pop1.nettaxi.com
SMTP Server: mail1.nettaxi.com

Note that older forms of the Mailstation (like the one I own) were never
intended to allow the user to modify the server names and other critical
information. It is possible, however, to erase the user information on
the Mailstation and re-enter it. It requires that you enter Mailstation
test mode and perform one of the tests which re-initializes the
user memory. The
I-Appliance BBS
contains the information on this simple
procedure.

Category:

  • Linux