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

martin

Re: Special Characters in Password

You should not need to do anything with the password in the .NET assembly. Just assign it as is. Of course, except for symbols which have special meaning in your programming language.

If you have problems, try to enable password logging by calling session.AddRawConfiguration("Logging\LogSensitive", "1") and inspect the log.
See https://winscp.net/eng/docs/rawconfig
Confused

Special Characters in Password

I have been given a rather difficult password by one of our suppliers to sftp from an offsite server.

I am trying to use assembly and powershell to connect and I have tested successfully to our own server but looking at the debug log shows its not escaping the special characters in the password - can anyone help?

For arguments sake the password (not the real one) is Tynf^&f34%cvBN

when viewed in the debug log this is being changed to Tynf%5E%26f34%25cvBN

I have tried wrapping the password in double quotes ("Tynf^&f34%cvBN"), single quotes, ive tried replacing the special characters with %25 as in session url but this just translates the % character and the number.

I'm using winscp version 5.7.7.6257 and have been browsing through posts on here for hours so any help is appreciated.