Forum Discussion
Apply sensitivity labels 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/
JSlei Hello again, didn't you look for an option to protect at scale without anyone have to review the documents? Are you saying this isn't applicable even if using PowerShell cmdlets for it?
https://office365itpros.com/2020/01/27/microsoft-previews-auto-label-policies-sensitivity-labels/
"Manual application of sensitivity labels is a good way to protect new messages and documents but does nothing to deal with the mass of documents and messages that already exist inside Office 365. To address the issue, Microsoft is running a preview program for auto-labeling Word, Excel, and PowerPoint files stored in SharePoint Online sites and OneDrive for Business accounts (Exchange Online will come later). The solution is intended to allow Office 365 tenants to protect existing content at scale without needing anyone to review large quantities of documents."