We’re rewarding the question askers & reputations are being recalculated! Read more.

Questions tagged [permissions]

Salesforce permissions are all about what a user can do in terms of Field Level Security, object level access, Apex class access, Visualforce page access, and other built in Salesforce access that are handled via a profile or permission set.

Filter by
Sorted by
Tagged with
59
votes
8answers
45k views

What is the best way to deploy profiles in Salesforce? (especially system admin)

What is the best way to deploy profiles in Salesforce? I have a system admin profile with access given to the objects that i have created in my sandbox. I have about 1000 fields across these objects. ...
45
votes
3answers
7k views

Salesforce bug enabled “Modify All”

Apparently, Salesforce has released a patch that implicated "Modify all" to be enabled for every single profile in some orgs. This includes standard profiles and custom as well. Yes, even standard ...
40
votes
2answers
58k views

How to fix insufficient access rights on cross-reference id?

I am getting the error: INSUFFICIENT_ACCESS_ON_CROSS_REFERENCE_ENTITY, insufficient access rights on cross-reference id: [] Scenario is, I am inserting an Opportunity and then Opportunity Line ...
31
votes
2answers
16k views

How to access profile permissions via API

If I know the name of a certain profile, I would like to obtain CRUD permission settings for each object in the profile using Apex. I see that there is an sObject called Profile, but this only ...
19
votes
2answers
3k views

“Required fields are missing” on non-null field

My organization uses a third-party relational replication tool to sync data between Salesforce and a SQL Server database. The replication software is written in Java and uses the Salesforce API for ...
18
votes
1answer
4k views

Best Practices for Managing Org Profiles & Permissions

Are there any books, tutorials or whitepapers out there that recommend a strategy how to cope with the complexity of profiles and permissions in big Salesforce orgs? You find fragments of that in ...
17
votes
3answers
9k views

VisualForce - How to detect if a user has write permissions for a field

I would like to display different elements to a user depending on whether they have write permissions for a certain field, or just read permissions. Is it possible to detect user permissions for a ...
17
votes
3answers
10k views

Does Process Builder run with System permissions or User permissions?

Regarding field-level security, does Lightning Process Builder run as system-level permissions or user? That is: Can I trigger an update to a field that the current user cannot edit? Can I filter ...
16
votes
2answers
5k views

are Triggers (and their delegated classes) or Batch affected by sharing?

I understand with sharing classes run in User Mode, meaning they respect permissions, field-level security and sharing rules of the current user. I understand without sharing classes run in System ...
15
votes
1answer
3k views

When to add apex class permissions to a profile

The apex class permissions are a bit confusing to me. For example, classes used by page controllers do not need to be added to the profile. Can anyone give a complete list of scenarios on when you ...
11
votes
6answers
1k views

App disappears from Permission Set included with package

We're working on our first Salesforce package, and recently switched from creating Beta packages to a Managed Package. For some reason, the permission set that we're pushing loses the entry in ...
11
votes
2answers
2k views

How do you Apex Unit Test Object(CRUD)/Field(FLS) Permissions in an Org Portable manner?

Specifically, how might one get an org portable Apex Unit Test User that DOES NOT have READ access to Accounts? Creating a Test Permission Set that DOES NOT have READ access to ACCOUNTS and assigning ...
10
votes
3answers
4k views

What are permissions are needed to upload a file via a public Salesforce community page?

I would like to be able to upload files using <lightning:fileUpload which is on a public community page. The community is using template: Customer Account Portal. The files would get attached to ...
10
votes
1answer
2k views

Unit-Testing Sites Permission Involving a Sharing Rule with Unit-Test Created Data

We currently have a Salesforce Site, and we're trying to add some unit-tests, around permissions and sharing rules that need to be set. We've smoke tested everything via the UI, and permissions appear ...
10
votes
2answers
6k views

Owner custom fields and some standard fields are not accessible in relations

I am trying to access owner information using soql for managed packaged sobject. select id,ownerId,owner.name, owner.Email_Subscription__c from ARE__HavesWants__c I tried above query but it is ...
10
votes
2answers
3k views

Custom Controllers - effect of running in System mode

