Apache James builds an intranet email server

Source: Internet
Author: User

Preface

About two weeks ago, the Seminar introduced the establishment of the. NET Intranet email server. Therefore, it is necessary to build an email server. Here we select the tool James.

 

Why intranet mail server?

A. Security is limited to personal opinions. Security and confidentiality are essential for any enterprise.

B. No restrictions on the Internet. Although WiFi is everywhere, a mail server that can be controlled and used by itself is definitely a good choice.

What is Apache James?

A. An enterprise mail server that supports multiple protocols

B. Open source and multi-platform

Open-source projects mean that there is no version problem, which reduces many legal issues and ensures the scalability of the platform; the implementation of pure Java will not be incompatible with windows, Linux, and other systems.

 

Latest

  1. Apache James 3.0 Beta
  2. Apche James 2.3.2 stable Edition

2.3.2.


Procedure
1. Environment Configuration

A. JDK


JDK 1.7. Currently, it is best to configure the relevant environment variables so that you do not need to configure the relevant java_home and jre_home in the file each time.


B. James


Decompress the downloaded ZIP file to your favorite directory.


1. Start

Find the run. BAT file under the binfile.

Displayed successfully,


 


2. Use telnet to remotely access port 4555 and add a user

. Telnet localhost 4555;

. Enter the logon user and password. The default value is root Root.

. Adduser CFL (add user name and password)

. Adduser cfltest

Added successfully,




2. xml configuration

In the config. xml file under the file james-2.3.1 \ apps \ James \ SAR-INF, pay attention to the time. This file appears only after it is started.

A. Configure the email server name


<Span style = "font-size: 18px; "> <Postmaster> [email protected] </Postmaster> for example, <Postmaster> [email protected] </Postmaster> <servernames autodetect =" true "autodetectip =" true "> <servername> localhost </servername> </servernames> </span>

 

B. comment out the mailet


<span style="font-size:18px;"><!--mailet match="RemoteAddrNotInNetwork=127.0.0.1" class="ToProcessor">       <processor> relay-denied </processor>       <notice>550 - Requested action not taken: relaying denied</notice>   </mailet--!> </span>


Maillet is similar to servlet, which will perform some simple processing on emails. We will not implement this interface here.


C. enable authentication authrequired


<span style="font-size:18px;"><authRequired>true</authRequired></span>


Configure the two clients [email protected] @ chenfanglin.com. I did a simple test in my Foxmail.



Configure account

 



Effect

1. Send email

 



2. receive emails





3. Some Problems

 

When you execute telnet, sometimes telnet is not an internal command. This is because the telnet server is not enabled. Enable this function in the window function.





Summary

In general, the configuration process is not very difficult. Of course, this is only the most basic e-mail setup, in order to understand such a good open-source tool. I think expansion and more implementations are the most promising.

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.