Skip to content

Commit 4fe289c

Browse files
authored
Update Set-SPOTenantPreAuthSettings.md
1 parent a8c5d04 commit 4fe289c

File tree

1 file changed

+85
-90
lines changed

1 file changed

+85
-90
lines changed

sharepoint/sharepoint-ps/sharepoint-online/Set-SPOTenantPreAuthSettings.md

Lines changed: 85 additions & 90 deletions
Original file line numberDiff line numberDiff line change
@@ -19,39 +19,34 @@ Sets the configuration of pre-authentication.
1919

2020
## SYNTAX
2121

22+
### IsDisabled
2223
```powershell
23-
Set-SPOTenantPreAuthSettings
24-
-IsDisabled <bool> [<CommonParameters>]
24+
Set-SPOTenantPreAuthSettings -IsDisabled <Boolean> [<CommonParameters>]
2525
```
2626

27+
### AddListItem
2728
```powershell
28-
Set-SPOTenantPreAuthSettings
29-
-Add
30-
-Type {Allow | Deny}
31-
[-IncludedApps <string>]
32-
[-ExcludedApps <string>]
33-
[-IncludedFeatures <string>]
34-
[-ExcludedFeatures <string>]
35-
[<CommonParameters>]
29+
Set-SPOTenantPreAuthSettings [-Add] -Type <TenantPreAuthSettingsListType> [-IncludedApps <String>]
30+
[-ExcludedApps <String>] [-IncludedFeatures <String>] [-ExcludedFeatures <String>] [<CommonParameters>]
3631
```
3732

33+
### RemoveListItem
3834
```powershell
39-
Set-SPOTenantPreAuthSettings
40-
-Remove
41-
-Id <string>
35+
Set-SPOTenantPreAuthSettings [-Remove] -Id <String> [<CommonParameters>]
4236
```
4337

4438
## DESCRIPTION
4539

46-
You can use the Set-SPOTenantPreAuthSettings cmdlet to configure or disable the pre-authentication feature within SharePoint Online. The disablement can be combined with switches to support granular pre-authentication management for specific apps and features at the tenant level.
40+
You can use this cmdlet to configure or disable the pre-authentication feature within SharePoint Online. The disablement can be combined with switches to support granular pre-authentication management for specific apps and features at the tenant level.
4741

48-
**What is pre-authentication?**
49-
50-
SharePoint includes self-issued tokens in URLs called pre-authentication URLs (also known as tempauth URLs) to provide temporary access to a SharePoint resource, which helps support more rich user experiences. For example, a common scenario is downloading a file using a URL that includes a token in the `tempauth` query parameter like the following:
51-
52-
`https://<tenant>.sharepoint.com/sites/samplesite/_layouts/15/download.aspx?UniqueId=<id>&tempauth=v1.ey...`
53-
54-
But this feature is currently being deprecated, so this cmdlet lets you control the use of pre-authentication in various use cases.
42+
> [!NOTE]
43+
> **What is pre-authentication?**
44+
>
45+
> SharePoint includes self-issued tokens in URLs called pre-authentication URLs (also known as tempauth URLs) to provide temporary access to a SharePoint resource, which helps support more rich user experiences. For example, a common scenario is downloading a file using a URL that includes a token in the `tempauth` query parameter like the following:
46+
>
47+
> `https://<tenant>.sharepoint.com/sites/samplesite/_layouts/15/download.aspx?UniqueId=<id>&tempauth=v1.ey...`
48+
>
49+
> But this feature is currently being deprecated, so this cmdlet lets you control the use of pre-authentication in various use cases.
5550
5651
> [!NOTE]
5752
> The settings leverage an order of precedence:
@@ -60,9 +55,9 @@ But this feature is currently being deprecated, so this cmdlet lets you control
6055
> 3. IsDisabled
6156
6257
> [!NOTE]
63-
> As the use of this cmdlet can disable functionality in your SharePoint Online Tenant, it is highly recommended to test and evaluate each change in a test tenant ahead of making changes in a production environment.
58+
> As the use of this cmdlet can disable functionality in your SharePoint Online tenant, it is highly recommended to test and evaluate each change in a test tenant ahead of making changes in a production environment.
6459
65-
You must be a SharePoint Online administrator to run the cmdlet.
60+
You must be a SharePoint Administrator to run the cmdlet.
6661

