X
Xia Wei
Hi group,
I'm trying to use CAS in my project these days. And I find a problem, for
example:
[PrincipalPermission(SecurityAction.Demand,Role="Xxx")]
static void Exec()
{}
Then the caller of this method should be a member of role "Xxx". If I define
the method like this:
[PrincipalPermission(SecurityAction.Demand,Role="Xxx")]
[PrincipalPermission(SecurityAction.Demand,Role="Yyy")]
static void Exec()
{}
Then the caller should be a member of role "Xxx", or "Yyy". My question is,
how to define the PrincipalPermissionAttribute, and it needs both "Xxx" role
and "Yyy" role.
I've tried to define like this:
[PrincipalPermission(SecurityAction.Demand,Role="Xxx,Yyy")]
but failed.
Is it possible in CAS?
Thanks,
Sunmast
I'm trying to use CAS in my project these days. And I find a problem, for
example:
[PrincipalPermission(SecurityAction.Demand,Role="Xxx")]
static void Exec()
{}
Then the caller of this method should be a member of role "Xxx". If I define
the method like this:
[PrincipalPermission(SecurityAction.Demand,Role="Xxx")]
[PrincipalPermission(SecurityAction.Demand,Role="Yyy")]
static void Exec()
{}
Then the caller should be a member of role "Xxx", or "Yyy". My question is,
how to define the PrincipalPermissionAttribute, and it needs both "Xxx" role
and "Yyy" role.
I've tried to define like this:
[PrincipalPermission(SecurityAction.Demand,Role="Xxx,Yyy")]
but failed.
Is it possible in CAS?
Thanks,
Sunmast