I am writing Exchange ActiveSync client in C++. I use FolderSync command for synchronize list of folders and Sync command for synchronize emails from server.
In IMAP protocol I use command STATUS INBOX (UNSEEN) for getting unseen emails in inbox folder.
Is in Exchange ActiveSync some equivalent command ?
According to the Microsoft documentation only the following is part from ActiveSync:
Support for HTML messages
Support for follow-up flags
Conversation grouping of email messages
Ability to synchronize or not synchronize an entire conversation
Synchronization of Short Message Service (SMS) messages with a user's Exchange mailbox
Support for viewing message reply status
Support for fast message retrieval
Meeting attendee information
Enhanced Exchange Search
PIN reset
Enhanced device security through password policies
Autodiscover for over-the-air provisioning
Support for setting automatic replies when users are away, on vacation, or out of the office
Support for task synchronization
Direct Push
Support for availability information for contacts
But you might wish to implement something via EWS (see here some example).
Related
My basic requirement is that I need to create "something" that is capable of intercepting emails incoming/outgoing from our mail server. It cannot be an extension to mail clients. Currently we consider only exchange server. In my research I found below resources that seems to be helpful.
Mail flow and the transport
Delivery agents and Delivery Agent connectors
Transport agents
From these transport agents seems to be quite old. Now I can't figure out what's the best from the remaining options(Mail flow and the transport or Delivery agents and Delivery Agent connectors).
Whatever I develop should be able to read email get some statistics (using mail header(s), amount of attachments etc...) and store it into a custom database. Additionally add some custom headers to incoming/outgoing mails.
Can anyone point me to right direction? Should it be some kind of a service that I can install in Exchange server? (admin center->mail flow-> connectors). For example, can I write it in c# and host it like an assembly? or may be a web hook to a hosted service where Exchange will forward emails in real time etc...
I couldn't find any examples/tutorials except this
If its OnPrem Exchange and you don't have or are considering Office365 then Transport Agents would be the right thing to use. They haven't change since 2013 but are still what is used for this type of thing the last SDK was 2010 but its still valid given the lack of change on the backend https://learn.microsoft.com/en-us/previous-versions/office/developer/exchange-server-2010/dd877026(v=exchg.140)
Delivery Agents are more for when you have an external gateway that you want to send and receive messages from.
Exchange 2010.
I've read about notification subscriptions, mailbox events, and EWS in Exchange and as i got it, the notiified client app have to stay connected to EWS all the time. Am i right?
My task looks easy - i need to trigger some action (web call most likely) when message arrives to mailbox. Is there anything for such task in EWS 2010? Is there anything like this in latest versions of Exchange Server on-prem?
For now I'm starting to think about forwarding email via trasnport rules to some unix-mta for further processing.
Yes that's correct EWS notifications require that the client application that receives the notifications stay connected if your using Stream notifications. Pull notification don't and push notifications don't but the client does need to be available to receive the heartbeat messages and then update the subscription.
There is nothing new in the later OnPrem version of Exchange there are web-hooks in Exchange Online in the Graph API
For some security reasons that I can't have a public accessible server to receive data from slack.
So, this is what I'm planning to do:
Inbound message from slack: using RTM API
Outbound message to slack: using RTM API or Web API
Questions:
Any better alternatives?
Any restrictions? (AFAIK, buttons and drop downs can't work)
If Web API reach rate limit, can I use incoming webhook as a backup plan?
RTM only approach
Yes, that would work. With only the RTM API you are limited to:
receiving and responding to messages
Other RTM events.
You can't use any interactive functionality like:
Interactive components (buttons, menus, datepickers)
Dialogs
Rate limit on message posting
Using the webhook as "backup" to circumvent the rate limit is not an option, since the rate limit of posting max 1 message per second applies to all form of message posting.
From the documentation:
In general, apps may post no more than one message per second per
channel, whether a message is posted via chat.postMessage, an incoming
webhook, or one of the many other ways to send messages in to Slack.
Alternatives
You did not give any details about the reasons why your app can't expose an endpoint to the public Internet. But you might want to consider using a VPN tunnel like ngrok.
Yes! Socket Mode
There is a new alternative from slack, Socket Mode, which doesn't require a publicly accessible server.
Note: this is only for private apps.
With Socket Mode you have an API token and your server uses it to communicate with Slack's servers and create a two way socket connection. This means your Slack Bot's code can run on a machine behind a firewall and not require any inbound ports to be opened.
Slack message delivery requires an acknowledgement once you get the message, or else they may retry to deliver it.
Limitations
Socket Mode has two main limitations:
Apps using Socket Mode are not currently allowed in the public Slack App Directory.
Socket Mode is only available for apps using new, granular permissions. If you created your app on or after December of 2019, good news: your app already uses the new permissions. Otherwise, you may have to migrate your classic Slack app to use granular permissions before turning on Socket Mode.
I am developing MS Exchange client using active sync protocol and i have implemented all the commands, able to fetch, read mails, can also mark as unread or can delete it. But now i want to manage the emails thread wise, so i am wondering if there is any way to manage email thread. I tried to find the thread index property but there isn't such a property like gmail or other imap protocol have. So i am wondering how can i implement it.
I have referred document from https://msdn.microsoft.com/en-us/library/dd299441(v=exchg.80).aspx but didn't get exact solution from there.
If you are using protocol version 14.0 or higher (meaning that the server is Exchange 2010 or higher), each message should have a ConversationId element and a ConversationIndex that you can use to group messages. There's more information in the ActiveSync Conversations Protocol document, [MS-ASCON].
I'm in a process of creating security software that will address a specific type of security problem. In order to do that I would need to gather information about all the mails that are sent using Microsoft exchange. The information needed is mail's sender, receivers and timestamp. Actually I don’t even need to hold the information on real-time just counters for each sender-receiver pair for specific time frame.
How can I do that?
Is there some Exchange's service that I can use to get this information?
Must such a component be installed on each exchange server (hub, mailbox server etc')?
Are there Exchange's logs or internal database that hold such information?