IIdentity
interface exposes AuthenticationType
property which i would like to take into account because things are bit different if a user logs on with x509 or basic username/password auth, you know:
[PrincipalPermission(SecurityAction.Demand, Role = "BigBoss", AuthenticationType="basic")]
protected static void DoSomething() {}
But i can't. Moreover, both PrincipalPermission
and PrincipalPermissionAttribute
are sealed (thanks guys) so i cannot add the functionality I need. Is this for some special reason or just a design flaw? Any ideas how to workaround?