以下表格将说明使用权限要求的型别。
The following table describes the types of permission requests.
要求衍生类别必须具有指定的识别或使用权限。
Require derived classes to have a specified identity or permission.
例如,呼叫堆叠中的方法可以使用一组具名为P SET1的使用权限拒绝它所有的呼叫端,如此一来,只要对这些呼叫端要求任何属于pset1一部分的使用权限都会失败。
For example, a method on the call stack might deny all of its callers a set of permissions named PSET1, such that any demand for a permission that is part of PSET1 fails for those callers.
例如,使用权限集上的要求会检查,是否所有呼叫堆叠中的呼叫端在使用权限集中有必要的使用权限。
For example, a demand on a permission set checks that all callers on the call stack have the necessary permissions in the permission set.
要求使用权限可以在程式码被允许执行后增加成功执行的机会。
Requesting permissions increases the likelihood that your code will run properly if it is allowed to execute.
这些要求只会造成执行阶段拒绝您的程式码存取组件,且执行阶段并不会因此赋予程式码超过其所应当获得的使用权限。
Requests only influence the runtime to deny permissions to your code and never influence the runtime to give more permissions to your code than has been granted.
要求覆写特定方法的衍生类别必须具有指定的识别或使用权限。
Require derived classes that override specific methods to have a specified identity or permission.
若要要求使用权限,您必须知道程序码会使用哪些资源和保护的作业,也必须知道保护这些资源和作业的是哪些使用权限。
To request permissions, you must know which resources and protected operations your code USES, and you must also know which permissions protect those resources and operations.
以下的程序码范例示范基本的使用权限要求。
The following code example demonstrates a basic permission request.
要求使用权限可以让管理员知道应用程序所需的最小使用权限需求,并据此调整安全性原则。
Requesting permissions lets administrators know the minimum permissions that your application needs so that they can adjust security policy accordingly.
您应该只要求您的程序码会用到的使用权限,而不要求过多的使用权限。
You should request only those permissions that your code needs, and no more.
要求,以确保所有直接和间接呼叫端具有需求指定的使用权限。
Demands to ensure that all direct and indirect callers have the permissions that the demand specifies.
适当地为您的使用权限要求自订使用权限。
Demand custom permission for your permission, where appropriate.
连结要求只会指定立即呼叫组件中的直接呼叫端在连结至您的程式码时,所要具备的使用权限。
The link demand specifies only the permissions direct callers in the immediate calling assembly must have to link to your code.
您应该将使用权限要求包含在存取受保护资源的应用程式中。
You should include permission requests in applications that access protected resources.
堆叠查核行程要求呼叫堆叠中的所有程式码都必须具有存取受保护资源的使用权限。
The stack walk requires that all code in the call stack has permission to access a protected resource.
购买一个月后发ticket要求索取2个月的免费使用权限官方会给你在账户自动增加2个月的freecredit !
Open a ticket with billing and request an account credit, and we'll provide you with a 2 month credit!
购买一个月后发ticket要求索取2个月的免费使用权限官方会给你在账户自动增加2个月的freecredit !
Open a ticket with billing and request an account credit, and we'll provide you with a 2 month credit!
应用推荐