function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Erica CoxErica Cox 

VF page suddenly getting insufficient privileges error

Suddenly all users are getting an Insufficient Privileges error when trying to access a VF page in our org. Even sys admins. The page hasn't changed, the controller hasn't changed, all profiles still have access to the page and controller, and all static resources referred to in the page are accounted for. Nothing in the setup audit trail since yesterday when things were running normally.
James LoghryJames Loghry
Have you checked object CRUD and field level security for any sobjects that are on the VF page?

Have you tried capturing the errors in a debug log (Setup->Monitor->Debug Log, create a new one and hit the page)

Is this a sites or communities VF page that could be redirecting to another VF page on error?
Erica CoxErica Cox
Thanks for the ideas, James. Another developer compiled all of the classes in the org and was able to isolate the problem. There had been a single Knowledge license in the org (unassigned) that was removed overnight with a license renewal. Some stray code in this page references a knowledge object and seems to be the cause of the error.