我正在使用标准登录用户策略设置新的 Azure AD B2C 目录。我计划让管理员创建用户帐户,因此不需要注册策略。我的问题是我想返回为用户帐户创建的电子邮件地址,但是当我测试用户流时,电子邮件地址是唯一缺少的声明。是否有原因和解决方法?
答案 0 :(得分:2)
B2C 内置用户流主要收集本地账户的 2 个位置的电子邮件地址。
一个是 otherMails
(Microsoft Grpah) / Alternate email
(Azure Portal)。
另一个是 signInType 为 emailAddress
(Microsoft Graph) 的身份。
因此,如果您的本地帐户使用“用户 ID”选项进行注册,则没有 signInType 为 emailAddress
的身份。如果 otherMails
(Microsoft Grpah) / Alternate email
也未设置,则令牌中不会有任何电子邮件声明。
请更新我提到的属性(otherMails
/ Alternate email
或使用电子邮件地址注册/添加一个 signInType 为 emailAddress
的身份,使用 Microsoft Graph)以使其包含在令牌。