How to Block Malware Uploads to OneDrive for Business
Question details
Organizations need a way to scan files on personal devices to prevent malicious files from being uploaded to corporate cloud storage.

- Product
- OneDrive for Business
- Device & OS
- Android
- Scenario
- Users are attempting to upload files from a personal folder on their Android device to corporate OneDrive storage.
- Observed behavior
- Administrators require a secure configuration to intercept and scan files prior to or during upload to prevent malware from compromising corporate data.
Ensure you have global administrator or security administrator privileges in your Microsoft 365 tenant to configure threat protection and endpoint policies.
Utilize Microsoft 365 Built-in Malware Detection
OneDrive for Business includes native malware detection that automatically scans files asynchronously as they are uploaded.
While it does not scan files locally on a personal device before upload, Microsoft's asynchronous anti-virus engine immediately scans files as they arrive in the cloud. If malware is detected, the file is isolated, preventing users from opening, sharing, or syncing it.
Log into the Microsoft 365 Defender portal using your administrator credentials and navigate to the Policies & rules section.
Locate Threat policies, click on Safe Attachments, and select Global settings. Ensure that 'Turn on Defender for Office 365 for SharePoint, OneDrive, and Microsoft Teams' is toggled on.

Implement Pre-Upload Scanning with Mobile Application Management (MAM)
Use endpoint protection and conditional access policies to force a security scan on Android devices before uploads are permitted.
Securely Manage and Edit Files with WPS Office
If managing complex corporate cloud security policies becomes overwhelming, consider WPS Office. It provides a free, lightweight, and highly secure alternative for processing documents, featuring a familiar interface and seamless migration.
- 1. Download WPS Office: Visit the official WPS website or the Google Play Store to download the free WPS Office suite for your device.
- 2. Install and Open: Follow the simple installation prompts and launch the application to access the main workspace.
- 3. Work Securely: Create, edit, and save your documents utilizing built-in password protection and encryption tools to keep your data safe.

Frequently Asked Questions
Does OneDrive automatically scan for viruses upon upload?
Yes, Microsoft 365 includes a built-in virus detection engine that asynchronously scans files uploaded to SharePoint Online, OneDrive for Business, and Microsoft Teams.
Can I block specific file types from being uploaded to OneDrive?
Yes. Administrators can configure sync policies within the SharePoint admin center to block the upload of specific file extensions that are commonly associated with malware.
What happens when OneDrive detects a malicious file?
When a malicious file is identified, it is marked with a red shield icon. The file remains in cloud storage, but users are blocked from downloading, opening, sharing, or syncing it.




