Let's cut to the chase: Salesforce security audits don't care about your good intentions. They demand proof. I've managed audits for healthcare, finance, and manufacturing orgs—where a single misconfigured sharing rule can trigger compliance fines. Here’s how to actually prepare, not just check boxes.
Don't just check "System Administrator" roles. Run this SOQL to find hidden risks:
SELECT Id, Name, Profile.Name, UserPermissionsMacroAdmin, UserPermissionsSelfReg FROM User WHERE UserPermissionsMacroAdmin = true OR UserPermissionsSelfReg = true
Example: At a healthcare client, we found 23 users with UserPermissionsMacroAdmin (enabling self-service admin tools) despite being sales reps. This violated HIPAA’s least-privilege principle. Cleaned it up before the audit.
Sharing rules are a mess in 80% of orgs. Audit these two critical areas first:
Loan_Appliance__c exposed customer SSNs. We moved to "Private" sharing + sharing sets for required teams.Site__c field to restrict visibility using OwnerId = :UserInfo.getUserId() in Apex triggers.OAuth apps and API keys are audit goldmines for security teams. Check:
Custom Permissions assigned to non-admin users (e.g., "Allow Marketing API" given to a sales rep)Example: A retail client’s "Inventory Sync" app had Full Access to Product__c. We scoped it to Read and added IP whitelisting. Audit team gave a pass.
Don’t wait for the auditor’s email. Before they arrive:
Minimum Password Length is ≥12, Maximum Age ≤90 days (non-negotiable for SOC 2).Setup > Security > Login History to flag logins from unexpected locations (e.g., "New York" at 3 AM for a user based in London).Security audits aren’t about perfection—they’re about showing you’ve systematically managed risk. If you can’t answer "Why does this user need this access?" in 10 seconds, you’re not ready. I’ve seen orgs fail because they spent weeks on documentation but couldn’t prove their sharing rules actually worked. Start with the SOQL, fix the obvious, and document the why.
Still unsure if your org is audit-ready? Run a free security health scan with OrgScanner—it flags misconfigurations in 2 minutes and gives actionable fixes. No fluff, just the gaps that will get you flagged.