You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hrmmm. What do you think about a -MapDrives argument to anything that uses remote Test-Path's, something like "New-PSDrive –Name $RandName –PSProvider FileSystem –Root “\SERVER\share” . Could also supply alternate credentials.
The version_2.0 branch just got a push to hopefully support this- Get-GptTmpl, Get-GroupsXML, Get-NetGPOGroup, Find-GPOComputerAdmin, Find-GPOLocation and Get-DomainPolicy nowhave a "-UsePSDrive" switch that should automate the creation of a randomized session-only PSDrive for the mounting of locations to search for policy files. Let me know if this does/doesn't work, and I'll close the issue when it's a confirmed fix.
Also, Find-InterestingFile and Invoke-FileFinder received the flag as well, along with a -Credential option to specify alternate credentials for file searching. Again, minimally tested, so let me know what breaks :)
Using
runas /netonly
technique, for some reason Test-Path returns false unless you have the drive mapped?e.g. net use * \target.com
Then Test-Path will start returning true...
The text was updated successfully, but these errors were encountered: