CryptoKeySecurity.RemoveAccessRule(CryptoKeyAccessRule) 方法
定义
从与此 CryptoKeySecurity 对象关联的自由访问控制列表 (DACL) 中移除与指定的访问规则具有相同安全性标识符和访问掩码的访问规则。Removes access rules that contain the same security identifier and access mask as the specified access rule from the Discretionary Access Control List (DACL) associated with this CryptoKeySecurity object.
public:
bool RemoveAccessRule(System::Security::AccessControl::CryptoKeyAccessRule ^ rule);
public bool RemoveAccessRule (System.Security.AccessControl.CryptoKeyAccessRule rule);
override this.RemoveAccessRule : System.Security.AccessControl.CryptoKeyAccessRule -> bool
Public Function RemoveAccessRule (rule As CryptoKeyAccessRule) As Boolean
参数
- rule
- CryptoKeyAccessRule
要移除的访问规则。The access rule to remove.
返回
如果访问规则已成功移除,则为 true;否则为 false。true if the access rule was successfully removed; otherwise, false.
注解
通过使用可能添加访问控制规则的复杂算法来完成访问删除。Access removal is accomplished by using a complex algorithm that might add access control rules in addition to removing them.
false如果与访问规则关联的继承规则太复杂,而使删除算法成功,则此方法将无法删除访问规则,并返回。This method fails to remove the access rule and returns false if the inheritance rules associated with the access rule are too complex for the removal algorithm to succeed.