6762
## EXAMPLES
6863

@@ -94,9 +89,9 @@ Set-SPOTenantPreAuthSettings -IsDisabled $true
9489
9590
Set-SPOTenantPreAuthSettings -Add -Type Allow -ExcludedApps "029e7c27-4b9c-4f8b-ba32-b96249468d42" -ExcludedFeatures "Download,WebRenderingEmbed"
9691
```
97-
This example disables pre-authentication overall and allows all apps apart from one to use pre-authentication for all features except for Download and WebRenderingEmbed.
92+
This example disables pre-authentication overall and allows all apps apart from one to use pre-authentication for all features except for `"Download"` and `"WebRenderingEmbed"`.
9893

99-
In this case, the app 029e7c27-4b9c-4f8b-ba32-b96249468d42 will always be denied from using pre-authentication since it is excluded from the allow list setting. Any other app will be allowed to use pre-authentication for any feature apart from Download and WebRenderingEmbed.
94+
In this case, the app `"029e7c27-4b9c-4f8b-ba32-b96249468d42"` will always be denied from using pre-authentication since it is excluded from the allow list setting. Any other app will be allowed to use pre-authentication for any feature apart from `"Download"` and `"WebRenderingEmbed"`.
10095

10196
### Example 5
10297
```powershell
@@ -106,9 +101,9 @@ Set-SPOTenantPreAuthSettings -Add -Type Allow -IncludedApps "029e7c27-4b9c-4f8b-
106101
107102
Set-SPOTenantPreAuthSettings -Add -Type Deny -IncludedApps "029e7c27-4b9c-4f8b-ba32-b96249468d42,0ab82eba-96c7-4681-9f75-c18437e20d0e"
108103
```
109-
This example disables pre-authentication overall but contains an overlap between the settings in the Allow list and Deny list. It first allows an app to use pre-authentication for the OfficeOnline, WebRenderingEmbed, and Download features. But in the final execution of the cmdlet, it denies the same app from using pre-authentication for all features.
104+
This example disables pre-authentication overall but contains an overlap between the settings in the Allow list and Deny list. It first allows an app to use pre-authentication for the `"OfficeOnline"`, `"WebRenderingEmbed"`, and `"Download"` features. But in the final execution of the cmdlet, it denies the same app from using pre-authentication for all features.
110105

111-
In this case, the app 029e7c27-4b9c-4f8b-ba32-b96249468d42 would not be allowed to use pre-authentication for any of the allow-listed features despite having the setting. This is because the Deny list takes precedence over the Allow list.
106+
In this case, the app `"029e7c27-4b9c-4f8b-ba32-b96249468d42"` would not be allowed to use pre-authentication for any of the allow-listed features despite having the setting. This is because the Deny list takes precedence over the Allow list.
112107

113108
### Example 6
114109
```powershell
@@ -119,70 +114,72 @@ Set-SPOTenantPreAuthSettings -Add -Type Deny -IncludedApps "Empty"
119114
This example enables pre-authentication overall and denies requests that are not coming from an app (e.g. requests coming via a browser) from using pre-authentication for all features.
120115

