Powershell - Export permissions for folder and share?
HI everyone from the following commands which one will export only folder level Security information.
Get-ChildItem "X:\Share" -recurse | Get-Acl | export-csv c:\djk\share_folder_permission.csv
or
Get-ChildItem "X:\Share" -recurse | Get-Acl -Exclude *.* | export-csv c:\djk\share_folder_permission.csv
or
Get-ChildItem "X:\Share" -recurse -Exclude *.* | Get-Acl | export-csv c:\djk\share_folder_permission.csv
or
Get-ChildItem "X:\Share" -recurse | Get-Acl -Exclude *.* | export-csv c:\djk\share_folder_permission.csv
or
Get-ChildItem "X:\Share" -recurse -Exclude *.* | Get-Acl | export-csv c:\djk\share_folder_permission.csv
or is there any options to restore permissions from this exported file to a new location
I am using SYSINTERNALS SOFTWARE ShareEnum which is fast for see shared folder permission but the export is not good as i want