You can use something like tar to and pipes to do this (as long as you have tar available on both hosts). For example, to copy root's homedir over to another host:
sudo tar c -C / root | ssh remote_host tar xv -C some/location/to/unpack/into
(assuming gnu tar for -C support, it can be done without it using '()' but it's trickier) and of course, you can do the sudo on the remote end:
tar c -C my_trojan_files . | ssh remote_host sudo tar xv -C /usr/bin
The trick here is that, in both cases, tar is emitting the archive to STDOUT, which is being piped into the command running on the remote host via ssh. You can do this with cpio and dump/restore as well.
sudo su 2? – maco Oct 22 '10 at 21:36