Skip to content

Commit 05fab84

Browse files
Merge pull request #13084 from d-chetan/main
Introducing Granular Federation Controls and updating behavior of AllowFederatedUsers
2 parents 2996761 + f507098 commit 05fab84

File tree

3 files changed

+76
-30
lines changed

3 files changed

+76
-30
lines changed

teams/teams-ps/MicrosoftTeams/New-CsEdgeDomainPattern.md

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,10 @@ Whether or not users can communicate with people who have accounts on public IM
3737
Federation is managed, in part, by using allowed domain and blocked domain lists.
3838
The allowed domain list specifies the domains that users are allowed to communicate with; the blocked domain list specifies the domains that users are not allowed to communicate with.
3939
By default, users can communicate with any domain that does not appear on the blocked list.
40-
However, administrators can modify this default setting and limit communication to domains that are on the allowed domains list.
40+
However, administrators can modify this default setting and limit communication to domains that are on the allowed domains list.
41+
42+
> [!IMPORTANT]
43+
> The `AllowFederatedUsers` property must be set to `True` for the `AllowedDomains` list to take effect. If `AllowFederatedUsers` is set to `False`, users will be blocked from communicating with all external domains regardless of the values in `AllowedDomains` or any `ExternalAccessPolicy` instance.
4144
4245
Skype for Business Online does not allow you to directly modify the allowed list or the blocked list; for example, you cannot use a command similar to this one, which passes a string value representing a domain name to the blocked domains list:
4346

@@ -59,8 +62,30 @@ Set-CsTenantFederationConfiguration -BlockedDomains $x
5962
```
6063

6164
Example 1 demonstrates how you can assign a single domain to the blocked domains list for a specified tenant.
62-
To do this, the first command in the example creates a domain object for the domain fabrikam.com; this is done by calling the New-CsEdgeDomainPattern cmdlet and by saving the resulting domain object in a variable named $x.
63-
The second command then uses the Set-CsTenantFederationConfiguration cmdlet and the BlockedDomains parameter to configure fabrikam.com as the only domain blocked by the current tenant.
65+
To do this, the first command in the example creates a domain object for the domain fabrikam.com; this is done by calling the `New-CsEdgeDomainPattern` cmdlet and by saving the resulting domain object in a variable named $x.
66+
The second command then uses the `Set-CsTenantFederationConfiguration` cmdlet and the `BlockedDomains` parameter to configure fabrikam.com as the only domain blocked by the current tenant. Please note that `AllowFederatedUsers` should be `True` for this to work.
67+
68+
### Example 2
69+
```
70+
$x = New-CsEdgeDomainPattern -Domain "fabrikam.com"
71+
72+
Set-CsTenantFederationConfiguration -AllowedDomains $x
73+
```
74+
75+
Example 2 demonstrates how you can assign a single domain to the allowed domains list for a specified tenant.
76+
To do this, the first command in the example creates a domain object for the domain fabrikam.com; this is done by calling the `New-CsEdgeDomainPattern` cmdlet and by saving the resulting domain object in a variable named $x.
77+
The second command then uses the `Set-CsTenantFederationConfiguration` cmdlet and the `AllowedDomains` parameter to configure fabrikam.com as the only domain allowed by the current tenant. Please note that `AllowFederatedUsers` should be `True` for this to work.
78+
79+
### Example 3
80+
```
81+
$x = New-CsEdgeDomainPattern -Domain ""
82+
83+
Set-CsTenantFederationConfiguration -AllowedDomains $x
84+
```
85+
86+
Example 3 demonstrates how you can block a specified tenant from any external federation.
87+
To do this, the first command in the example creates an empty domain object; this is done by calling the `New-CsEdgeDomainPattern` cmdlet and by saving the resulting domain object in a variable named $x.
88+
The second command then uses the `Set-CsTenantFederationConfiguration` cmdlet and the `AllowedDomains` parameter to configure the current tenant with a Block-All setting. Please note that `AllowFederatedUsers` should be `True` in case you want to allow specific users to be able to communicate externally via `ExternalAccessPolicy` instances.
6489

6590
## PARAMETERS
6691

teams/teams-ps/MicrosoftTeams/Set-CsExternalAccessPolicy.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,10 @@ This enables your users to use Skype for Business and log on to Skype for Busine
9191

9292
After an external access policy has been created, you can use the `Set-CsExternalAccessPolicy` cmdlet to change the property values of that policy.
9393
For example, by default the global policy does not allow users to communicate with people who have accounts with a federated organization.
94-
If you would like to grant this capability to all of your users you can call the `Set-CsExternalAccessPolicy` cmdlet and set the value of the global policy's EnableFederationAccess property to True.
94+
If you would like to grant this capability to all of your users you can call the `Set-CsExternalAccessPolicy` cmdlet and set the value of the global policy's EnableFederationAccess property to True.
95+
96+
> [!NOTE]
97+
> For the domain settings defined under `AllowFederatedUsers` to be applied, the value of the property `AllowedFederatedUsers` under `TenantFederationConfiguration` should be set to `True` for the Tenant.
9598
9699
## EXAMPLES
97100

@@ -118,7 +121,7 @@ Get-CsExternalAccessPolicy -Filter tag:* | Set-CsExternalAccessPolicy -EnableFed
118121
```
119122

