This section provides information about the architecture design and functionality of ENS2.
ENS2 Architectural Flow
ENS2 architectural flow description:
- Public-Key Request - The device requests a public key to encrypt the account credentials.
- Subscribe - The device sends an encrypted payload with credentials and all the necessary information to subscribe and get email notifications.
- Push Subscription - ENS authenticates with EWS and subscribes for push notifications using a webhook URL. The webhook URL contains the encrypted credentials. The credentials are now kept encrypted on the Exchange server.
- New Email Notification -
- Exchange sends notification about the mailbox changes to the provided webhook URL.
- ENS extracts and decrypts the credentials and prepares a call to fetch emails.
- Email Fetch - ENS performs a fetch for the email details (subject and sender) required for providing a notification.
- Push Notification Payload - ENS pushes email details for delivery to all devices belonging to the user through SNS (ENS cloud deployments) or CNS (ENS on-premises deployments).
- SNS or CNS sends notifications to iOS or Android devices. For iOS devices, SNS or CNS uses Apple Push Notification Service (APNS), and for android devices, SNS or CNS uses Firebase Cloud Messaging (FCM).