Note: This is for DS 7.0 only, it uses the Email Server Type IMAP
Microsoft recommends now using the Email Server Type OAUTH IMAP. Please refer to the article called "How to configure the DocuShare Email Agent to connect to Office 365 IMAP OAuth"
Prerequisites:
· A unique dedicated email account created on either an external POP3 or an external IMAP mail server. (example dsmail@mailserver.com) and the username and password used for this account.
1. Download the Office 365 certificate bundle from Microsoft.
Note: If you are unable to get the Office 365 certificate, Customer Support can provide an Office 365 certificate bundle that contains two certificates that you can try using. However, it is preferred that you obtain the certificates from the Microsoft site to be sure you have the newest ones.
2. Modify the mailagent.properties file.
a. Stop DocuShare.
b. Make a copy <dshome>\config\mailagent.properties file and rename it mailagent.properties.orig.
c. Open the mailagent.properties in a text editor.
d. Search for the entry imapMailboxPort=
e. Change the value to imapMailboxPort=993
f. Save the file.
3. Modify the Monitor.xml (if needed)
a. Make a copy of the <dshome>\config\Monitor.xml and rename the copy Monitor.xml.orig.
b. Open the Monitor.xml in a text editor.
c. Search for the following mailagent.
d. Add -Djavax.net.ssl.trustStore=+DSH+\jdk\jre\lib\security\dstruststore into server part of mailagent at StartJVMParams section.
Example: added entry is shown in red.
<StartJVMParams>-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=+DSH+/logs -Dcom.xerox.docushare.install=+DSH+ -Dcom.xerox.docushare.jmslogprint=enabled -Ddocushare.mailagent.standalone=yes
-Djavax.net.ssl.trustStore=+DSH\jdk\jre\lib\security\dstruststore
-Xrs</StartJVMParams>
<StartAppParams></StartAppParams>
</JavaServerParam>
e. Save the file.
4. Install the Office 365 Certificates into the dstruststore.
a. Copy the .cer file or files to the DocuShare directory containing the DSTrustStore file <dshome>\jdk\jre\lib\security.
Where <dshome> is replaced with the installation directory for DocuShare. The default installation path is C:\Xerox\Docushare. Depending on your installation environment the path may vary.
The path to the security directory may vary depending on the version of DocuShare installed. For example, <dshome>\jdk1.5.0\jre\lib\security or <dshome>\jdk\jre\lib\security
b. Open a command prompt window on the DocuShare server.
c. Change into the <dshome>\jdk1.6.0\jre\lib\security directory.
d. At the command prompt, enter the keytool utility command ..\..\bin\keytool -import -alias <alias_name> -file <cert_file> -keystore dstruststore
Replace <alias_name> with a unique name for the certificate file.
Replace <cert_file> with the name of the certificate file (.cer) that you exported and
Example: ..\..\bin\keytool -import -alias ms1 -file office_cer1.cer -keystore dstruststore
e. Press Enter to start the command.
f. A request for a password appears.
g. Enter password and press Enter.
h. Examine the screen output to ensure that Keytool successfully added the certificate to the keystore.
i. Use the same command to add in any additional Office 365 certificates.
j. Verify that the certificate was successfully added to the dstruststore by running the following command. ..\..\keytool -list -v -keystore D:\Xerox\Docushare\jdk1.6.0\jre\lib\security\dstruststore
The Office 365 certificates you added should be listed in the dstruststore, if they were added successfully with the Keytool.
k. Once you have finished importing the certificate, reboot your DocuShare server.
5. Enable and Configure the Email Agent in DocuShare.
a. Log into DocuShare as admin.
b. Click the Admin Home link on the Navigation bar.
c. Click the [+] symbol next to Services and Components.
d. Click the [+] symbol next to Email Agent. The Email Account Configuration page displays.
e. In the Dedicated Email Address field type the Email Agent’s email address on the email server.
f. Note: The address should be dedicated to the Email Agent installed on this DocuShare server and not used for any other purpose. Example dsmail@domain.com
g. In the Mailbox Login Name field enter the username of the Email Agent’s account on the email server.
h. In the Mailbox Password field enter the password for the Email Agent’s account on the email server.
i. In the Password Confirm filed enter the same password entered in the previous field.
j. In the Email field type imap-mail.outlook.com
k. From the Email Server Type menu select IMAP.
l. In the Mail Folder field enter the name of the Email Agents mail folder. The default is INBOX. (This field is used when the email server is using IMAP)
m. Click the Apply button.
n. Click on the User Account link on the left-hand side of the page. The User Account Configuration page displays.
o. In the Handle of the Email Agent User field enter the handle of the user who is the designated Email Agent user. By default, this user’s personal collection will be used as the Default Collection for email messages.
Note: The Email Agent user is the default owner assigned to email messages that are sent from users who do not have DocuShare accounts and that cannot be sent to the specified locations. For example, when the sender does not have write access to a collection or workspace, it is strongly recommended that you dedicate this account for use with the Email Agent. Example: User-18.
p. In the Default Collection field enter the handle of a collection. The collection specified will be used to store email messages when they cannot be sent to the specified collection. This can occur when a user specifies an incorrect collection handle or when the user does not have sufficient access permissions to the collection.
Note: If you do not specify a collection, the Email Agent user’s personal collection is used. Example: Collection-12
q. Click the Apply button.
Note: If Required, you can also configure additional email agent properties in the Digital Certificate, Advanced and Email Server Integration pages.
Note: If there is a problem with either the addressed collection or the addressed group, the Email Agent places the problem message into the defined default collection (Step 15) on the DocuShare site. If configured to do so, the Email Agent also emails a confirmation to the sender.
Note: The default collection tends to accumulate a lot of unclaimed messages, so the administrator should either act as postmaster and periodically reroute or remove misdirected and old messages from the collection or make the default collection visible, so users can access the collection and claim their own messages. One way of making the default collection visible is to make it a root collection that appears on the site home page. The administrator should give All Users except Guests, Reader and Writer permission to the collection.
Note: When DocuShare receives the email, it compares the from field to its list of user email address to try to associate the email sender to a DocuShare user (case sensitive) If DocuShare finds a match, the owner of the newly added object becomes the user and their permissions are used. If DocuShare cannot find an email that matches, or the user does not have permission to the Collection that they are trying to place an object in, then the message will be placed in the default mail folder.
Solution Updated: February 5, 2019
Solution ID:1974