public static string ToString(PrincipalIdentifier principalIdentifier) { switch (principalIdentifier.Kind) { case PrincipalIdentifierKind.Claim: return(ToString((ClaimPrincipalIdentifier)principalIdentifier)); case PrincipalIdentifierKind.Role: return(ToString((RolePrincipalIdentifier)principalIdentifier)); case PrincipalIdentifierKind.Windows: return(ToString((WindowsPrincipalIdentifier)principalIdentifier)); case PrincipalIdentifierKind.X509: return(ToString((X509PrincipalIdentifier)principalIdentifier)); default: return(string.Format(CultureInfo.InvariantCulture, "Unknown PrincipalIdentifier {0}", principalIdentifier.Kind)); } }
public UserGroupMembershipFact( PrincipalIdentifier user, PrincipalIdentifier group ) : base( "GroupMembership", user, group) { if (user == null) { throw new ArgumentNullException("user"); } if (group == null) { throw new ArgumentNullException("group"); } this.User = user; this.Group = group; }
public AllowedAce(PrincipalIdentifier principal) : base(AceType.Allowed, principal) { }
public AllowedAce(PrincipalIdentifier principal, AccessMask accessMask) : base(AceType.Allowed, principal, accessMask) { }
public ResourceAccessFact( PrincipalIdentifier resource, PrincipalIdentifier module, PrincipalIdentifier group, IntegerIdentifier from, IntegerIdentifier to, IntegerIdentifier dayOfWeek, VerbIdentifier accessMode, IntegerIdentifier priority ) : base( "ResourceAccess", resource, module, group, from, to, dayOfWeek, accessMode, priority) { if (resource == null) { throw new ArgumentNullException("resource"); } if (module == null) { throw new ArgumentNullException("module"); } if (group == null) { throw new ArgumentNullException("target"); } if (from == null) { throw new ArgumentNullException("from"); } if (to == null) { throw new ArgumentNullException("to"); } if (dayOfWeek == null) { throw new ArgumentNullException("dayOfWeek"); } if (accessMode == null) { throw new ArgumentNullException("accessMode"); } if (priority == null) { throw new ArgumentNullException("priority"); } this.Resource = resource; this.Module = module; this.Group = group; this.From = from; this.To = to; this.DayOfWeek = dayOfWeek; this.AccessMode = accessMode; this.Priority = priority; }
public UserGroupMembershipFact( PrincipalIdentifier user, PrincipalIdentifier group ) : base("GroupMembership", user, group) { if (user == null) { throw new ArgumentNullException("user"); } if (group == null) { throw new ArgumentNullException("group"); } this.User = user; this.Group = group; }
public ResourceAccessFact( PrincipalIdentifier resource, PrincipalIdentifier module, PrincipalIdentifier group, IntegerIdentifier from, IntegerIdentifier to, IntegerIdentifier dayOfWeek, VerbIdentifier accessMode, IntegerIdentifier priority ) : base("ResourceAccess", resource, module, group, from, to, dayOfWeek, accessMode, priority) { if (resource == null) { throw new ArgumentNullException("resource"); } if (module == null) { throw new ArgumentNullException("module"); } if (group == null) { throw new ArgumentNullException("target"); } if (from == null) { throw new ArgumentNullException("from"); } if (to == null) { throw new ArgumentNullException("to"); } if (dayOfWeek == null) { throw new ArgumentNullException("dayOfWeek"); } if (accessMode == null) { throw new ArgumentNullException("accessMode"); } if (priority == null) { throw new ArgumentNullException("priority"); } this.Resource = resource; this.Module = module; this.Group = group; this.From = from; this.To = to; this.DayOfWeek = dayOfWeek; this.AccessMode = accessMode; this.Priority = priority; }