Now you don't really want to exclude folders entirely in a production environment. That would be silly. You still need protection. So in production, just be sure to disable on-access scanning. In a test environment, you can exclude these folders from all scans. Terminology may vary by virus protection software.
The key folders are:
- C:\Program Files\Microsoft Office Servers
- C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions
$ssa = Get-SPEnterpriseSearchServiceApplication $ssa.AdminComponent.IndexLocation