how to change ssh port using command line

Discussion in 'DD-WRT Firmware' started by sufrano63, Dec 1, 2005.

  1. sufrano63

    sufrano63 Network Guru Member

    I'm currently running SSH on port 22 and wish to change it to a diff. port. I know how to enable from the FW, but there was a command line to enable to access from the Internet. I already have the command below configured in the router

    - /usr/sbin/iptables -I INPUT 1 -p --tcpport 22 .......
    - nvram="/usr/sbin..................
    - nvram commit

    Would anyone know the command to erase what's in the iptable and change to a diff. port with the same command above.

    Thanks in advance
  2. k3nv

    k3nv Network Guru Member

    Are you using dropbear ssh? I think you change that from the /etc/init.d/S50dropbear. You change:

    /usr/sbin/dropbear -p 2222

    Where 2222 is the port #
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice