The Salesforce security model is the set of controls that decides who can log in to your org and what they can see once they're in. Salesforce's data security module splits it into four levels, organization, objects, fields and records, and you mix them to give each person just the access they need.
The same module notes that the model works at the API level, so your permissions still apply when someone queries or updates data through API calls. So a gap in any one layer matters, no matter how a user or an integration gets to the data.
Most of what follows is about the layers you control, plus the code and integrations you build on them. If you're here for the regulatory side, we've got separate guides to SOX compliance, GDPR in Salesforce, HIPAA backups and PCI compliance.
What does Salesforce secure, and what do you?
Salesforce looks after the service itself. According to its Security, Privacy, and Architecture documentation, that covers TLS encryption between your network and the service, intrusion detection, and ISO 27001 and SOC 2 audits of the covered services.
If you want to see what Salesforce publishes about its side, our post on the shared responsibility model walks through who covers what. The same Salesforce documentation is clear that if you store regulated data, it's on you to make sure your use of the service complies with the law.
No platform audit will stop data leaking through a misconfigured permission set or an integration with more access than it needs. That part is yours: the four layers below, plus the code and connections you build on top of them.
What are the 4 layers of the Salesforce security model?
Each layer answers a different question and has its own tools. Here they are side by side, using a sales team where only Finance should see commission rates as the example.
| Layer | Question it answers | Salesforce tools | Example |
|---|---|---|---|
| Organization | Who can log in, from where and when? | Password policies, login IP ranges and login hours | A rep can only log in from the office network during working hours |
| Object | Which types of records can this user work with? | Profiles, permission sets and permission set groups | A rep can read, create and edit opportunities but not delete them |
| Field | Which fields on a record can this user see or edit? | Field permissions in permission sets and profiles | The commission rate field is hidden from reps and visible to Finance |
| Record | Which individual records can this user reach? | Org-wide defaults, role hierarchy, sharing rules and manual sharing | Opportunities are Private, so a rep sees only the deals they own |
Organization-level security
Think of organization-level security as the perimeter. Salesforce's org access unit covers managing who your authorized users are, setting password policies, and limiting the IP ranges and hours each profile can log in from.
Offboarding sits here too. The same unit explains that you can't delete a user, but you can deactivate them, and if a deactivation is blocked you can freeze the account in the meantime.
Salesforce requires everyone to use MFA when they log in to a product's UI, and MFA is part of the login process by default for production orgs. Admins can also set up single sign-on from a third-party identity provider.
Object-level security
Object permissions decide whether someone can create, read, edit or delete an object's records at all. Salesforce's object access unit says each user gets one profile, and it recommends handing out object permissions through permission sets and permission set groups.
Its suggested pattern is to give users the Minimum Access - Salesforce profile, or a clone of it, and then grant only what they need through permission sets. A permission set group bundles several sets into one assignment that fits a job, like a sales rep.
Field-level security
Field permissions control whether someone can see and edit a particular field on an object they can already open. Salesforce's field access unit points out that page layouts only control fields on detail and edit pages.
Field permissions, by contrast, apply everywhere, including related lists, list views, reports and search results. So taking a sensitive field off a layout isn't enough, and the same unit says no other shortcut gives you the same protection.
Record-level security
Record access decides which individual records someone can view and edit inside an object they can already open. Salesforce's record access unit lists four controls in order of increasing access: org-wide defaults, role hierarchies, sharing rules and manual sharing.
How does record access open up in Salesforce?
You lock records down with org-wide defaults, set to Private, Public Read Only, Public Read/Write or Controlled by Parent, and then open them up. Salesforce's record access unit says sharing rules can't restrict access below those defaults, and the steps below follow it outward.

