Activity › Forums › Salesforce® Discussions › What is Inherited Sharing in Apex in Salesforce ?
-
What is Inherited Sharing in Apex in Salesforce ?
Posted by Kirandeep on August 17, 2020 at 1:33 PMWhat is Inherited Sharing in Apex in Salesforce ?
Ratnesh replied 5 years, 9 months ago 4 Members · 3 Replies -
3 Replies
-
Using inherited sharing enables you to pass security review and ensure that your privileged Apex code is not used in unexpected or insecure ways. An Apex class with inherited sharing runs as with sharing when used as a Visualforce page controller, Apex REST service, or an entry point to an Apex transaction.
- [adinserter block='9']
-
Using inherited sharing enables you to pass security review and ensure that your privileged Apex code is not used in unexpected or insecure ways.
-
Inherited sharing keyword to define apex class as Inheritedsharing is available with the Salesforce winter’19 release in both Salesforce classing and lighting versions.
– If the class is declared as inheritedsharing, it runs in the sharing mode of the class that called it.
– The keyword ‘inheritedsharing’ is used to define an Apex class as Inheritedsharing class.
– If a class declared as inheritedsharing, it runs as with sharing by default.
Log In to reply.