Hello everybody
Sorry for my english in advance!
I'm working on a Windows Server 2012 R2 with PowerShell version 4.
I've got two different domains (domain1 & domain2). Domain1 trusts domain2 and therefore I can access with UNC path on all the folders in domain2 and check their security settings.
However when I try to check the security settings with the cmdlet
get-acl "\\domain2.local\dfs\company\folder1"
I receive only the path and the owner correctly. Access data are empty:
Path Owner Access
---- ----- ------
folder1 BUILTIN\Administrators
I also tried to invoke a command remotely on a server in the second domain with the following scriptline:
invoke-command -ComputerName "server1" -ScriptBlock {Get-Acl "\\domain2.local\dfs\company\folder1"
but I only receive the error
Cannot find path '\\domain2.local\dfs\company\folder1' because it does not exist.
The folder is accessible from domain1 and all the script lines can be run directly on a server in domain2.
The last thing I tried was with the cmdlet:
(get-item "\\domain2.local\dfs\company\folder1").getAccessControl()
but with the same empty result.
Am I doing something wrong, since I can perfectly view the security settings with the explorer?
I'm very thankful for every help.
Many thanks!
maragam