accounts without either typing an explicit and unsafe URL or doing a bit of installation
and configuration.
This is on purpose, and it has to do with security constraints; as we’ll see later,
PyMailCGI is written such that it never associates your email username and password
together without encryption. This isn’t an issue if your web server is running locally,
of course, but this policy is in place in case you ever run this system remotely across
the Web.
By default, then, this page is set up to read the email account shown in this book—
address [email protected]—and requires that account’s POP password to
do so. Since you probably can’t guess the password (and wouldn’t find its email all that
interesting if you could!), PyMailCGI is not incredibly useful as shipped. To use it to
read your email instead, you’ll want to change its mailconfig.py mail configuration file
to reflect your mail account’s details. We’ll see this file later; for now, the examples
here will use the book’s POP email account; it works the same way, regardless of which
account it accesses.
Sending Mail by SMTP
PyMailCGI supports two main functions, as links on the root page: composing and
sending new mail to others, and viewing incoming mail. The View function leads to
Figure 16-2. PyMailCGI main page
Sending Mail by SMTP| 1241