Post a reply

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

ryu_1337

Connecting to SFTP through PowerShell

Hi All,

We are rewriting our SFTP push script from .bat to .ps1.

However, we want to "encrypt"/secure our authentication. At the moment we have blank passwords in the script like:
    "open sftp://username:password@sftpName:port/ -hostkey=`"`"ssh-ed25519 fingerprint`"`""

We have tried doing saving the site then opening it:
    "open sftpSitename" `
    "put D:\file\* /filearea/outbound/" `
    "exit"

But it isn't able to find the site. We are also OK with using a credential.xml.

Has anyone been able to get to work?