Azure动态组成员规则:如何排除指定组的用户
Azure AD动态组排除指定组成员的正确规则写法
正确语法1(推荐)
-not (user.memberof -any (group.objectId -in ['my-group-id']))
正确语法2(等价写法)
user.memberof -not-any (group.objectId -in ['my-group-id'])
你之前写法的问题
- 第一种错误写法少了最后一个闭合的右括号,导致语法解析失败,触发“invalid property”提示;
- 第二种写法
(group.objectId -not ['my-group-id'])不符合规则语法,-not不能直接和属性值搭配使用,必须结合-any/-all这类逻辑运算符来实现否定判断。
内容的提问来源于stack exchange,提问作者Shaquille Oatmeal
相关产品推荐
相关产品推荐

