[BZ1051260] check permission for public static methods
(cherry picked from commit 5d598e6)
Merge pull request #109 from pskopek/master-BZ1051260

[BZ1051260] check permission for public static methods