120123
Example 3 enables federation access for all the external access policies that have been configured at the per-user scope.
121-
To carry out this task, the first thing the command does is use the `Get-CsExternalAcessPolicy` cmdlet and the Filter parameter to return a collection of all the policies that have been configured at the per-user scope.
124+
To carry out this task, the first thing the command does is use the `Get-CsExternalAccessPolicy` cmdlet and the Filter parameter to return a collection of all the policies that have been configured at the per-user scope.
122125
(The filter value "tag:*" limits returned data to policies that have an Identity that begins with the string value "tag:".
123126
Any policy with an Identity that begins with "tag:" has been configured at the per-user scope.) The filtered collection is then piped to the `Set-CsExternalAccessPolicy` cmdlet, which modifies the EnableFederationAccess property for each policy in the collection.
124127

@@ -152,7 +155,7 @@ In this example, we create an ExternalAccessPolicy named "GranularFederationExam
152155
> Applicable: Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
153156
154157
> [!NOTE]
155-
> Please note that this parameter is in Private Preview.
158+
> Please note that this parameter is in Public Preview.
156159
157160
Specifies the external domains allowed to communicate with users assigned to this policy. This setting is applicable only when `CommunicationWithExternalOrgs` is configured to `AllowSpecificExternalDomains`. This setting can be modified only in custom policy. In Global (default) policy `CommunicationWithExternalOrgs` can only be set to `OrganizationDefault` and cannot be changed.
158161
```yaml
@@ -172,7 +175,7 @@ Accept wildcard characters: False
172175
> Applicable: Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
173176
174177
> [!NOTE]
175-
> Please note that this parameter is in Private Preview.
178+
> Please note that this parameter is in Public Preview.
176179
177180
Specifies the external domains blocked from communicating with users assigned to this policy. This setting is applicable only when `CommunicationWithExternalOrgs` is configured to `BlockSpecificExternalDomains`. This setting can be modified only in custom policy. In Global (default) policy `CommunicationWithExternalOrgs` can only be set to `OrganizationDefault` and cannot be changed.
178181
```yaml
@@ -192,7 +195,7 @@ Accept wildcard characters: False
192195
> Applicable: Lync Server 2010, Lync Server 2013, Skype for Business Server 2015, Skype for Business Server 2019
193196

194197
> [!NOTE]
195-
> Please note that this parameter is in Private Preview.
198+
> Please note that this parameter is in Public Preview.
196199

197200
Indicates how the users get assigned by this policy can communicate with the external orgs. There are 5 options:
198201

teams/teams-ps/MicrosoftTeams/Set-CsTenantFederationConfiguration.md

Lines changed: 40 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -108,46 +108,55 @@ When this command completes, the blocked domain list will be cleared.
108108

109109
### Example 6
110110
```
111+
Set-CsTenantFederationConfiguration -AllowedDomains $Null
112+
```
113+
114+
Example 6 shows how you can remove all the domains assigned to the allowed domains list for the current tenant, thereby blocking external communication for all users in the Tenant. In case `AllowFederatedUsers` is set to `True`, then explicit `ExternalAccessPolicy` instances can be leveraged to set a per-user federation setting.
115+
To do this, simply include the AllowedDomains parameter and set the parameter value to null ($Null).
116+
When this command completes, the allowed domain list will be cleared.
117+
118+
### Example 7
119+
```
111120
$list = New-Object Collections.Generic.List[String]
112121
$list.add("contoso.com")
113122
$list.add("fabrikam.com")
114123
Set-CsTenantFederationConfiguration -AllowedDomainsAsAList $list
115124
```
116125

117-
Example 6 shows how you can replace domains in the Allowed Domains using a List collection object.
126+
Example 7 shows how you can replace domains in the Allowed Domains using a List collection object.
118127
First, a List collection is created and domains are added to it, then, simply include the AllowedDomainsAsAList parameter and set the parameter value to the List object.
119128
When this command completes, the allowed domains list will be replaced with those domains.
120129

121-
### Example 7
130+
### Example 8
122131
```
123132
$list = New-Object Collections.Generic.List[String]
124133
$list.add("contoso.com")
125134
$list.add("fabrikam.com")
126135
Set-CsTenantFederationConfiguration -AllowedDomainsAsAList @{Add=$list}
127136
```
128137

