我们有一个使用 Azure B2C 和 Azure Active Directory 的应用程序。
问题:用户A想要设置他的特定电子邮件地址。但这是不可能的,因为用户 B 之前已经使用过该电子邮件地址。用户 B 拥有此电子邮件的代理地址条目,尽管用户 B 不再使用该电子邮件地址。
我们尝试删除用户 B 的 proxaddresses 中的 smtp 条目:
Connect-AzureAD -TenantId <TenantID>
$User = Get-AzureADUser -ObjectId "<ObjectIDUserB>"
$User.ProxyAddresses //Displays all proxyaddresses(smtpEntries)
$User.ProxyAddresses.Remove("<smtpEntry>")
Set-AzureADUser -ObjectId "<ObjectIDUserB>" //But then there is no parameter for ProxyAddresses to update
我们是否在这里遗漏了某些内容,或者是否有其他方法可以删除天蓝色广告中用户的代理地址条目?
MSOnline powershell 模块运行以下命令:
Connect-MsolService
Restore-MsolUser -UserPrincipalName [email protected] -AutoReconcileProxyConflicts
[电子邮件受保护] 现已从 [电子邮件受保护] 帐户中删除。从 Azure AD 门户,您现在可以删除 [电子邮件受保护]。
编辑2024年4月19日: 这个过程需要的时间更长。您现在可以使用 Graph Explorer (
https://aka.ms/ge) 并执行 PATCH 来更新仅限云的非 EXO 许可用户的 proxyAddresses 属性
补丁https://graph.microsoft.com/beta/users/
{ “代理地址”:[ “SMTP:[电子邮件受保护]” ] }
您可以使用管理员帐户登录
O365管理中心。
找到用户B并单击它。用户详细信息打开后,单击管理用户名和电子邮件。
然后您可以点击“···” ->删除别名来删除smtp proxaddress。
添加:
Set-Mailbox [email protected] -EmailAddresses @{add="[email protected]"}
然后删除:
Set-Mailbox [email protected] -Emailaddresses @{remove="[email protected]"}