The VisualForce Developer's Guide says: Like other Apex classes, all custom controllers run in system mode. Consequently, the current user's credentials are not used to execute controller logic, ...
10
votes
1answer
2k views

How To Cause DmlException - Delete

I thought I would be able to take a User who does not have delete privileges on an object, delete records from that object, and get a DmlException. No dice. Below are the Case permissions for the ...
10
votes
3answers
5k views

Metadata API Custom Field Permissions (how to automate this process)

We are using the Metadata API to add Custom Fields to the Account object in Salesforce. We are able to create the custom fields, but then the Salesforce user has to manually login to their account ...
9
votes
3answers
2k views

Can't install managed package because packaged permission set seems to have lost a read permission

I developed a Managed Extension Package. When I try to install it or create a patch org for it, this fails with no error but the note to call Salesforce. Support told me that it fails due to: ...
9
votes
1answer
4k views

Report Folder Sharing setting SFDC bug?

Background We need to configure a folder "Company X Reports" which has to: Everybody can view One profile called Supervisor can clone reports from there and save only in "My Personal Custom Reports" ...
8
votes
4answers
16k views

What overrides a profile?

I am confused about the hierarchy of settings 1) I have a profile A and it has a read only access. I have a permission set specific to an user and the permission set grants the user access to edit ...
8
votes
3answers
3k views

Programmatically check a user access level to a record

I have a strange behavior on my org. The user's profile have no "Delete" permissions for the custom object, only "Read / Create / Edit". So he can not delete any record from this object. But when i ...
8
votes
2answers
2k views

Which Apex classes & Objects must be enabled in a Permission Set?

I'm still a bit unsure which Apex classes I have to enable in a Permission set. I guess I don't need to enable Test classes I definitely need to enable Controller and Controller extensions for ...
8
votes
5answers
2k views

Visualforce exception page authentication

For sites, there's a standard visualforce exception page. We use a header on the site that will present either Welcome, username Or Login/register ...based on login status. Whenever a user finds ...
8
votes
1answer
16k views

INSUFFICIENT_ACCESS_ON_CROSS_REFERENCE_ENTITY, insufficient access rights on cross-reference id: [] on opportunity

I have created an object named as "Component" which has Master-Detail Relationship with Opportunity Object. On Opportunity we have a button says "Create Component", when user clicks on it it takes ...
8
votes
1answer
177 views

Summer '16 release breaking Visual Workflows?

Some of my visual workflows have been hitting permissions-related errors, and I suspect it's something to do with the Summer '16 release that hit my org over the weekend. I'm getting errors like this ...
8
votes
1answer
1k views

Updating profile via Metadata API from Apex gives weird error