121116
> [!NOTE]
122-
> The `"Empty"` value for `-IncludedApps` or `-ExcludedApps` is different from an empty string `""`:
117+
> The `"Empty"` value for `-IncludedApps` or `-ExcludedApps` is different from an empty string `""`. The rules are as follows:
123118
> - `"Empty"` represents any requests that are not coming from an app (e.g. direct requests from the browser) and will not have an app ID associated with it
124119
> - `""` can mean several things:
125120
> - If you have `–IncludedApps "" -ExcludedApps ""`, it means that the setting applies to all
126-
> - If you have `–IncludedApps "" -ExcludedApps "<appid>"`, it means that the setting applies to all apps apart from 029e7c27-4b9c-4f8b-ba32-b96249468d42.
127-
> - If you have `–IncludedApps "029e7c27-4b9c-4f8b-ba32-b96249468d42" and -ExcludedApps ""`, it means that the setting only applies to the appId 029e7c27-4b9c-4f8b-ba32-b96249468d42
121+
> - If you have `–IncludedApps "" -ExcludedApps "029e7c27-4b9c-4f8b-ba32-b96249468d42"`, it means that the setting applies to all apps apart from `"029e7c27-4b9c-4f8b-ba32-b96249468d42"`.
122+
> - If you have `–IncludedApps "029e7c27-4b9c-4f8b-ba32-b96249468d42" and -ExcludedApps ""`, it means that the setting only applies to the app `"029e7c27-4b9c-4f8b-ba32-b96249468d42"`
128123
> - You cannot have a setting with `–IncludedApps "029e7c27-4b9c-4f8b-ba32-b96249468d42" –ExcludedApps "029e7c27-4b9c-4f8b-ba32-b96249468d42"`
129124
130125
## PARAMETERS
131126

132-
### -IsDisabled
133-
134-
This parameter allows the administrator to toggle pre-authentication for all apps and features to be either enabled or disabled.
127+
### -Add
135128

136-
PARAMVALUE: True | False
129+
This parameter specifies that the operation of the cmdlet is to Add a setting to the allow list or deny list.
137130

138131
```yaml
139-
Type: Boolean
140-
Parameter Sets: IsDisabled
132+
Type: SwitchParameter
133+
Parameter Sets: AddListItem
141134
Applicable: SharePoint Online
142-
Required: True
135+
Required: False
143136
Position: Named
144-
Default value: False
137+
Default value: None
145138
Accept pipeline input: False
146139
Accept wildcard characters: False
147140
```
148141
149-
### -Add
142+
### -ExcludedApps
150143
151-
This parameter specifies that the operation of the cmdlet is to Add a setting to the SPOTenantPreAuthSettings configuration.
144+
This parameter value contains the apps ids to configure within the `-ExcludedApps` scope.
145+
146+
PARAMVALUE: `"Empty"`, `""`, or a comma-separated list of app IDs
152147

153148
```yaml
154-
Type: SwitchParameter
155-
Parameter Sets: Add
149+
Type: String
150+
Parameter Sets: AddListItem
156151
Applicable: SharePoint Online
157-
Required: True
152+
Required: False
158153
Position: Named
159-
Default value: None
154+
Default value: ""
160155
Accept pipeline input: False
161156
Accept wildcard characters: False
162157
```
163158

164-
### -Remove
159+
### -ExcludedFeatures
165160

166-
This parameter specifies that the operation of the cmdlet is to Remove a setting from the SPOTenantPreAuthSettings configuration.
161+
This parameter value contains the feature names to configure within the `-ExcludedFeatures` scope.
162+
163+
PARAMVALUE: `"Empty"`, `""`, or a comma-separated list of app IDs
167164

168165
```yaml
169-
Type: SwitchParameter
170-
Parameter Sets: Remove
166+
Type: String
167+
Parameter Sets: AddListItem
171168
Applicable: SharePoint Online
172-
Required: True
169+
Required: False
173170
Position: Named
174-
Default value: None
171+
Default value: ""
175172
Accept pipeline input: False
176173
Accept wildcard characters: False
177174
```
178175

179176
### -Id
180177

181-
This parameter identifies the configuration setting to remove from the SPOTenantPreAuthSettings configuration set. It is only required with the -Remove parameter.
178+
This parameter identifies the list item setting to remove from the current configuration. It is only required with the `-Remove` parameter.
182179

183180
```yaml
184181
Type: String
185-
Parameter Sets: Remove
182+
Parameter Sets: RemoveListItem
186183
Applicable: SharePoint Online
187184
Required: True
188185
Position: Named
@@ -191,32 +188,32 @@ Accept pipeline input: False
191188
Accept wildcard characters: False
192189
```
193190

