Automatic acceptance of a TLS (self-signed) certificate
Hello! I'm trying to connect to ftp server using command prompt. When I connect it requires to accept certificate manually (press (Y),(N) or (C)copy key ). I need it to be accepted automatically without my participation. I've read some topics about that and saw such commands as "certificate-*" etc. But I can't do that automatically. Here is my code:
@echo off
"C:\Program Files (x86)\WinSCP\WinSCP.com" ^
/log="C:\Users\skolnieks\Desktop\WinSCP.log" /ini=nul ^
/command "open ftpes://user1:12345@192.168.12.28/" ^
"lcd C:\Users\skolnieks\Desktop" ^
"cd /" ^
"put *.xlsx" ^
"exit"
set WINSCP_RESULT=%ERRORLEVEL%
if %WINSCP_RESULT% equ 0 (
echo Success
) else (
echo Error
)
exit /b %WINSCP_RESULT%
@echo off
"C:\Program Files (x86)\WinSCP\WinSCP.com" ^
/log="C:\Users\skolnieks\Desktop\WinSCP.log" /ini=nul ^
/command "open ftpes://user1:12345@192.168.12.28/" ^
"lcd C:\Users\skolnieks\Desktop" ^
"cd /" ^
"put *.xlsx" ^
"exit"
set WINSCP_RESULT=%ERRORLEVEL%
if %WINSCP_RESULT% equ 0 (
echo Success
) else (
echo Error
)
exit /b %WINSCP_RESULT%