I am trying to automatically enable pages for profiles (profileApexPageAccess doc) via Metadata API. Here is my method: public static void updateProfileAccesses(String profileName, List<String> ...
7
votes
3answers
4k views

How can I Efficiently Check if the Running User has a Custom Permission?

Is there any way to check in Apex if the running user has a specific Custom Permission? The best I know of using available methods involves two separate SOQL queries: public static Boolean ...
7
votes
1answer
3k views

Documentation for Roles and permissions

Does anyone know where I can find some documentation or a description of the roles and permissions found in the account 'Roles'? I have looked into the documentation and have not been able to find ...
7
votes
6answers
5k views

Can you limit the visibility of fields based on record ownership?

I know with permission sets and sharing rules you can limit visibility and how users can interact with entire records. Is there any way to limit visibility of fields? We are looking to make the basic ...
7
votes
2answers
2k views

Customize permissions required by a managed package

I've a managed package which when installed, shows that it has Read/Create/Edit/Delete permissions on all the standard objects (Step 1. Approve Package API Access - Extended Object Permissions) Is ...
7
votes
3answers
4k views

Permission Sets for Site Guest User

Managing permissions on a force.com site is one of my least favorite things to do. If you got it right in dev, then move to QA, you have to write down all the permissions because you can't deploy ...
7
votes
2answers
761 views

Accessing Chatter API in Communities

I'm Having trouble accessing the Chatter API in the context of a community. Mainly, we have a certain type of user that only has access as a user of a SalesForce community we are using to act as an ...
7
votes
1answer
66 views

Is Describe Information Accurate for the Site Guest User?

As the title states, can describe information be trusted for the site guest user? Scenario I want to be able to insert/update tasks against accounts via a public Apex webservice. Yes, I'm aware of ...
6
votes
3answers
1k views

Pulling Permission Sets only through IDE polls a trimmed version of them

In Eclipse Force.com IDE I created a Force.com project that was configured to pull the Permission Set folder only. The Permission Sets have been pulled, but in what appeared to be a trimmed form - all ...
6
votes
2answers
2k views

How to prevent users from viewing apex code?

There are many apex classes and triggers in my production org. Despite 'System Administrator' being the only enabled profile, (in Develop>>Apex Classes>>"Class Name">>Security) users can still view ...
6
votes
2answers
5k views

Apex bypasses field-level security?

Can an apex code, invoked by a non-admin user, perform an update on a field that has a field-level security of visible and read-only for non-admin profiles? If so, what is permitted/restricted by the ...
6
votes
2answers
3k views

How do you change profile level security permissions on an app after it's been installed?

I recently had an app that had been installed a while ago. In the mean time we had created a new profile type which, since it hadn't existed when the app was first installed, didn't have permissions ...
6
votes
2answers
2k views

Can you show/hide a custom tab on a per user basis?

Is there a way to show/hide a tab on a per user basis? I would like to manage this with Apex, but examples of managing this from the UI would also be helpful.
6
votes
1answer
6k views

Query Which Profiles Have Read Access To Specific Object?

Since I couldn't think of how to write this query off the top of my head, I thought it might be worth sharing. How can I query which Profiles have Read permission on a specific object? I knew it would ...
6
votes
3answers
1k views

For the Platform Event “Automated Process” user, why do both Visualforce controller access and email sending fail?

We are executing some asynchronous code that uses getContentAsPdf on a Visualforce page as the result of handling custom platform event and we get this error in the Apex Jobs listing: First error: [...
6
votes
2answers
10k views

Enabling SAML SSO: where is the “Use Single Sign-On” permission?

We've set up Single Sign on with SAML. Our IdP is OneLogin and using their link, we are able to connect. We now want to disable password login for some users in Salesforce. Salesforce's documentation ...
6
votes
2answers
1k views

Limit who can add/edit specific contact roles

I have a feeling I know the answer is No, but wanted to check if anyone had any luck or quick workaround to my issue. We use Account Contact Roles, but we want to allow specific profiles to add/edit ...
6
votes
1answer
590 views

How to guard a FeedItem insert when code is executing in a Force.com Site?

I have some code that is used both through a normally licensed user and through a "Site Guest User" for a public Force.com Site. I am aware that for the latter type of User Chatter capabilities are ...
6
votes
1answer
81 views

Does SObjectType Access Guarantee Id Access?

I am writing a fluent query builder which I hope will pass security review, and I still have a few nagging questions. I will refrain from asking more than one question per question, so right now, what ...
6
votes
1answer
11k views

Enabling Editing/Deleting others' Tasks without “Modify All”

Use Case My users are primarily Service users. They all have Read/Write access (through sharing rules) on all Cases, Contacts and Accounts that they deal with. They collaborate on data grooming - ...
6
votes
1answer
808 views

Cannot create a Permission Set related to an Idea via Console or Anonymous

I am trying to create a permission set in my code but I'm getting some issues when I tried to assign an Idea, Product2 or Pricebook. With some other objects like custom or other Standards, I'm able to ...
6
votes
1answer
3k views

Customer Community User Activity (Event) Access

I am trying to expose Events in a read only manner to users with a Customer Community license. Eventually I found out about the field IsVisibleInSelfService. This field is not visible to System ...
6
votes
2answers
562 views

Cannot edit Deployment Connections when given rights through a Permission Set

The default System Administrator profile does not allow for creation of Change Sets and Deployment Connections. At one time we set up a clone of System Adminstrator with the following permissions ...
6
votes
1answer
984 views

Permissions to execute System.abortJob() method

What permissions does user need to call System.abortJob() in Apex? When the method is called this error is displayed: System.SecurityException: Insufficient Privileges. Thanks.