Can someone explain ASP.NET trust levels to me?

前端 未结 3 926
孤独总比滥情好
孤独总比滥情好 2021-01-11 12:55

I\'ve heard a lot about trust levels, had people try to explain it to me but still am unable to give a scenario in which I would apply one trust level over another.

3条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-01-11 13:19

    While not an expert, I would give one of the more common examples of trust is if you bought hosting through a shared hoster through some vendor for $10 a month, where you don't have direct access to the machine, but get an allotted storage space. In this scenario, you get medium trust typically because the hoster wants to limit what you can do (make sure you can't delete or modify something that's not supposed to be), and don't have access to certain resources (like try to read a file outside of the folder you have permission to) and other tasks.

    We have full access to our machine where we host a site, and we give it full trust, it isn't a concern for us since its dedicated to our web site and not a shared resource.

提交回复
热议问题