bug #2096: Preserve remotes permissions. Adds -p flag to scp as suggested by Steffen Neumann

(cherry picked from commit e9f720a6bb1d3e4abbae6389c529e36e6247628e)