129-
Example 7 shows how you can add domains to the existing Allowed Domains using a List object.
138+
Example 8 shows how you can add domains to the existing Allowed Domains using a List object.
130139
First, a List is created and domains are added to it, then use the Add method in the AllowedDomainsAsAList parameter to add the domains to the existing allowed domains list. When this command completes, the domains in the list will be added to any domains already on the AllowedDomains list.
131140

132-
### Example 8
141+
### Example 9
133142
```
134143
$list = New-Object Collections.Generic.List[String]
135144
$list.add("contoso.com")
136145
$list.add("fabrikam.com")
137146
Set-CsTenantFederationConfiguration -AllowedDomainsAsAList @{Remove=$list}
138147
```
139148

140-
Example 8 shows how you can remove domains from the existing Allowed Domains using a List object.
149+
Example 9 shows how you can remove domains from the existing Allowed Domains using a List object.
141150
First, a List is created and domains are added to it, then use the Remove method in the AllowedDomainsAsAList parameter to remove the domains from the existing allowed domains list. When this command completes, the domains in the list will be removed from the AllowedDomains list.
142151

143-
### Example 9
152+
### Example 10
144153
```
145154
Set-CsTenantFederationConfiguration -AllowTeamsConsumer $True -AllowTeamsConsumerInbound $False
146155
```
147156

148-
The command shown in Example 9 enables communication with people using Teams with an account that's not managed by an organization, to only be initiated by people in your organization. This means that people using Teams with an account that's not managed by an organization will not be able to discover or start a conversation with people in your organization.
157+
The command shown in Example 10 enables communication with people using Teams with an account that's not managed by an organization, to only be initiated by people in your organization. This means that people using Teams with an account that's not managed by an organization will not be able to discover or start a conversation with people in your organization.
149158

150-
### Example 10
159+
### Example 11
151160
```
152161
$list = New-Object Collections.Generic.List[String]
153162
$list.add("contoso.com")
@@ -157,20 +166,20 @@ Set-CsTenantFederationConfiguration -BlockedDomains $list
157166
Set-CsTenantFederationConfiguration -BlockAllSubdomains $True
158167
```
159168

160-
Example 10 shows how you can block all subdomains of domains in BlockedDomains list.
169+
Example 11 shows how you can block all subdomains of domains in BlockedDomains list.
161170
In this example, all users from contoso.com and fabrikam.com will be blocked.
162171
When the BlockAllSubdomains is enabled, all users from all subdomains of all domains in BlockedDomains list will also be blocked.
163172
So, users from subdomain.contoso.com and subdomain.fabrikam.com will be blocked.
164173
Note: Users from subcontoso.com will not be blocked because it's a completely different domain rather than a subdomain of contoso.com.
165174

166-
### Example 11
175+
### Example 12
167176
```
168177
Set-CsTenantFederationConfiguration -ExternalAccessWithTrialTenants "Allowed"
169178
```
170179

171-
Example 11 shows how you can allow users to communicate with users in tenants that contain only trial licenses (default value is Blocked).
180+
Example 12 shows how you can allow users to communicate with users in tenants that contain only trial licenses (default value is Blocked).
172181

173-
### Example 12
182+
### Example 13
174183
```
175184
$list = New-Object Collections.Generic.List[String]
176185
$list.add("contoso.com")
@@ -179,44 +188,44 @@ $list.add("fabrikam.com")
179188
Set-CsTenantFederationConfiguration -AllowedTrialTenantDomains $list
180189
```
181190

182-
Using the `AllowedTrialTenantDomains` parameter, you can whitelist specific "trial-only" tenant domains, while keeping the `ExternalAccessWithTrialTenants` set to `Blocked`. Example 12 shows how you can set or replace domains in the Allowed Trial Tenant Domains using a List collection object.
191+
Using the `AllowedTrialTenantDomains` parameter, you can whitelist specific "trial-only" tenant domains, while keeping the `ExternalAccessWithTrialTenants` set to `Blocked`. Example 13 shows how you can set or replace domains in the Allowed Trial Tenant Domains using a List collection object.
183192
First, a List collection is created and domains are added to it, then, simply include the `AllowedTrialTenantDomains` parameter and set the parameter value to the List object.
184193
When this command completes, the Allowed Trial Tenant Domains list will be replaced with those domains.
185194

186-
### Example 13
195+
### Example 14
187196
```
188197
Set-CsTenantFederationConfiguration -AllowedTrialTenantDomains @("contoso.com", "fabrikam.com")
189198
```
190199

191-
Example 13 shows another way to set a value of `AllowedTrialTenantDomains`. It uses array of objects and it always replaces value of the `AllowedTrialTenantDomains`. When this command completes, the result is the same as in example 12.
200+
Example 14 shows another way to set a value of `AllowedTrialTenantDomains`. It uses array of objects and it always replaces value of the `AllowedTrialTenantDomains`. When this command completes, the result is the same as in example 13.
192201

