다음을 통해 공유


ISecurityDescriptorCmdletProvider.NewSecurityDescriptorFromPath Method

Definition

Creates a new empty security descriptor of the same type as the item specified by the path. For example, if "path" points to a file system directory, the descriptor returned will be of type DirectorySecurity.

public:
 System::Security::AccessControl::ObjectSecurity ^ NewSecurityDescriptorFromPath(System::String ^ path, System::Security::AccessControl::AccessControlSections includeSections);
public System.Security.AccessControl.ObjectSecurity NewSecurityDescriptorFromPath (string path, System.Security.AccessControl.AccessControlSections includeSections);
abstract member NewSecurityDescriptorFromPath : string * System.Security.AccessControl.AccessControlSections -> System.Security.AccessControl.ObjectSecurity
Public Function NewSecurityDescriptorFromPath (path As String, includeSections As AccessControlSections) As ObjectSecurity

Parameters

path
String

Path of the item to use to determine the type of resulting SecurityDescriptor.

includeSections
AccessControlSections

The sections of the security descriptor to create.

Returns

A new ObjectSecurity object of the same type as the item specified by the path.

Applies to