In this project you will configure a web mail MUA called Squirrelmail. This will first require configuring Apache web server.
A web server accepts requests from clients (known as web browsers) for specific documents. Usually these are text documents with HTML formatting, but may be any type of document. In addition a web server can generate documents dynamically, as the result of running separate (external) programs or performing database lookups.
The requests include a URL
which uniquely identifies a document on the internet.
A URL has several parts, including a protocol (such as
http://, https://, ftp://,
etc.), a web server (either an IP address or a
DNS name, such as www.example.com,
mail.example.com, etc.) and an optional
port number (by default
),
a pathname, and optional other data.
A typical example might be
:80http://wpollock.example.com/somedocument.html.
A URL can also point to a directory rather than
a document.
In this case it is up to the web server to determine what document
to return to the client.
Some possibilities include a (nicely formatted) directory listing,
an error message, or some default document.
For Apache the default document is called
(or some variation such as
index.html
or
index.htm
).
A default web page for the top directory of the web server is called
the server's home page.
This is the page you get with a URL similar to
index.php
.)
By default Apache ships with a default http://servername/test
homepage.
You will probably need to change that!
The requests and responses are sent via TCP using HTTP. A request packet may include form data that the user entered on some web page that allows user input (a form), and includes a submit button.
In many cases the user needs both privacy (so no one can eavesdrop) and assurance that they are talking to your website and not some impostor. Both of these goals are met if you use HTTPS connections. (This will be done in a project for the Unix/Linux Security course.)
Squirrelmail is a collection of PHP generated HTML forms that can either directly access mailboxes (MBOX but not Maildir!), or more commonly use an MAA, typically IMAP. Thus you will need to have your mail service (including IMAP) setup and working before you can setup Squirrelmail.
Although Squirrelmail can be configured to use IMAPS, the user enters usernames and passwords (and composed email) in HTML 4.0 forms. The resulting HTTP packet is sent in plain text form to your MAA. This is clearly a security problem! In this assignment we will use the same server for webmail and the MAA, so no sensitive data is transmitted across a network. In general you should only configure webmail from secure HTTPS connections. (This will be done in a project for the Unix/Linux Security course.)
Note!
Fedora may not have correct SELinux policy rules for
Dovecot or other servers.
It is strongly suggested you make sure SELinux is run in
permissive mode for this project.
One way to always boot up in permissive mode is to edit
the file /etc/selinux/config and follow the
comments to change the mode.
Unlike some previous projects, the steps will not include specific commands to run. At this point you are expected to be able to locate relevant commands and documentation using the skills you have learned.
Perform the following tasks and answer the following questions
httpd).
httpd.conf as httpd.conf-original.
Make any changes needed to the Apache web server configuration.
While Apache will work out of the box, you may need to make some changes to turn on or off various features to suit your use as a webmail server. For example there is no need to support fancy indexing, UserDirs, etc. (In real life you would have a static IP address and DNS name, and you may want to support
https://webmail.servername/.)
What changes did you make, and to which
files?
(You can use diff to record the changes made.)
httpd -S.
If any errors are reported, go back and change the incorrect
statements.
Repeat until no errors are detected.
(Be sure to re-run diff to accurately
record the final set of changes made.)
localhost, port TCP/80
(and possibly TCP/443 for HTTPS).
What changed (if any) did you need to make,
and to which file(s)?
localhost?
http://your-server-name/.
For now your server-name is just
localhost).
If you don't see the Apache test page examine the error and
access logs to determine the problem(s).
Once working, make sure your web server will start automatically
at boot time.
What changes did you make to have Apache
start at boot time?
testhomepage with an actual HTML page. This page should contain a brief message about the acceptable use of this server (just for webmail), and a link to the correct URL to use to access Squirrelmail. By default this is
http://localhost/webmail/,
which can be abbreviated as
<a href="/webmail/">webmail</a>.
Be sure the page is legal HTML (or
XHTML).
You can save (with the correct name) and modify this
Basic.htm web page
to create a new default document for your website.
What is the pathname of the default web
page?
What is the contents of your new homepage?
squirrelmail package.
What other packages does this
require?
cd to the Squirrelmail directory
(/usr/share/squirrelmail)
Here you will find the Squirrelmail configuration
program, config/conf.pl.
Run this program (from the Squirrelmail directory)
and record the choices you make.
(If you see a blank screen it is likely the text color
is the same as the background color.
Use the command C (and hit enter)
to turn off colors.)
http://server-name/webmail/src/configtest.php
(Where you can use localhost for
server-name.)
That will run some tests and at the bottom of the page report
the results, hopefully that your configuration is working.
If not, re-run the configuration program and change the incorrect
setting(s).
Repeat until this works.
Don't forget to record all configuration changes as you
make them!
A copy of your journal pages showing the changed made for this project, and the answers to the questions asked above. You can send as email to (preferred). If email is a problem for some reason, you may turn in a hard-copy. In this case the pages should be readable, dated, and stapled together. Your name should appear on the first page.
Don't turn in your whole journal, you will need to add to it every day in class! It is common in fact to keep the journal as a text file on the system (with a paper backup of course).
Please see your syllabus for more information about submitting projects.