Office365 with Version 2023/IV

New mail interface for the Microsoft cloud

Egg, April 25, 2023: At the end of last year, Microsoft shut down the standards-compliant IMAP login for all Office365 services. This meant that the previous mail module was no longer able to archive mails from the Microsoft cloud. Version 2023/IV now provides an interface developed specifically for the Microsoft cloud. The new O365 module can be ordered and implemented as of now.

Preliminary remark: Market power versus standards

Where would the world be today without the Internet? First of all, this question is purely technical: whether the world needs Insta and the like is explicitly not the point here. The situation would probably be more or less the same as it was 30 years ago. Back then, there were a few service providers that made it possible to send a few data blocks from A to B for steep fees. Or as a heise article (in German) from 2021 sums it up nicely: “The operation was complicated, the price per hour high.

In a nutshell, it was the Internet that brought us the (almost) limitless communication that we take for granted today. For this to be possible, protocols (standards) are needed. Without these, it would be impossible to communicate with each other. In principle, anyone with some affinity for technology (and some hardware) can use them to connect.

The very fact that the Internet has no central control lever ensures that the network is and remains accessible to everyone without any hurdles. Such decentralization is in tension with the big tech players. If it were up to Facebook, it would only need Facbook or WhatsApp (the main thing is that it stays in the family); if it were up to Google, it wouldn’t need a second search engine, because with a quasi-monopoly, Google can of course market advertising at much higher conditions than if there were several search engines on the market with a certain distribution.

And if Microsoft had had its way, the cancer of Linux would have had to be urgently eliminated altogether. And since it has become clear that the Windows monopoly is no longer a monopoly, the company has been working hard to penetrate the market with cloud products. This sometimes includes “shooting down” common Internet protocols.

And that is why it has not been possible to access the Office365 services in the business area with the IMAP mail protocol for a few months now. Small side note: For accounts that run via hotmail.com, outloook.com, etc., for these accounts, access via IMAP is still possible without any problems. The argument of Microsoft, it would be about security, is therefore pretended, because if it would be about security, then this would have to be activated first with hotmail.com or outlook.com.

From a sober point of view, the more the big players succeed in “bedding down” customers in such a way that no standards are used, the longer they will be “stuck” with the cloud services. This is for the simple reason that the migration effort is kept so high that a change is only feasible with great effort, if at all.

Standard-compliant mail services still in demand

After it became apparent last November/December that Microsoft would “hijack” IMAP access, many discussions were held with customers. Those who already use Microsoft’s cloud services saw little problem in the shutdown of the IMAP protocol. The other part of the customers, those who do not use Microsoft mail services, stated that switching to Microsoft was not an issue. After all, there are many good local mail service providers. The administration of these services is also quite feasible for non-IT specialists.

For this reason it became clear that the existing mail archiving should remain 100% on the market. Mail archiving via the IMAP protocol offers a high degree of flexibility because it allows all common mail service providers to be integrated.

O365 module for Microsoft customers

However, for those customers who have their mail services hosted via the Microsoft cloud, further archiving of mails would only have been possible via tedious detours. In short, some customers asked for an Office365 mail module.

This module is now available in version 2023/IV. The implementation was done via Python3 or the O365 Python module. So that the mails can be fetched via Office365, the three parameters Tenant (a kind of customer number), ClientID and ClientSecret have to be created via MicrosoftAzure. The correct rights must also be set there so that the O365 module of the ArchivistaBox can access the corresponding mail accounts.

Furthermore, in WebAdmin there is the field ‘Number of mails (Office 365)’ for mail archiving. This allows the default value of 25 mails, which are delivered by default per call, to be increased so that the mails can also be archived within a reasonable period of time.

Licensing and setting up the O365 module

The ArchivistaBox O365 module is available as an alternative to the Mail module for all customers who wish to archive mails from Microsoft cloud services to the ArchivistaBox or also manage them via this. The price of the O365 module is higher than that of the Mail module. This is ultimately due to the high development effort. Customers who already use the Mail module can switch to the O365 module with a 50% discount (the previous Mail module will be deactivated). The current prices of the O365 module can be found in our web store.

For setting up O365 archiving, a competent partner is required who must be able to generate the correct rights and the appropriate keys (Tenant, ClientID, ClientSecret) for the mail accounts to be used. It should also be noted that the O365 module requires the availability of open interfaces on the part of Microsoft or the Python3 module O365.

In order to test whether the mails can be processed via the ArchivistaBox, the following script can be called with ‘python3 mailtest.py’:

#!/usr/bin/python3
from O365 import Account, Connection, MSGraphProtocol
from O365.mailbox import MailBox
from O365.message import Message
client_id = 'xxxx'
client_secret = 'yyyy'
tenant = 'zzzz'
credentials = (client_id,client_secret)
account = Account(credentials, auth_flow_type='credentials',
tenant_id=tenant)
if account.authenticate():
  print('Authenticated!')
  mailbox = account.mailbox('test@mymail.ch')
  print(mailbox)
  inbox = mailbox.inbox_folder()
  print(inbox)
  for message in inbox.get_messages():
    print(message)
    break

The correct information is to be entered at ‘test@mymail.ch’, ‘xxxx’, ‘yyyy’ and ‘zzzz’. If access is possible, the title (subject) of the first mail message will be printed.

Bonus: Access link from any document

Thanks to a small customer project it is possible in version 2023/IV to create a direct link to any file directly from any document. The access link is set up via WebAdmin or there at ‘Archive administration’:

Either the IP address of the ArchivistaBox (http:// or https:// in front) must be entered for DNS name for API call. If the ArchivistaBox has a public domain name (i.e. is accessible on the Internet), the corresponding domain must be entered under DNS name (example: https://archivistaimnetz.ch).

In the ‘Title field for API link’, enter the desired field which is to appear as the title for the document. If the title field is left empty, ‘File number: Title content’ will always be used. After the access link has been set up, the corresponding links can be created directly in WebDMS with ‘Ctrl+C’. Now ‘Ctrl+C’ is sometimes also used to copy a marked part of a section out of WebDMS. Therefore the creation of the access link only works if the tab ‘View’ is activated in WebDMS.

If this is the case, ‘Ctrl+C’ will copy the corresponding link to the clipboard and the link can be pasted into another file with ‘Ctrl+V’ or ‘Paste’. The following is an example of such a link:

viastockalperhd.mp4
https://192.168.0.233/perl/avclient/index.pl?target=new&go=8441

With copying the second line (after a login in WebDMS!!) in the navigation line, the corresponding document can be called directly for viewing. Especially for archives that are publicly accessible on the Internet, interesting documents can be presented conveniently (e.g. via a newsletter) in a compilation.