In app, access token with app only permission is used to elevate the privilege. in provider hosted & auto hosted apps, app only permission works however it is not available in SharePoint hosted app.
I am wondering as elevate the privilege is very much required to deliver business functionality why this option is not available in SharePoint hosted app? In this type of app also, in CSOM it might be required to run the code with elevated privilege.
Amit - Our life is short, so help others to grow.....
Whenever you see a reply and if you think is helpful, click ♥Vote As Helpful♥ And whenever you see a reply being an answer to the question of the thread, click ♥Mark As Answer♥