Resources
HOWTO Documents > IMAP at CCIS > Configuring Pine to use IMAP at CCIS
Requirements
This document describes how to configure the Unix/Linux version of Pine to communicate with our IMAP server, so you can read your mail at CCIS (including saved mail folders) remotely.
This document is mainly intended for people running Pine on Unix or Linux computers at other sites, and trying to access their CCIS mail from there, but you can also use IMAP with Pine at CCIS. (There's also a version of Pine that works under Windows, called PC-Pine. PC-Pine behaves and is configured almost identically to Unix Pine, so you can probably use it along with the instructions below. These instructions have only been tested with the Unix version of Pine. However, PC Pine is available at http://www.cac.washington.edu/pine/getpine/pcpine.html.
At CCIS, we only support encrypted access to the IMAP server, so that your password will not be transmitted in plain text over the Internet. That means you need a version of Pine built with SSL encryption support. You can find out whether your version of Pine supports SSL encryption by typing ‘pine -supported’. You should see SSL listed under ‘Encryption’. If the output includes the message ‘(no TLS or SSL)’ or ‘(no SSL)’, then that version of Pine will not work with our IMAP server. (Support for SSL can be compiled into Pine when it is built and installed.)
Pine folder and mailbox concepts
Pine and IMAP two kinds of places your mail can be stored. One is your incoming mailbox (or inbox), which is where the operating system delivers your new mail by default. At CCIS, that's in a disk space shared by all CCIS users, so you should not leave mail there longer than necessary; you should delete it or refile it into folders as soon as possible.
The other place is mail folders, which are stored somewhere under your home directory. You can use Pine with IMAP just to check your incoming mail, but if you also want to be able to access mail in folders, you'll need to tell Pine where you keep your folders.
Pine divides your folders into ‘collection lists’, which allows you to access folders in multiple places - including multiple accounts - or access different subsets of your folders. In order to access your mail on an IMAP server, you define a new collection list which specifies that server and where your mail folders are on it. (Depending on the particular server software, that last step may not be necessary, but at CCIS we use an IMAP server that can access mail in different formats and in different locations, so you need to tell Pine where in your CCIS home directory you keep your mail folders.) When you later view that collection list, Pine will prompt you for your login name and password on the server, and then show you the folders in it.
Configuring Pine to show your CCIS mail
Setting your CCIS inbox as your default Pine inbox
If you intend only or mainly to use Pine to access your CCIS email, you'll probably want to make your CCIS incoming mailbox your default Pine inbox. You can do this with the following sequence of actions:
| 1. | Start Pine with the command ‘pine’ |
| 2. | On the main menu, press [S] for SETUP. |
| 3. | From the SETUP screen, press [C] to go to the configuration screen. |
| 4. | Scroll down to inbox-path, and press [C] to change it. |
| 5. | Type ‘{imap.ccs.neu.edu/ssl/user=yourlogin}INBOX’, including the curly braces around the hostname but substituting your CCIS login name for yourlogin. You can leave off the ‘/user=yourlogin’ part, you'll be prompted for your login name as well as your password whenever you start Pine. You can also leave off the ‘/ssl’ part, but then Pine may try (and fail) to connect to CCIS using less secure methods first, causing it to take longer to open your mailbox. When you're done, press [Return]. |
| 6. | Press [E] to Exit Setup. |
| 7. | Press [Y] to confirm saving the changes to your Pine settings. |
| Then quit Pine (with ‘Q’, confirming with ‘Y’) and start it again to see the result of the configuration change. This time, you'll be prompted for your CCIS password at the bottom of the screen (and perhaps first for your login name, if you didn't specify it in the inbox-path value). |
If you don't want your CCIS inbox to be Pine's default inbox, but only want to be able to check it from time to time, see below.
Configuring Pine to access your stored mail folders at CCIS
In order to access mail you've filed into folders, you'll need to know where under your home directory your mail folders are stored. This is referred to as the ‘path’ to your mail folders. (If you don't have any stored mail folders yet, and you're just going to be creating new ones, you can pick an arbitrary directory name to put them in, but probably you already have folders created with your existing mail reader, not using IMAP, and you'll want to access them.) If you've already been using Pine (not over IMAP) from your CCIS account, your mail folders are probably in a subdirectory called ‘mail’ in your home directory. If you use Elm or mutt, they're probably in a subdirectory called ‘Mail’ (with a capital M). If you use Netscape, they're probably in ‘nsmail’.
Once you've figured out where your existing folders are, you can create a Collection List in Pine that lets you access them using the following procedure.
| 1. | Start Pine with the command ‘pine’. | ||||||||
| 2. | On the main menu, press [S] for SETUP. | ||||||||
| 3. | From the SETUP screen, press [L] to get to the SETUP COLLECTION LIST screen. | ||||||||
| 4. | Type ‘A’ to add a new collection. You'll be prompted for: | ||||||||
|
|||||||||
| 5. | When you've set Nickname, Server, and Path properly (and perhaps View, but you'll probably leave that blank), press Control-X (hold down the Control key and press X, indicated by ^X in the menu at the bottom of the screen) to save your changes. | ||||||||
| 6. | At that point, you're still in the SETUP COLLECTION LIST screen. From there, press [E] to Exit Setup and get back to the main menu. | ||||||||
| 7. | Then press [L] to see and access your collection lists, including the new one. You can scroll down to the one you've just created and press [Return] or [>] to access the folders in it. |
By way of example, the screen might look like the following while setting up a new folder collection:
| PINE 4.44 FOLDER COLLECTION EDIT <CCIS IMAP> mboxes/testing 2 Msgs + | ||
| Nickname | : | CCIS email |
| Server | : | imap.ccs.neu.edu/ssl/user=yourusername |
| Path | : | mail/ |
| View | : | |
Fill in the fields above to create a new Folder Collection. |
||
| Use ^G command to get help specific help for each item, and | ||
| use ^X when finished. | ||
Occasional access to your CCIS inbox via Pine
If you usually will be using Pine at another site to read non-CCIS mail, but you want to be able to check your CCIS inbox with it once in a while, the easiest way to do so might be by giving Pine a command-line flag telling it to open your CCIS inbox. The syntax is as follows:
pine -f '{imap.ccs.neu.edu/ssl/user=yourlogin}INBOX'
replacing yourlogin with your CCIS login name. You need the single quotation
marks (') because Pine's syntax for remote folders uses curly braces and the equal sign, which are special to the shell.
That command will bring you to Pine's main menu (prompting you for your CCIS password first). Make sure you don't just press [Return] or [L] to go to the COLLECTION LIST screen and switch folders. Instead, just press [I] to see the index of messages in the current folder - your CCIS inbox, which you have specified on the command line.
Alternatively, if you are already in Pine, you can press the G key (from many screens) to go to a particular folder. Pine prompts you for the short name of a folder in the current collection list, but you can specify the full name of a remote folder in the above syntax. So to view your CCIS incoming mailbox, you would press G, and then type {imap.ccs.neu.edu/ssl}INBOX at the GOTO prompt, and when you pressed [Return] you'd be prompted for your CCIS login name and password. Then Pine would show you the mail in your CCIS mailbox.
Advanced features
MH-format mail folders
If you normally read your mail using MH, your mail folders will
be in a different format. To access an MH mail folder via Pine, you can press G and type
{imap.ccs.neu.edu/ssl/user=mylogin}#mh/folder
where mylogin is your CCIS login name and folder is the MH folder you want to access. You don't need to provide
the path in your home directory to your MH folders; the IMAP server finds that automatically.
This does not work for your MH
‘inbox’ folder (where you ‘inc’ ‘to’, as distinct from the system incoming mailbox where you
‘inc’ ‘from’), because IMAP and Pine reserve the word ‘INBOX’ (even lowercase) for your system mailbox. To access your MH
‘inbox’ folder, you would type
{imap.ccs.neu.edu/ssl/user=mylogin}#mhinbox
You can define collection lists that refer to your MH folders,
but due to minor peculiarities in Pine's option-setting interface,
you need to do this by editing your
‘~/.pinerc’ file by hand. For instance, my (with username jay) ‘.pinerc’ includes the following:
folder-collections="CCIS MH folders" {imap.ccs.neu.edu/ssl/user=jay}#mh/[],
"CCIS mbox folders" {imap.ccs.neu.edu/ssl/user=jay}mboxes/[]
The example above has also made a symbolic link from its MH ‘inbox’ folder to ‘mhinbox’, so you can access that more conveniently from your MH collection list, since you can't use the name ‘inbox’ for anything but your system mailbox, where your new mail is delivered.
See also...
| • | General information about using IMAP at CCIS. |
| • | The University of Washington's Pine Information Center (UW wrote Pine). |
| • | SSH Tunneling: How to securely send and retrieve your CCIS mail via SSH (only relevant for the sending part, since you will need to configure that separately). |
| • | Configuring Eudora to access your CCIS email via IMAP. |
| • | Configuring Microsoft Outlook (not Outlook Express) to access your CCIS email via IMAP. |
| • | Configuring Microsoft Outlook Express to access your CCIS email via IMAP. |
| • | Configuring Pine to access your CCIS email via IMAP. |
If you have questions about IMAP access to CCIS mailboxes that these documents don't answer, or comments or questions about the documentation itself, please send them to systems@ccs.neu.edu with as much information as possible about your problem. We will do what we can to help you resolve the problem, but please note: CCIS Systems does not have the resources to support non-CCIS machines, so we may have to refer you to other forms of support.