Saturday, April 7, 2012

Make Your Own Email Server Using JAMES

Have you ever wanted to make your own email server? In this post I'll show you how you can easily isntall and configure your very special home-made email server.

First things first, before we start, you will need to install the following:
  1. JAMES server stable 2.x release from http://james.apache.org.
  2. Windows telnet client.
  3. JDK 1.5 (in case you don’t have it installed already)+.
  4. [Optional] Outlook Express or Thunderbird.
Now you have everything you need, let the installation begin.

Installation

JDK

  • if you haven't installed java already, make sure it's installed and well configured, you can test that easily by executing the following command in your command prompt (CMD):
 java -version

JAMES

  • Extract the zip file to a directory (in this document it’s assumed to be D:\).
  • Start JAMES from the cmd on D:\JAMES\bin\run.bat, you will see something like the following.
Using PHOENIX_HOME:   D:\James\
Using PHOENIX_TMPDIR: D:\James\temp
Using JAVA_HOME:     
Phoenix 4.0.1
James 2.1.3
Remote Manager Service started plain:4555
POP3 Service started plain:110
SMTP Service started plain:25
NNTP Service started plain:119
Fetch POP Disabled
 Now that we're done with the installation, let's move to the interesting part, configuration.

Configuration

JAMES

  • Open cmd window and telnet to the mail admin server, if you can’t find the telnet command then you are probably using windows7, please refer to Appendix A for how to enable telnet on windows 7
  • Create a user; this is the user that will be used to receive emails:
# telnet localhost 4555
JAMES Remote Administration Tool 2.2.0
Please enter your login and password
Login id:
root
Password:
root
Welcome root. HELP for a list of commands
adduser testuser password
User testuser added
quit
Bye

Outlook

  • Add the test email you’ve just created to the outlook using the following data
E-mail Address: testuser@localhost
Incoming mail server: 127.0.0.1
Outgoing mail server (SMTP): 127.0.0.1
Username: testuser
Password: password. 
  • Test the account settings, if it’s ok, press next and then finish.
That's All folks, please feel free to ask.