Enable SSH server on Backtrack 5 r2

The SSH server is pre-installed , we just need to configure it before we can fire it up.
The first thing we need to is generate the ssh keys by running:

root@bt:~# sshd-generate

Generating public/private rsa1 key pair.
<— blablabla — >
Generating public/private rsa key pair.
Your identification has been saved in /etc/ssh/ssh_host_rsa_key.
Your public key has been saved in /etc/ssh/ssh_host_rsa_key.pub.
<— blablabla — >
Generating public/private dsa key pair.
Your identification has been saved in /etc/ssh/ssh_host_dsa_key.
Your public key has been saved in /etc/ssh/ssh_host_dsa_key.pub.
<— blablabla — >

Now that we have generated the ssh keys we can  start the SSH server.

root@bt:~# /etc/init.d/ssh start
* Starting Secure Shell server sshd [ OK ]

You can verify whether the server has started by issuing a netstat command.

root@bt:~# netstat -ntlp

Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 3690/sshd
<— blablabla —>

To start the SSH server when Backtrack start run:

update-rc.d -f ssh defaults

5 thoughts on “Enable SSH server on Backtrack 5 r2”

  1. Love it, simple and to the point and worked perfectly 🙂 also to check / start the ssh you can type service ssh status/start/disable/enable whatever.

    Thanks again!

Leave a Reply

Your email address will not be published. Required fields are marked *

*