To set your own trust level, you need to create a security policy file and then specify this file in the security policy section of the application web.config.

For example, you create a file called web_custom.config, set the desired permissions there, and then refer to this file from within your web.config file:

<!--  Custom trust level for my application  -->
                   <trustLevel name="Custom" policyFile="web_custom.config" />

            <trust level="Custom" originUrl=""/>

You may refer to the following Microsoft article for more information:

ASP.NET Trust Levels and Policy Files