Welcome to the VanDyke Software Forums

Join the discussion today!


Go Back   VanDyke Software Forums > General

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 03-14-2013, 12:25 PM
dustin.hartman dustin.hartman is offline
Registered User
 
Join Date: Apr 2012
Posts: 7
Smile How to send username\pass inside jump ssh session

I know this question is already answered, I tried searching for awhile but couldn't find it, so please forgive me for re-asking this

Environment: We use Remedy which contains all of our customer's device information (ip\username\password, etc...). We have Remedy setup so that when we hit a button it automatically ssh's into the customers device, using the following syntax:

"C:\Program Files\VanDyke Software\SecureCRT\SecureCRT.exe" /T /SSH2 #IPADDRESS# /L #Username# /PASSWORD #password#

Which worked great. Then the compliance folks said that we had to use a jump box to ssh through (which logs everything we do). The server allowed socks, so we just setup our securecrt to use the Socks5 Firewall proxy by default for all connections, which also worked great.

Unfortunately our company changed the software we use for compliance logging and this new software doesnt allow socks proxy. Instead we have to ssh to this jump server and from there we can ssh out to the customer devices.

Goal: I would like to be able to restore automation so that we can click a button in remedy that will automatically launch SecureCRT, ssh to the jump server, and then ssh to the customer device, all automagically ;-D

Question: I know that I could define a script in the command line option, but since we have thousands of customer devices, all with unique ip\username\passwords we couldnt have a script on our desktops that contained all of that data. Is there a way to send two ssh connect statements via command-line option? For example:
SecureCRT.exe /SSH2 #JumpServerIP# /L #Username# /PASSWORD #password# /SSH2 #CustomerDeviceIP /L #Username# /PASSWORD #password#

If not, another idea I was thinking about was to create a locallyh saved session which ssh's into the jump server. Then in the command-line options tell SecureCRT to launch that SSH session and then send then ssh to the customer device, but I could not figure out that syntax. For example it would be like:
SecureCRT.exe /S SavedJumpSession #CustomerIP# /L #Username# /PASSWORD #password#

If not, the only other idea I could think of would be to use the /ARG option to define variables that a local script was using, but I saw in previous forum posts that this option wasnt supported yet, though that was an old post. So for example something like:
SecureCRT.exe /ARG username=admin /ARG password=abc123 /ARG ip=1.2.3.4 /Script script.vbs and in the script it has two ssh statements, one that connects to the ssh jump server, another that connects to the customer device which references the variables defined in the command-line syntax.

If not, Fairy Dust?

Sorry for the long post, we love you guys, SecureCRT saves us SOOO much time (and money). I know we can do this, I just need a little push in the right direction.

Thanks again!
Reply With Quote
 

Tags
automate , expect , remedy , ssh


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -6. The time now is 04:47 PM.