2

So I have the following "problem". I have a work laptop I want to ssh into my workstation. However, due to security measures I have to first log into a jump host before being able to login.

ssh -J -A username@jumphost username@workstation-name

This is fine, however this means I have to input my password twice; once for the jump host and one for my computer.

I can not store any ssh keys on the jump host as it is locked down, however I can store keys on my workstation and laptop.

Is there any way I can manage to login with just inputting a single password and do the rest with validated keys?

1
  • (1) Do you mean "password" (to authenticate) or "passphrase" (to unlock your key)? If unsure, see this answer. The passphrase and the password are different concepts. You wrote "password" but in the context of keys maybe you mean "passphrase". (2) "I can not store any ssh keys on the jump host as it is locked down" – But is your public key already in the authorized_keys there? Aug 12 at 17:45

1 Answer 1

3

You should be able to do that with AgentForwarding. You first need to add your local key to the ssh-agent, and then forward it with ssh -oForwardAgent=yes -J jmpserver workstation. Probably you are missing the first step.

Although, the option must be enabled in your jump server and you may have to setup correctly your local client to share the keys. The very verbose flag (-vv) of ssh may help to determine if it is working or not.

See the GitHub tutorial for some instructions.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.