194-
### -Type
191+
### -IncludedApps
195192

196-
This parameter indicates whether the cmdlet is interacting with the Allow list or the Deny list within the SPOTenantPreAuthSettings.
193+
This parameter value contains the app ids to configure within the `-IncludedApps` scope.
197194

198-
PARAMVALUE: Allow | Deny
195+
PARAMVALUE: `"Empty"`, `""`, or a comma-separated list of app IDs
199196

200197
```yaml
201-
Type: ListType
202-
Parameter Sets: Add
198+
Type: String
199+
Parameter Sets: AddListItem
203200
Applicable: SharePoint Online
204-
Required: True
201+
Required: False
205202
Position: Named
206-
Default value: None
203+
Default value: ""
207204
Accept pipeline input: False
208205
Accept wildcard characters: False
209206
```
210207

211-
### -IncludedApps
208+
### -IncludedFeatures
212209

213-
This parameter value contains the app ids to configure within the SPOTenantPreAuthSettings `-IncludedApps` scope.
210+
This parameter value contains the feature names to configure within the `-IncludedFeatures` scope.
214211

215-
PARAMVALUE: "Empty", "", or a comma-separated list of app IDs
212+
PARAMVALUE: `"Empty"`, `""`, or a comma-separated list of app IDs
216213

217214
```yaml
218215
Type: String
219-
Parameter Sets: Add
216+
Parameter Sets: AddListItem
220217
Applicable: SharePoint Online
221218
Required: False
222219
Position: Named
@@ -225,53 +222,51 @@ Accept pipeline input: False
225222
Accept wildcard characters: False
226223
```
227224

228-
### -ExcludedApps
225+
### -IsDisabled
229226

230-
This parameter value contains the apps ids to configure within the SPOTenantPreAuthSettings `-ExcludedApps` scope.
227+
This parameter allows the administrator to toggle pre-authentication for all apps and features to be either enabled or disabled.
231228

232-
PARAMVALUE: "Empty", "", or a comma-separated list of app IDs
229+
PARAMVALUE: True | False
233230

234231
```yaml
235-
Type: String
236-
Parameter Sets: Add
232+
Type: Boolean
233+
Parameter Sets: IsDisabled
237234
Applicable: SharePoint Online
238-
Required: False
235+
Required: True
239236
Position: Named
240-
Default value: ""
237+
Default value: False
241238
Accept pipeline input: False
242239
Accept wildcard characters: False
243240
```
244241

245-
### -IncludedFeatures
246-
247-
This parameter value contains the feature names to configure within the SPOTenantPreAuthSettings `-IncludedFeatures` scope.
242+
### -Remove
248243

249-
PARAMVALUE: "Empty", "", or a comma-separated list of app IDs
244+
This parameter specifies that the operation of the cmdlet is to Remove a setting from the allow list or deny list.
250245

251246
```yaml
252-
Type: String
253-
Parameter Sets: Add
247+
Type: SwitchParameter
248+
Parameter Sets: RemoveListItem
254249
Applicable: SharePoint Online
255250
Required: False
256251
Position: Named
257-
Default value: ""
252+
Default value: None
258253
Accept pipeline input: False
259254
Accept wildcard characters: False
260255
```
261256

262-
### -ExcludedFeatures
257+
### -Type
263258

264-
This parameter value contains the feature names to configure within the SPOTenantPreAuthSettings `-ExcludedFeatures` scope.
259+
This parameter indicates whether the cmdlet is interacting with the allow list or the deny list.
265260

266-
PARAMVALUE: "Empty", "", or a comma-separated list of app IDs
261+
PARAMVALUE: Allow | Deny
267262

268263
```yaml
269-
Type: String
270-
Parameter Sets: Add
264+
Type: TenantPreAuthSettingsListType
265+
Parameter Sets: AddListItem
271266
Applicable: SharePoint Online
272-
Required: False
267+
Required: True
273268
Position: Named
274-
Default value: ""
269+
Default value: None
275270
Accept pipeline input: False
276271
Accept wildcard characters: False
277272
```
@@ -282,20 +277,20 @@ The `-IncludedFeatures` and `-ExcludedFeatures` use feature names from the follo
282277

