How To Install openssh-server on Kali Linux
Introduction
In this tutorial we learn how to install openssh-server
on Kali Linux.
What is openssh-server
openssh-server is:
This is the portable version of OpenSSH, a free implementation of the Secure Shell protocol as specified by the IETF secsh working group.
Ssh (Secure Shell) is a program for logging into a remote machine and for executing commands on a remote machine. It provides secure encrypted communications between two untrusted hosts over an insecure network. X11 connections and arbitrary TCP/IP ports can also be forwarded over the secure channel. It can be used to provide applications with a secure communication channel.
This package provides the sshd server.
In some countries it may be illegal to use any encryption at all without a special permit.
sshd replaces the insecure rshd program, which is obsolete for most purposes.
There are three methods to install openssh-server
on Kali Linux. We can use apt-get
, apt
and aptitude
. In the following sections we will describe each method. You can choose one of them.
Install openssh-server Using apt-get
Update apt database with apt-get
using the following command.
sudo apt-get update
After updating apt database, We can install openssh-server
using apt-get
by running the following command:
sudo apt-get -y install openssh-server
Install openssh-server Using apt
Update apt database with apt
using the following command.
sudo apt update
After updating apt database, We can install openssh-server
using apt
by running the following command:
sudo apt -y install openssh-server
Install openssh-server Using aptitude
If you want to follow this method, you might need to install aptitude on Kali Linux first since aptitude is usually not installed by default on Kali Linux. Update apt database with aptitude
using the following command.
sudo aptitude update
After updating apt database, We can install openssh-server
using aptitude
by running the following command:
sudo aptitude -y install openssh-server
How To Uninstall openssh-server on Kali Linux
To uninstall only the openssh-server
package we can use the following command:
sudo apt-get remove openssh-server
Uninstall openssh-server And Its Dependencies
To uninstall openssh-server
and its dependencies that are no longer needed by Kali Linux, we can use the command below:
sudo apt-get -y autoremove openssh-server
Remove openssh-server Configurations and Data
To remove openssh-server
configuration and data from Kali Linux we can use the following command:
sudo apt-get -y purge openssh-server
Remove openssh-server configuration, data, and all of its dependencies
We can use the following command to remove openssh-server
configurations, data and all of its dependencies, we can use the following command:
sudo apt-get -y autoremove --purge openssh-server
Dependencies
openssh-server have the following dependencies:
References
Summary
In this tutorial we learn how to install openssh-server
package on Kali Linux using different package management tools: apt
, apt-get
and aptitude
.