public sealed class WindowsSecurityDescriptor : IEquatable<WindowsSecurityDescriptor> An immutable self-relative Windows security descriptor that compares by its binary form.
Remarks
The binary form is kept exactly as supplied or read, so owner, group, ACE order and inheritance flags are preserved. Use WindowsSecurityDescriptor.ToRawSecurityDescriptor to inspect or edit it with the Security.AccessControl types, and WindowsSecurityDescriptor.From to convert the result back.
Properties
Sddl
public string Sddl { get; } The descriptor in Security Descriptor Definition Language, including every section it contains.
Methods
Equals
public bool Equals(WindowsSecurityDescriptor? other) Inherits documentation from IEquatable.Equals.
From
public static WindowsSecurityDescriptor From(RawSecurityDescriptor descriptor) Creates a descriptor from the binary form of descriptor. Later changes to it are not reflected.
FromBinaryForm
public static WindowsSecurityDescriptor FromBinaryForm(ReadOnlySpan<byte> binaryForm) Creates a descriptor from a self-relative binary form, which is copied.
Exceptions
ArgumentExceptionThe bytes are not one complete self-relative security descriptor.
FromSddl
public static WindowsSecurityDescriptor FromSddl(string sddl) Creates a descriptor from SDDL.
Exceptions
ArgumentExceptionThe SDDL is not a valid security descriptor.
ToRawSecurityDescriptor
public RawSecurityDescriptor ToRawSecurityDescriptor() Returns a new RawSecurityDescriptor for this descriptor on every call.
Operators
operator !=
public static bool operator !=(WindowsSecurityDescriptor? left, WindowsSecurityDescriptor? right) Compares two descriptors by their binary form.
operator ==
public static bool operator ==(WindowsSecurityDescriptor? left, WindowsSecurityDescriptor? right) Compares two descriptors by their binary form.