283278
| Feature name | Description | Additional Information |
284279
|----------------------|--------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------|
285-
| DataFormWebpart | Scenarios involved with DataFormWebParts to display/interact with SharePoint data. | [DataFormWebPart Properties (Microsoft.SharePoint.WebPartPages) - Microsoft Learn ](https://learn.microsoft.com/en-us/previous-versions/office/developer/sharepoint-2010/ms369119(v=office.14)) |
286-
| Download | Scenarios for getting pre-authenticated download URLs. 3rd party application and some 1st party applications may be broken. | [OAuth 2.0 and OpenID Connect protocols on the Microsoft identity platform - Microsoft Learn ](https://learn.microsoft.com/en-us/entra/identity-platform/v2-protocols) |
280+
| DataFormWebpart | Scenarios involved with DataFormWebParts to display/interact with SharePoint data. | [DataFormWebPart Properties (Microsoft.SharePoint.WebPartPages) - Microsoft Learn ](/previous-versions/office/developer/sharepoint-2010/ms369119(v=office.14)) |
281+
| Download | Scenarios for getting pre-authenticated download URLs. 3rd party application and some 1st party applications may be broken. | [OAuth 2.0 and OpenID Connect protocols on the Microsoft identity platform - Microsoft Learn ](/entra/identity-platform/v2-protocols) |
287282
| OfficeOnline | Office on the web scenarios. Performance might be impacted. | |
288283
| SearchPreview | Scenarios involved in generating previews/thumbnails/conversions for search query results. Experience might be broken. | |
289-
| SharePointConnector | Scenarios involved with SharePoint Connectors | [SharePoint Connectors - Microsoft Learn](https://learn.microsoft.com/en-us/connectors/sharepointonline/) |
284+
| SharePointConnector | Scenarios involved with SharePoint Connectors | [SharePoint Connectors - Microsoft Learn](/connectors/sharepointonline/) |
290285
| Thumbnail | Scenarios for getting pre-authenticated thumbnail generation URLs. | |
291286
| UploadSession | Scenarios for creating upload sessions. 3rd party application and some 1st party applications may be broken | |
292287
| Video | Playing Video hosted on SharePoint might be broken | |
293288
| WebRendering | Scenarios for rendering previews of files in browser. | |
294-
| WebRenderingEmbed | Embed SharePoint files in another application. 3rd party application and some 1st party applications may be broken | [Embed Web Part](https://support.microsoft.com/en-us/office/add-content-to-your-page-using-the-embed-web-part-721f3b2f-437f-45ef-ac4e-df29dba74de8) |
295-
| Whiteboard | Teams integration with Whiteboard app will be broken for anonymous and guest users. | [Use Whiteboard in a Teams meeting - Microsoft Support](https://support.microsoft.com/en-us/office/use-whiteboard-in-a-teams-meeting-26f87802-b37f-4af0-806d-af79fbfb8ae6) |
289+
| WebRenderingEmbed | Embed SharePoint files in another application. 3rd party application and some 1st party applications may be broken | [Embed Web Part](https://support.microsoft.com/office/add-content-to-your-page-using-the-embed-web-part-721f3b2f-437f-45ef-ac4e-df29dba74de8) |
290+
| Whiteboard | Teams integration with Whiteboard app will be broken for anonymous and guest users. | [Use Whiteboard in a Teams meeting - Microsoft Support](https://support.microsoft.com/office/use-whiteboard-in-a-teams-meeting-26f87802-b37f-4af0-806d-af79fbfb8ae6) |
296291

297292
### CommonParameters
298-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).
293+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](/powershell/module/microsoft.powershell.core/about/about_commonparameters?view=powershell-5.1).
299294

300295
## RELATED LINKS
301296

0 commit comments

Comments
 (0)