I have something curious that I am hoping a .Net expert can help me with.
I have a custom configuration section and to get hold of it I do this:
va
I know this is an old thread, but I ran into this problem recently when working with a client and thought I'd post another suggestion. In my case the issue was using a non-static ConfigurationManager method, which can cause a SecurityException under certain specific conditions (app targeting .NET Framework 4 and installed on a network drive, and in this case also Windows Update being disabled). Here is more information on the problem and a hotfix from Microsoft:
https://support.microsoft.com/en-us/help/2580188/fix-system.security.securityexception-occurs-when-a-.net-framework-4-based-application-that-calls-a-static-method-in-the-system.configuration.configurationmanager-class-runs-on-a-network-share