The rights associated with an application that are granted to an account.
Esempio n. 1
0
        /// <summary>
        /// Updates the access right set with the permissions for the specified object.
        /// </summary>
        private void UpdateAccessRightSet(
            SecuredObject objectToSecure,
            IdentityReference identity,
            bool denied,
            Dictionary <string, SecuredObjectAccessRights> setToUpdate)
        {
            SecuredObjectAccessRights accountRights = null;

            if (!setToUpdate.TryGetValue(identity.Value, out accountRights))
            {
                accountRights          = new SecuredObjectAccessRights();
                accountRights.Identity = identity;
                setToUpdate.Add(identity.Value, accountRights);
            }

            if (denied)
            {
                accountRights.DeniedObjects |= objectToSecure;
            }
            else
            {
                accountRights.AllowedObjects |= objectToSecure;
            }
        }
        /// <summary>
        /// Updates the access right set with the permissions for the specified object.
        /// </summary>
        private void UpdateAccessRightSet(
            SecuredObject objectToSecure,
            IdentityReference identity,
            bool denied,
            Dictionary<string, SecuredObjectAccessRights> setToUpdate)
        {
            SecuredObjectAccessRights accountRights = null;

            if (!setToUpdate.TryGetValue(identity.Value, out accountRights))
            {
                accountRights = new SecuredObjectAccessRights();
                accountRights.Identity = identity;
                setToUpdate.Add(identity.Value, accountRights);
            }

            if (denied)
            {
                accountRights.DeniedObjects |= objectToSecure;
            }
            else
            {
                accountRights.AllowedObjects |= objectToSecure;
            }
        }
Esempio n. 3
0
 public Item(SecuredObjectAccessRights accessRights, bool denied)
 {
     Identity = accessRights.Identity;
     Denied   = denied;
     Rights   = (denied) ? accessRights.DeniedObjects : accessRights.AllowedObjects;
 }
 public Item(SecuredObjectAccessRights accessRights, bool denied)
 {
     Identity = accessRights.Identity;
     Denied = denied;
     Rights = (denied) ? accessRights.DeniedObjects : accessRights.AllowedObjects;
 }