SMTP App

The SMTP OCE app provides for converting email to USDS format and routing through an OCE (Fautore) in addition to routing through standard SMTP. This app opens a world of possibilities for using a standard email client to compose USDS messages for routing to any other available OSA compliant recipient. The email could, for example, be used to compose weBLog posts if routed to an OSA compliant weBLog site.

Registration

The fauSMTP app is registered to the OCE (Fautore) via commands.

cd {OCE home}/apps/fauSMTP ./fauSMTP.pl -r <membername> <password>

where

{OCE home}
the location to which the OCE (Fautore) is installed
<membername>
the login name of a POD member authorized to register applications
<password>
the current tribe password for the registering member. The password is exposed when entered as a parameter on the command line
Note:
You may receive a series of errors citing :
DBD::SQLite::db prepare failed: no such table:
the first time fauSMTP is run. This is normal and a self correcting error.

Management

The fauSMTP app is managed via command line.

{OCE home}/apps/fauSMTP/fauSMTP.pl [opts] <action>

Action Commands

stopStop the server
startStart the server
restartStop server (if it was running) and then start it

Options

Option Param Example Description
-r username -r Harold MyVisiblePassword Register this application with Fautore OSA/OCE
-smtpport integer -smtpport 42420 Set a new port number to use for SMTP (default is 20001)
-pop3port integer -pop3port 24240 Set a new port number to use for POP3 (default is 20002)
-jsonport integer -jsonport 5981 Set a new port number to use for OCE communications (default is 1895)
-usefromsmtp 0 or 1 -usefromsmtp 1 Switch outgoing SMTP mail to use the from address SMTP server (its realm) rather than using that of the to address. Value may be any of 0 1 on off
-dedicatedsmtp string -dedicatedsmtp myhost.com,26,mruser,somepass Switch outgoing SMTP mail to use a dedicated SMTP server as defined within the values. The values are a comma delimited string of hostname,port,username,password.
-settings N/A -settings Display control/configuration settings
-client N/A -client Display pop3 and smtp setting information to aid in configuring an email client. Example would be to aid setting up say 'Thunderbird' email client.
-pullinfo N/A -pullinfo Retrieve and Display OSA data synchronisation status.
-clearqueue N/A -clearqueue Clear the outgoing unsent mail queue (all mail will be lost)

Email Client Setup

Tips to setup an email client
-------------

Email Out-going SMTP Settings.

Description: Fautore SMTP Server
Server Name: 127.0.0.1
Port: 20001
Username: [your fautore username]@oce
Password: [your fautore password]
Authentication Method: Password, transmitted insecurely (yes allow this)
Connection Security: NONE (yes allow this)

Email In-coming POP Settings.

Server Type: POP Mail Server
Server Name: 127.0.0.1
Port: 20002
Username: [your fautore username]@oce
Password: [your fautore password]
Authentication Method: Password, transmitted insecurely (yes allow this)
Connection Security: NONE (yes allow this)

Sending A Message

Sending a message is very much like sending any other email. Simply type the message into your email client as you would at any other time. Attachments can be included as usual. The difference in sending an OCE message via Fautore (or any other OCE in the future) is in the addressing.

Typical Email Address

A typical email address breaks down as:

{recipient}@{domain}

where

{recipient}
The Internet name being used by the intended recipient
{domain}
The fully qualified domain name for the recipient intended to receive the email.

example

DemoMember@TekAdvocates.com

OCE Message Address

A message intended to be processed through an OCE takes a similar form to that of a regular email with the differance being in the meaning of the different components.

When the recipient is outside the local tribe the fully qualified location, including their tribe name" must be included in the address.

{recipient}@{RegisteredTribe}.oce

where

{recipient}
The local tribe name being used by the intended recipient
{RegisteredTribe}
The local name for a remote tribe registered to the local tribe.
oce
The literal 3 characters o-c-e to indicate to the SMTP application this message is to be handled by the OCE.

example

DemoMember@aFriendlyTribe.oce


The {RegisteredTribe} portion of the destination address is optional if the message recipient is known to be local to same tribe as the sender. In this case the address would look like this:

DemoMember@oce

Outstanding Work

Modules
Need to figure out a strategy for SMTP, and any other modules to be made available automatically during installation with minimal user intervention. Fautore automatically adding $FAUTOREHOME/apps to the @INC variable would allow applications to reference internal modules as {app}::{modulename} (fauSMTP::JDBsqlite). The problem with this approach however is that it creates a dependency on an OCE being writting in Perl and having awareness enough to set a Perl path.