4

When I set the TargetAddress in an on-premise environment, I'm able to enable cross domain free/busy lookups in a hybrid cloud environment. In addition, email is forwarded to the TargetAddress, and the envelope/P1 header is rewritten accordingly.

However, I am unable to locate this attribute in any of the Powershell commands for the respective environments (O365, EOP, Exchange, AzureAD).

Where can I find this attribute in the hosted environment, because some aspect of it is present, and affecting email.

Ran Dom
  • 191
  • 1
  • 3
  • 6
  • `(Get-ADUser UserID -Properties TargetAddress).TargetAddress` – EBGreen Jul 10 '18 at 17:45
  • @ebgreen that command is for an onpremise user right? I'm trying to locate the same via AzureAD, Exchange, or O365/MSOL commandlets. – Ran Dom Jul 10 '18 at 18:35
  • Does Get-AzureADUser get it for you? – EBGreen Jul 10 '18 at 18:44
  • @EBGreen It doesn't seem that a -Properties (or anything like it) exists in the AzureAD commandlet. I tried to dump an object with -Format-List and returned a smaller subset of attributes than what's available in Get-mailbox, other than some provisioning attributes. – Ran Dom Jul 10 '18 at 19:08

1 Answers1

1

The TargetAddress attribute does not get synced, it is on-premises only. The reason for this is that there is no reason to actually sync it.

It is used for the following: You have migrated a user from On-Prem to Office 365 or you have created a remote mailbox user on-premises that has a mailbox in Office 365.

The user is synced to Office 365 and the mailbox lives in Exchange Online. Now, since Exchange is self aware, it will need an object locally to tell it where the user is to be found.

The Target Address says, for this remote user, send mail to this address, the mail then goes through the normal connector mailflow in your hybrid setup and lands in Office 365 where the mail is delivered as normal since it has been sent redirected to the address the user has in Office 365.

Usually for Target Address you would use the mail.onmicrosoft.com domain alias for the user, your on-prem connector points this domain to Office 365.

As soon as the mail lands in Office 365 the mail alias (proxyaddress) will tell Exchange Online where the mailbox is. This is why Office 365 doesn't need to know the Target Address attribute, all is handled by normal mailflow, it is only for On-Prem to know what to do since the mailbox is not in the local Exchange Organisation.

  • 2
    Based on my experience and testing, I can do something that implies not only that the target address is not only synchronized, but is also acted upon uniquely by the transport agent / EOP. Simply set the target address to `smtp:user@anydomain.com` (not onmicrosoft.com) and send the user a message. The result is that the envelope is rewritten and the message is forwarded by "the cloud" to the external system. I'm aware this isn't standard usage, but its in use by several large enterprises to accommodate a migration from gmail, or other non MSFT systems without having to import contacts – Ran Dom Jul 25 '18 at 20:59