The role hierarchy doesn't have to match your org chart. Salesforce's role hierarchy unit adds that if Grant Access Using Hierarchies is turned off for a custom object, only the owner and users given access through sharing can reach its records.
Sharing rules can be based on the record owner or on criteria the records must match. Salesforce's sharing rules unit lets you share with roles, territories or public groups, which can mix users from different profiles and roles.
How do you keep Apex and integrations inside the model?
Your own code can still reach past the layers you've set up, so it needs checks of its own. The Apex Developer Guide says sharing declarations like with sharing don't enforce object-level access or field-level security.
Recent API versions also changed the default, which is worth knowing before you upgrade. The Winter '27 Apex Developer Guide says that in API version 67.0 and later, Apex runs in user context by default, while version 66.0 and earlier default to system mode.
To be explicit, add WITH USER_MODE to a SOQL query, which Salesforce's Apex docs say enforces the user's object permissions, field-level security and sharing rules. When you'd rather drop the fields a user can't access than have the query fail, the same guide points you to Security.stripInaccessible() for query results and for records before DML.
Injection is the other classic gap, and the Apex guide's advice is to avoid dynamic SOQL and use static queries with binding variables instead. Peer reviews and the scans in your CI/CD pipeline are there to catch what slips through.
For integrations and pipelines, give each connection its own user with only the scopes it needs, and keep its secrets out of your code. When a CI job has to sign in, the Salesforce DX Developer Guide recommends org login jwt, which logs in with a private key file using the JWT bearer flow.
How do you audit and monitor the model?
Access drifts as people change roles, so somebody on your team has to own regular checks. Salesforce's data security overview lists the built-in audit tools: record modification fields, Login History for the past six months, Field History Tracking and Setup Audit Trail for configuration changes.
For more detail, Event Monitoring records logins, API calls, Apex executions and report exports, and our threat detection guide shows what to look for. On Enterprise, Unlimited and Performance Edition you get some log types free with 1-day retention, and up to a year for some log types costs extra.
Field History Tracking keeps changes to up to 20 fields per object for 18 months in the UI, according to Salesforce's Field Audit Trail unit. For longer history, the same Trailhead unit points you to Field Audit Trail, and our Field Audit Trail guide covers it in depth.
Where does Shield Platform Encryption fit?
If you hold regulated data, Salesforce's Shield Platform Encryption unit describes its 256-bit encryption, field-level encryption and key options such as bring your own key (BYOK). Our Shield Platform Encryption guide walks through setup and the testing to do before you switch it on.
Salesforce security model best practices
These habits keep the model close to what you designed. Each row links to the Salesforce docs behind it.
| Habit | What Salesforce says |
|---|---|
| Start users on Minimum Access - Salesforce | Grant access through permission sets and permission set groups |
| Set org-wide defaults to the most restrictive level | Open access with the role hierarchy, sharing rules and manual sharing |
| Hide sensitive fields with field permissions | Page layouts don't cover reports, list views or search |
| Keep MFA on and limit login hours | MFA is required for UI logins, and login hours and IP ranges are set by profile |
| Set an explicit access mode in Apex | The Apex Developer Guide recommends it for every database operation in trigger and handler classes |
| Review Setup Audit Trail and Login History | Both are built-in audit tools, so check them on a schedule rather than just before an audit |
Backups belong on the list too, since a bad permission change or deletion has to be reversible. Our guides to Salesforce backup best practices and automated backups cover data and metadata.
Security audit checklist
Use this checklist to review your own org. The areas follow the four layers and audit tools above, and the timing is a starting point you can tighten.
| Area | What to review | How often |
|---|---|---|
| Users | Active users against headcount, departed staff deactivated or frozen, admin accounts | Monthly |
| Profiles and permission sets | Users on high-access profiles, temporary assignments that stayed, unused permission sets | Quarterly |
| Org-wide defaults | Objects set to Public Read/Write without a reason | Twice a year |
| Sharing rules | Rules that outlived their project, broad criteria-based rules, piles of manual shares | Quarterly |
| Sensitive fields | Field permissions on financial, personal and health data, with nothing hidden by layout alone | Quarterly |
| Integrations | Integration users, their scopes, and how old their credentials are | Quarterly |
| Logs | Setup Audit Trail for undocumented changes, Login History for odd patterns | Monthly |
Where does Flosum fit?
Every deployment can change a profile, permission set or sharing rule, so the release process is part of the security model. The Flosum DevOps platform runs admin, developer and AI-generated changes through one platform with the same version control, approvals and audit trail.
Flosum's product page also covers one-click rollback for a release that causes a production issue, and audit evidence produced in the release pipeline for SOX. Flosum DevOps runs in Flosum's cloud or in your own cloud.
FAQs
What is the Salesforce security model?
It's how Salesforce decides who gets into an org and which data they can view or change. Salesforce's data security module splits it into organization, object, field and record access.
What is the difference between object-, field- and record-level security?
Object permissions decide whether a user can work with a type of record, and field permissions decide which fields on it they can see or edit. Record access then decides which individual records they reach, as Salesforce's record access unit explains.
What is the difference between profiles and permission sets?
Each user has one profile, and permission sets add access on top. Salesforce recommends the Minimum Access - Salesforce profile plus permission sets and permission set groups for everything else.
Does with sharing enforce object and field permissions in Apex?
No. According to the Apex Developer Guide, with sharing applies record sharing rules only, so object and field checks come from user mode or Security.stripInaccessible().
Book a demo to see how Flosum keeps permission and sharing changes reviewed before they reach production.
Thank you for subscribing




