Topic "Unable to authenticate SFTP Credentials using Batch Script"

Author Message
sundar2013
[View user's profile]

Joined: 2016-04-04
Posts: 6
WINSCP - Version 5.12
Version of Windows - Windows 7
Transfer Protocol - SFTP
Error : Disconnected: Unable to authenticate

I am connecting SFTP Server using username and password directly in the batch script, but it is not working. I am not using host key and I am using the password directly.

I able to connect to my SFTP server using Graphical user interface with same credentials.

The Batch Script is mentioned below.

option batch abort
option confirm off
open sftp://username:password@Server Name
exit

Password had characters like +-. I don't know this will cause the issue.

Error :

. 2016-05-13 14:39:02.283 Using stored password.
! 2016-05-13 14:39:02.315 Further authentication required
. 2016-05-13 14:39:02.316 Further authentication required
. 2016-05-13 14:39:02.318 Attempting keyboard-interactive authentication
. 2016-05-13 14:39:02.347 Prompt (6, SSH server authentication, Using keyboard-interactive authentication., Enter password: )
. 2016-05-13 14:39:02.349 Disconnected: Unable to authenticate

Please help me to resolve it.

Thanks.
Sundaramurthy J.
winscp.log (4.65 KB) [Download]

Description: (none)

Advertisements
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Please attach a log file from GUI for comparison.

You also better use the latest version of WinSCP.
sundar2013
[View user's profile]

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

Herewith I am attaching the log file from GUI WINSCP.

From GUI if I enter the password directly it is asking for the password again & again during authentication. If I check the option to save the password then it won't ask and started working in GUI.

I am doubting that through script password is not storing correctly.

Please help me.

Regards,
Sundaramurthy J.
Winscp _GUI.log (6.77 KB) Private file

Description: GUI Log File for Comparision

sundar2013
[View user's profile]

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

I have resolved the issue. Password has special characters that caused the problem. I have converted special characters to Hexa that solved the problem.

Thanks for your help.

Regards,
Sundaramurthy J.
martin
[View user's profile]
Site Admin
Joined: 2002-12-10
Posts: 24530
Location: Prague, Czechia
Thanks for your feedback.
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