193202
The array of `AllowedTrialTenantDomains` can be emptied by running the following command: `Set-CsTenantFederationConfiguration -AllowedTrialTenantDomains @()`.
194203

195-
### Example 14
204+
### Example 15
196205
```
197206
$list = New-Object Collections.Generic.List[String]
198207
$list.add("contoso.com")
199208
200209
Set-CsTenantFederationConfiguration -AllowedTrialTenantDomains @{Add=$list}
201210
```
202211

203-
Example 14 shows how you can add domains to the existing Allowed Trial Tenant Domains using a List collection object.
212+
Example 15 shows how you can add domains to the existing Allowed Trial Tenant Domains using a List collection object.
204213
First, a List is created and domains are added to it, then, use the Add method in the `AllowedTrialTenantDomains` parameter to add the domains to the existing allowed domains list.
205214
When this command completes, the domains in the list will be added to any domains already on the Allowed Trial Tenant Domains list.
206215

207-
### Example 15
216+
### Example 16
208217
```
209218
$list = New-Object Collections.Generic.List[String]
210219
$list.add("contoso.com")
211220
212221
Set-CsTenantFederationConfiguration -AllowedTrialTenantDomains @{Remove=$list}
213222
```
214223

215-
Example 15 shows how you can remove domains from the existing Allowed Trial Tenant Domains using a List collection object.
224+
Example 16 shows how you can remove domains from the existing Allowed Trial Tenant Domains using a List collection object.
216225
First, a List is created and domains are added to it, then use the Remove method in the `AllowedTrialTenantDomains` parameter to remove the domains from the existing allowed domains list.
217226
When this command completes, the domains in the list will be removed from the Allowed Trial Tenant Domains list.
218227

219-
### Example 16
228+
### Example 17
220229
```
221230
Set-CsTenantFederationConfiguration -DomainBlockingForMDOAdminsInTeams "Enabled"
222231
```
@@ -234,7 +243,10 @@ If the `New-CsEdgeAllowList` cmdlet is used then users can only communicate with
234243
Note that string values cannot be passed directly to the AllowedDomains parameter.
235244
Instead, you must create an object reference using the `New-CsEdgeAllowList` cmdlet or the `New-CsEdgeAllowAllKnownDomains` cmdlet and then use the object reference variable as the parameter value.
236245

237-
The AllowedDomains parameter can support up to 4,000 domains.
246+
The AllowedDomains parameter can support up to 4,000 domains.
247+
248+
> [!IMPORTANT]
249+
> The `AllowFederatedUsers` property must be set to `True` for the `AllowedDomains` list to take effect. If `AllowFederatedUsers` is set to `False`, users will be blocked from communicating with all external domains regardless of the values in `AllowedDomains` or any `ExternalAccessPolicy` instance.
238250
239251
```yaml
240252
Type: Boolean
@@ -294,7 +306,9 @@ Accept wildcard characters: False
294306
> Applicable: Microsoft Teams
295307

296308
When set to True (the default value) users will be potentially allowed to communicate with users from other domains.
297-
If this property is set to False then users cannot communicate with users from other domains regardless of the values assigned to the AllowedDomains and BlockedDomains properties.
309+
If this property is set to False then users cannot communicate with users from other domains, regardless of the values assigned to the `AllowedDomains` and `BlockedDomains` properties or any `ExternalAccessPolicy` instances. In effect, the `AllowFederatedUsers` property serves as a master switch that globally enables or disables federation across the Tenant, overridding all other policy settings.
310+
311+
To block all domains while selectively allowing specific users to communicate externally via explicit `ExternalAccessPolicy` instances, set `AllowFederatedUsers` to `True` and leave the `AllowedDomains` property empty.
298312

299313
```yaml
300314
Type: Boolean
@@ -365,8 +379,12 @@ Accept wildcard characters: False
365379

366380
If the AllowedDomains property has been set to AllowAllKnownDomains, then users will be allowed to communicate with users from any domain except domains that appear in the blocked domains list.
367381
If the AllowedDomains property has not been set to AllowAllKnownDomains, then the blocked list is ignored, and users can only communicate with domains that have been expressly added to the allowed domains list.
382+
368383
The BlockedDomains parameter can support up to 4,000 domains.
369384

385+
> [!IMPORTANT]
386+
> The `AllowFederatedUsers` property must be set to `True` for the `AllowedDomains` list to take effect. If `AllowFederatedUsers` is set to `False`, users will be blocked from communicating with all external domains regardless of the values in `AllowedDomains` or any `ExternalAccessPolicy` instance.
387+
370388
```yaml
371389
Type: List
372390
Parameter Sets: (All)

0 commit comments

Comments
 (0)