passwordless cisco router SSH login

Posted on 2011-10-06
Last Modified: 2012-05-12

How do I setup passwordless SSH authentication to login to my cisco router? Do I need k9 IOS?

Question by:chainfear
    LVL 36

    Accepted Solution

    you need a fairly up to date IOS and it needs to have 3DES support
    LVL 17

    Expert Comment

    Passwordless SSH is not supported since any username created needs to have a password.

    Best regards


    Author Comment

    If I want to write a script that do something with cisco router/switch,do I need to put the password in clear text? Is there anyway to avoid that? This is why I am asking for passwordless SSH into a router.

    Thanks for all the efforts
    LVL 17

    Assisted Solution

    Yes you do. If you are concerned with using a password that can be seen in a script, you should be even more concerned with allowing anyone login to your device without using a password.

    If possible, make sure that your script is not readable by anyone tha shouldnt be allowed to see the password.

    LVL 36

    Expert Comment

    Once you have setup key based auth, your connection would be in the form of user@host, no password is used.

    the password is in effect the public key ssh key on the host that you are connecting from, so keeping the private key secure is important (usually in ~.ssh/ but no password is required to be in the script

    @Kvistofta there is no password with key based auth see how the hash of the is used
    LVL 17

    Expert Comment

    Yes you are right but the effect is the same: The user running the script needs to have access to the private key.


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Enabling OSINT in Activity Based Intelligence

    Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

    Tired of waiting for your show or movie to load?  Are buffering issues a constant problem with your internet connection?  Check this article out to see if these simple adjustments are the solution for you.
    Creating an OSPF network that automatically (dynamically) reroutes network traffic over other connections to prevent network downtime.
    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.
    In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…

    758 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

    12 Experts available now in Live!

    Get 1:1 Help Now