This comes up with surprising frequency:
I am on a server or other machine via ssh. I want to scp or rsync some files back to my client machine. The problem is that I am behind a firewall and I don't have a port mapped to port 22 on my machine.
It would be great if I could somehow alias the machine that I am connected from in an scp or rsync command something like:
scp fileToBeTransferred LOCALMACHINE:~/temp/
My current process is to issue the command from my local machine (not in an ssh session). It would just be so much faster to be able to issue the scp command from the server because I'm already in the correct directory, I can use file completion, and my credentials are already verified.
My client machine is almost always a Mac running Mountain Lion if that makes a difference.