Topic "Pass string for "Further authentication required" in script"

Author Message
Baseline

Guest


Hi,

(Using V4.3.5 on Win2k3. Protocol when connected via GUI is SFTP-3.)

We use WinSCP successfully to connect to 1 site and now have a requirement to use it to connect to another.

For this second site, we store the private key in Pageant and that authenticates fine. After that step, it asks for a second password while displaying the message "Further authentication required" (as per attachment 1.png). If I type the password into the GUI it works fine. The second password is a requirement of the people we are connecting to.

For the purpose of this connection, we need to script it to schedule it to run every 90 mins, 24 hours a day. My script currently looks like this:
The command line:
"C:\Program Files\WinSCP\WinSCP.com" "<SITE NAME>" /script=c:\<SITE NAME>\Scripts\test.txt

The script (test.txt):
# Download Today's 1830 FP File
get %date_dd%%date_mm%%date_yy%* C:\<SITE NAME>\Download\%date_dd%%date_mm%%date_yy%n.DAT
# Disconnect
Close
# Exit
Exit

When I run this, I get the message in attachment 2.png. Again, if I type in this password it connects.

However, since there is a requirement to automate it (as we don't currently work 24 hours a day) I'm looking for a way to pass the second password through as part of the script (I know the password will be shown in clear text in the script file). I've had a look in the scripting guides and can't see anything (I don't read C# so I can't tell if it's possible in .NET Assembly or not).

Any help would be much appreciated.

Many thanks
2.png (7.51 KB)

Description: (none)

2.png

1.png (7.56 KB)

Description: (none)

1.png

Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24555
Location: Prague, Czechia
Have you tried saving the password in the stored session you are opening?
Baseline

Guest


Hi

That worked - thanks very much!

I didn't think to try that as I thought it would overrule the private key and try to authenticate by password.

I'll take a look at the 'open' command and adjust my script as appropriate.

Many thanks
Andy
sundar2013
[View user's profile]

Joined: 2016-04-04
Posts: 6
Hi Andy,

What change you did in the Script to fix this issue.

Can you please let me know, because I am also facing the same problem.

Thanks.
Sundaramurthy J.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24555
Location: Prague, Czechia
Show us your script and log.
Advertisements

You can post new topics in this forum






Search Site

What is WinSCP?

It is award-winning SFTP client, SCP client, FTPS client and FTP client integrated into one software program for file transfer to FTP server or secure SFTP server. [More]

And it's free!

Donate

About donations

$9   $19   $49   $99

About donations

Recommend

WinSCP Privacy Policy

WinSCP License