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

consistency

push

if you use a lot of different keys, it is really important having this feature.

currently, after a network disconnect (computer hibernation), i have to enter all passphrases for the keys again (on all winscp connections and all putty sessions (using reconnect)).

would be great having winscp let pageant load the key, so it stays in memory after hibernation.
Petr

+1
consistency

martin wrote:


OK, so you have to specify the key in the session. Because in general, you do not have to. WinSCP tries to use any key loaded into pageant.

oh i see, i used to define my key in the "private key file" field of the winscp session. maybe you just can add the functionality with calling the pageant, if a key is specified in this field.
or add a checkbox force loading with pageant.

thanks for adding to the bug tracker
martin

consistency wrote:

i don't know how it work exactly in tortoise git, would have to look into the source
but i think it is quite straight:
you have the path to the key saved in your winscp session, so if the session is started a call like "exec(pageant sessionKeyNameWithPath)" sould be enough.
if you exec pageant like this, it will spawn its own password dialog and will keep the key including password in memory until the system is restarted. i don't know how you invoke the key, but i think you invoke it internal in winscp, rather then just sending the path to pageant.

OK, so you have to specify the key in the session. Because in general, you do not have to. WinSCP tries to use any key loaded into pageant.

This request has been added to the tracker:
https://winscp.net/tracker/738
consistency

i don't know how it work exactly in tortoise git, would have to look into the source
but i think it is quite straight:
you have the path to the key saved in your winscp session, so if the session is started a call like "exec(pageant sessionKeyNameWithPath)" sould be enough.
if you exec pageant like this, it will spawn its own password dialog and will keep the key including password in memory until the system is restarted. i don't know how you invoke the key, but i think you invoke it internal in winscp, rather then just sending the path to pageant.
martin

consistency wrote:

would be great to have such a feature like in tortoisegit with putty. if i start a session where i need my key pageant is startet and prompts me for the passphrase. if i enter it, it is directly stored in pageant. no fiddeling around with batch files to start pageant and winscp with the key.

How does tortoisegit tell that key is needed for that session?
consistency

would be great to have such a feature like in tortoisegit with putty. if i start a session where i need my key pageant is startet and prompts me for the passphrase. if i enter it, it is directly stored in pageant. no fiddeling around with batch files to start pageant and winscp with the key.
martin

Re: Automatically start Agent

xmt wrote:

Wouldn't that mean I'd need to enter the passphrase every time I wanted to log in? One of the main benefits of using an agent is that I only have to do that once.

That's true.

You can as well start both WinSCP and Pageant from one batch file.
xmt

Re: Automatically start Agent

martin wrote:

You can configure WinSCP to use the key directly, without using pageant. Wouldn't it be a solution?

Wouldn't that mean I'd need to enter the passphrase every time I wanted to log in? One of the main benefits of using an agent is that I only have to do that once.
martin

Re: Automatically start Agent

You can configure WinSCP to use the key directly, without using pageant. Wouldn't it be a solution?
xmt

Automatically start Pageant

Hey,

Would it be possible to add an option that if WinSCP can't find Pageant running when "Attempt authentication using Pageant" is enabled, it will start it automatically?

This would be really handy for when I sometimes forget to load up Pageant. Currently one has to cancel the connection, and then reconnect once Pageant has been started.

There would need to be a way to specify the command to execute in order to start the agent, since the only way I've found to make Pageant "remember" keys is to pass them as arguments.

Currently the best solution to this I've come up with is to create two additional shortcuts to Pageant, of the form...
"C:\Program Files (x86)\WinSCP\PuTTY\pageant.exe" "C:\Users\xxx\Documents\key.ppk" -c "C:\Program Files (x86)\WinSCP\WinSCP.exe"

...one for WinSCP and one for PuTTY, and then the icon can be changed to make the shortcut look like the real deal.

Unfortunately this makes key management a bit of a faff, not to mention it means I now *have* to enter all my passphrases into Pageant even if I wasn't planning to log into a server which required a key.

Thanks for your time.

Ps. Not sure if I should be asking the PuTTY people about this instead, since I'd also really like PuTTY to do this too.