예제 #1
0
        internal override string GetSddlForm()
        {
            if (OpaqueLength != 0)
            {
                throw new NotImplementedException(
                          "Unable to convert conditional ACEs to SDDL");
            }

            string objType = "";

            if ((ObjectAceFlags & ObjectAceFlags.ObjectAceTypePresent) != 0)
            {
                objType = object_ace_type.ToString("D");
            }

            string inhObjType = "";

            if ((ObjectAceFlags & ObjectAceFlags.InheritedObjectAceTypePresent) != 0)
            {
                inhObjType = inherited_object_type.ToString("D");
            }

            return(string.Format(CultureInfo.InvariantCulture,
                                 "({0};{1};{2};{3};{4};{5})",
                                 GetSddlAceType(AceType),
                                 GetSddlAceFlags(AceFlags),
                                 GetSddlAccessRights(AccessMask),
                                 objType,
                                 inhObjType,
                                 SecurityIdentifier.GetSddlForm()));
        }
예제 #2
0
        internal override string GetSddlForm()
        {
            if (OpaqueLength != 0)
            {
                throw new NotImplementedException(
                          "Unable to convert conditional ACEs to SDDL");
            }

            return(string.Format(CultureInfo.InvariantCulture,
                                 "({0};{1};{2};;;{3})",
                                 GetSddlAceType(AceType),
                                 GetSddlAceFlags(AceFlags),
                                 GetSddlAccessRights(AccessMask),
                                 SecurityIdentifier.GetSddlForm()));
        }