Thanks. That helped. Using SFTP::Foreign I get public key authentication and I can put the file to the remote server. I am getting an error on the put even though the file makes it to the destination: "Couldn't setstat remote file (fsetstat): SSH_FILEXFER_ATTR_PERMISSIONS". I'll do some research and see if I can figure out it out.