Hi guys,
I will need some help with a to automate a challenge/response sequence when I try to SCP files from a server to another.
The scenario is like this :
After selecting in a script the option to send files via scp (case switch):
I get this output from linux term:
The authenticity of host 'healthcares8300 (10.100.255.3)' can't be established.
RSA key fingerprint is 10:2b:c9:4c:15:19:3c:cc:52:06:87:7d:4c:b6:0a:0f.
Are you sure you want to continue connecting (yes/no)? yes
Failed to add the host to the list of known hosts (/var/home/defty/.ssh/known_hosts).
This system is restricted solely to authorized users for legitimate business
purposes only. The actual or attempted unauthorized access, use or modifications
of this system is strictly prohibited. Unauthorized users are subject to
company disciplinary procedures and or criminal and civil penalties under state,
federal or other applicable domestic and foreign laws.
The use of this system may be monitored and recorded for administrative and
security reasons. Anyone accessing this system expressly consents to such
monitoring and recording, and is advised that if it reveals possible evidence
of criminal activity, the evidence of such activity may be provided to law
enforcement officials.
All users must comply with all corporate instructions regarding the protection
of information assets.
Challenge: 000-4005 Product ID: 7000175677
Response:
The output of this response should be
~asg init 000-4005 7000175677
if this doesn´t work the script should send
~asg init 000-4005 7000175677 -K1 then if it doesnt work.
~asg init 000-4005 7000175677 -K2 then if it doesnt work.
~asg init 000-4005 7000175677 -K3 ....
Bare in mind the init is the login i am using to login to the server and this function would be part of another script that i will have to integrate.
ANY idea on how to do this?
Thanks for your support,
Fran