Solved

ssh login

Posted on 2011-09-26
2
289 Views
Last Modified: 2012-06-21
I am writing a script to do a Cisco Switch backup.

I already have Cgwin installed.

I need help with the batch script syntax.

ssh ciscosw1
 echo username admin
 echo password admin
copy run tftp 192.168.1.1
send return

 
0
Comment
Question by:alisafia
2 Comments
 
LVL 9

Accepted Solution

by:
parparov earned 500 total points
ID: 36707507
You cannot echo a password into ssh - it is not read from standard input.

You can do it via Expect or through existing Perl/Python ssh wrappers only.
0
 
LVL 1

Author Comment

by:alisafia
ID: 36707539
I thought so too. Thanks.
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
robocopy for today files 14 88
DOS expert? 3 44
edit command in Command Prompt through Windows 10 2 44
network copying issue 4 39
One of my most closely kept secrets is revealed in this discussion How to output text on the same line This question was recently posted in EE by Simon336697 (http://www.experts-exchange.com/Programming/Languages/Scripting/Shell/Batch/Q_2459…
TOMORROW TOMORROW.BAT is inspired by a question I get asked over and over again; that is, "How can I use batch file commands to obtain tomorrow's date?" The crux of this batch file revolves around the XCOPY command - a technique I discovered w…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now