0
I am on a Windows computer, say "LocalA". I manually RDP into a remote server, say "RemoteB". From RemoteB I run a script which does a bunch of things and at the end it should copy/send files from RemoteB to the machine from which I remoted, i.e. LocalA. How can the copy part be achieved using powershell or similar program?
Basically, I want to do something like this in powershell (or using any external command line tool):
# pseudo syntax
Copy -source RemoteB/C:/foo.txt -target LocalA/C:/foo.txt
# run from RemoteB
However, LocalA and RemoteB are not on any shared network or domain. They are totally unrelated machines. All I have with me is IP of RemoteB, the username and password.
I can of course manually pull a file from RemoteB to LocalA, using Ctrl+C, Ctrl+V. Basically I am trying to automate the manual copying.