Sending mail from offsite

What is meant by offsite?

Each "mail account" in your mail client program is configured with an incoming and an outgoing server.  When you send a mail message, your machine sends the message to the outgoing server which then relays the message to its recipient. The division mail server relays mail only from machines located on the division network or from machines connected to the laboratory's FOCAL service.  These machines are considered to be onsite.  All others are offsite.  While you can read your mail on the division server from anywhere, you can only send mail via the server if your machine is "onsite" as defined above.

This is not considered a limitation but a feature.  If the server is configured to relay mail from anywhere, it is an open-relay mailer and is not allowed by the laboratory.  The main reason is that open-relay mailers are used by spammers to send spam mail.  Also, many institutions no longer accept mail originating from open-relay mailers.

Solutions

The simple solution

An obvious solution is to use the appropriate outgoing server when you are "offsite".  Suppose your ISP is Corecomm .  When you connect to Corecomm, your machine is part of the Corecomm network.  It is therefore considered "offsite".  Your Corecomm account includes a mail account.  Typically, the incoming and outgoing servers are both mail.corecomm.net.  You can configure another "offsite account" in your mail client where the incoming server is the division mail server, mailstop, and the outgoing server is mail.corecomm.net.

In the following example, the mail client is Netscape Messenger.  Select Preferences under the Edit menu.  Click on Mail Servers under Mail & Newsgroups and enter the information as shown below.


 

With this account, you will be reading mail from the division's mail server, but sending mail via your ISP's outgoing server.

Typically, your Corecomm email address is name@corecomm.net.  You may wish to set your email address to name@phy.anl.gov as shown below so that when you send mail via this account, the mail will go out with your Physics mail address instead of your ISP's.

NOTE: There is no guarantee that the mail message will go out with a From: address of name@phy.anl.gov.  This depends entirely on the ISP mailer.  It may be configured to rewrite the address to name@your_isp.net.  In such cases, you may choose to enter name@phy.anl.gov in the Reply-To field shown above.

This basic idea also applies if you are connected to a network at some other institution.  In this case, you will need to find out from the institution's administrators what the appropriate outgoing server's name is.
 

The port forwarding solution

This solution uses a technique called port forwarding.  Specifically, you need to port forward with ssh.  If you are comfortable with using Unix Pine, it is recommended that you simply ssh to your account from offsite and read your mail there.  If you prefer to stay with a Windows mail client, you will need to carry out the following instructions to set up this solution.

You will need 2 things:

Launch SecureCRT and create a new session by selecting Connect from the File menu as shown below,

and click on New Session.


 

Fill in the fields as shown below.  In this example, the new session is called MailForward.  Instead of `teh', put in your account name on the maria cluster.


 

Next, click on the Advanced button next to the Hostname: field and select the Port Forwarding tab.

Click on New and fill out the fields as shown above.  Then, click Save to add it to the Current listing.  Finally,  click OK to bring up you back to the following screen.

You should see the session you have just defined.

Next, you need to create another "mail account" in your mail client program.  The example below uses Microsoft Outlook as the mail client, but the idea is the same with other mail clients.  For more details on creating a "mail account" in your mail client, click  here .

When you get to the dialog box as shown above, type in localhost for the outgoing mail server.  With the port forwarding technique, the outgoing server is always localhost.  When you are finished creating the account, you should see the following dialog box with 2 accounts defined.

You  may wish to rename your "offsite" account.  Click on Properties to rename the account as shown below.

As with your onsite account, you need a secure connection to the incoming server.  If you have not already done so, click on the Advanced tab and check the secure connection option for the incoming server.  When you're done, you should have 2 accounts - and offsite and an onsite as shown below.

Your setup is now complete.
 

Sending mail with the port forwarding technique

In order to send mail with this technique, you need to establish an ssh connection to the maria cluster with the MailForward session.  Select Connect from the File menu.  When the following dialog box appears, select MailForward and click on the Connect button.

A dialog box will appear as shown below prompting you for your password.  This is the password to your account on the maria cluster.  Type it in.

After the ssh connection is established, you must send your mail via your "offsite account".  Instead of clicking on Send, select Send Using from the File menu and select your offsite account as shown below.


 
 

A brief technical explanation

When you establish your ssh connection with the MailForward session, you have (1) created a secure ssh connection to maria, and (2) enabled transmission of port 25 (SMTP) traffic via this ssh channel.  Your offsite account's outgoing server is localhost.  This means when you send a message, your machine will send the message to itself.  In effect, a loopback. Since SecureCRT is running the MailForward session, all port 25 traffic arriving at your machine is transmitted via the ssh channel to maria which in turn forwards it to port 25 on the division mail server.
 

Corecomm

Argonne has an arrangement with the Internet Service Provider,  Corecomm, to offer special pricing to its employees.  Click  here  for more information on obtaining an account with Corecomm.