Forum Discussion
JSlei
Sep 14, 2021Brass Contributor
Apply sensitivity labels using PowerShell
Is it possible to apply sensitivity labels to documents in SharePoint (not sites or groups) using PowerShell?
- Sep 16, 2021There is no cmdlet to apply labels to individual files, afaik. Set-AIPFileLabel only works on local files. Using the MIP SDK is probably the way to go, at least until Microsoft introduces a cmdlet/Graph API endpoints.
Funnily enough we do have a cmdlet to remove labels: https://office365itpros.com/2021/03/25/decrypt-sharepoint-online-documents-graph/
WJN78
Feb 24, 2022Copper Contributor
How would someone using PowerShell change a label on a document? For example, a document was classified as Confidential. A request has come in to have the document reclassified as Internal. Is there a way for the Security Admin to change the classification of the document assuming we do not allow our base to change the classification themselves?
Feb 24, 2022
WJN78 Assuming the document is in SharePoint.
Unlock-SensitivityLabelEncryptedFile (SharePointOnlinePowerShell) | Microsoft Docs
Remove encryption for a labeled document
Might as well add this too (RMS to unified labeling cmdlet mapping)
Use PowerShell with the Azure Information Protection unified labeling client | Microsoft Docs