Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

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)


Topic review


Hi Martin,

Problem solved!
After re-reading:
If pattern !P is not used, and password is known, parameter -pw <password> is automatically added to the command.

So, I removed the "-pw !P" from the pattern and the problem is gone!

Thank you!
WinSCP is a great software. ;)

Hi Martin,

More info about the trouble:

- In the configuration of WinSCP I have this in Preferences/Integration/Applications:
External applications --> PuTTY/Terminal client path:
"C:\Portable\PortableApps\PuTTY\PuTTY-mod.exe -cmd "cd '!/'" -P !# !U@!@ -pw !P"

Previous to this I use "-pass" instead of "-pw" as this MOD uses both values. However, now the client shows a modal window with the error: "option '-pw' requires an argument".

So the problem is that: when the "!P" value is empty, in this case the previous "-pw" string needs to be removed.

I suggest to support some kind of "optional if empty" in the patterns. Like for example something like this:
"C:\Portable\PortableApps\PuTTY\PuTTY-mod.exe -cmd "cd '!/'" -P !# !U@!@ {-pw !P}"
Where "{...}" indicates "only when the value is not empty".

You agree?

Hi Martin,

I feel I found the problem:

I changed the call to the PUTTY.EXE with a PUTTY.BAT that prints the parameters passed to the binary. And I see that when the password is empty you still pass the parameter "-pass" to the call. This generates a problem with the PuTTY Mod that I use (yes, perhaps you don't see the problem because a different PuTTY client). So the solution can be:

* If "PASSWORD" is empty then don't add "-pass" to the commandline call.

In this case the client PuTTY will ask for the password.

Please, can you include this fix?
Thank you!

Hi Martin,

I'm sorry if I misinterpreted your request!

I try add more info:

- Version used: WinSCP 5.13.4 (Build 8731), in portable mode (INI files only).
- After point (4) the program closes, so no error, no log, nothing.
- Session bookmark:
File protocol: SCP
Host name: 192.168.1.xx (here my target server)
Port number: 22
User name: root
Password: _____ (empty)
- If I set the Password in the bookmark and I save the session, then it works!

Please, let me know if I can enable some GLOBAL LOGGING to share it (session logging doesn't show anything as the session doesn't starts).
I don't understand why the problem isn't reproducible in your case.

Thank you for your support!

Sorry, but if it were that easy to reproduce, I would not ask you for details. Obviously, what you describe works just fine for me (and others).
What happens after 4.? Do you get any error message? Or nothing happens at all?

Hi Martin,

An screenshot is useless, as you can see only the right panel.

However, if you need more info, I try to describe how to reproduce the bug:

0. Start with a WinSCP install with some site bookmarks registered; and with PuTTY installed too.
1. Open WinSCP.EXE
2. In the "Login" window you select one site bookmark that has all session data (hostname, username, etc.) but doesn't have a Password (the value is empty), and the session doesn't have any certificate or other mode configured to authenticate.
3. Right click over this bookmark and in the new "Site" window select the second entry "Open in PuTTY Ctrl+P".
4. Then the WinSCP program/process closes and exits.

But, if you repeat it with a site bookmark with the password stored, then in this case the session is stablished.

This is a real bug!
Please, fix it.


Re: Login Window: Right button "Open in PuTTY" doesn't work

Can you please share few screenshots and more information to document the issue?

Login Window: Right button "Open in PuTTY" doesn't work


When using the Login Window (at start) if you select one of the bookmarks and try with the right button "Open in PuTTY" it doesn't work!

In fact, it works if all data is stored... even the password. If the password is missing then the connection fails.

To correct the bug one solution can be: Check first all parameters (username, password, address, port, directory, etc.) if someone is missing then try to connect with some default value; and for sensible data (like the password), leave the option to enter it.

I hope you can fix it soon.
Thank you!