Hey everyone and welcome back. Now in the previous nugget we had looked at SSH server
configuration. In this nugget right here we're going to take a look at the client configuration
or at least some of the rules which apply to the client configuration. So you may recall
that in the previous nugget we actually modified a particular file and this was called the SSHD
config file. Now when you see the SSHD you know that you're dealing with the server configuration
that is the ability of your system to act as an SSH server for incoming connections. If you
just want to be able to make an SSH connection i.e. to connect to a remote SSH server the actual
configuration file is going to just be SSH underscore config so without that D that D is
going to tell you the server without it it will be the client configuration. Now we learned that
with SSH we can ultimately wrap our FTP connection into an encrypted tunnel via SSH ultimately
giving us secure FTP. Now this type of configuration for SFTP as well as to make secure copy
connections we can control this within this particular file. Now we have a global configuration
whereby we can manipulate our SSH client settings. This is going to be in the location again no
surprises the Etsy directory then noting that this is going to be system-wide. Again we go into
the SSH directory and then within this we're going to have SSH underscore config. This here will
be your system-wide settings which will apply to all users. Now we do have an order of precedents
right here the global settings are at the very lowest order of precedents they're going to come
in order three of three. Above that we have our user specific configurations that would be your
user and whereabouts we could specify these configurations would be within your home directory
so we'll do our dollar sign for our variable value and then home and within the user's home
directory we will have our dot SSH directory the hidden directory and then we'll have a file called
config this is where a user can specify their particular SSH settings so really anything that
is in the global settings will be overwritten by whatever the user specifies within here but we
do have one more setting that is going to override all that's going to be the top order of operations
with respect to precedents that is the CLI arguments that you actually specify when issuing any SSH
commands via your terminal. So to recap we have client configurations then we have our user
configurations and then the global settings really that means that if we happen to have some type
of configuration specified in the global and we don't have anything in the user defined and we
don't specify anything via the command line those global configurations will take effect however if
we have a conflict and the settings are specified within the global and that particular user who
is using SSH also has the same setting within their user defined SSH configuration file if we have
that clash the global ones will not take effect we're going to go with the user specific configurations
and again those settings can be overwritten directly if the user happens to specify them in via
the command line directly so if I clear the screen and let me just full screen this for now so if I
say man SSH we can see here this is the open SSH login client we can see here all of these
different options so if we specify dash 4 for IPv4 addresses via the command line or again if we
just scroll on down we can specify particular cipher specifications again if you're passing this in
via the command line they will actually override the settings specified within your configuration
file under the ciphers heading okay so that is the first order let's have a look at the configurations
within the Etsy directory so we go into Etsy and SSH and then SSH underscore config again not SSHD
and of course I'm going to have to use nano to actually open this up so I'll try that again type
in the passwords cool so this one looks a little bit different you will see some crossover with
respect to the settings but ultimately this is like I say for the client configuration so and in
fact here you actually even notice look what it says right here command line options user specific
system-wide again here if we scroll on down here are all the things that we can ultimately configure
via our client configuration file so again we can change the port we're gonna have the default
port that we're going to try to reach the connection to be maybe say 2222 but again by default we
can see here that we're going to use port 22 for good reason so we just change that back we can
specify which type of ciphers we want to include with respect to our cryptography and we can add
in more configurations with respect to say for example x11 as we can see right here but ultimately
understanding that this configuration file is our system-wide configuration file and again if I wanted
to create a user specific one I could go into my home directory in fact if I just do cd takes me to
my home directory at our pwd we can see where we are I can do this to do nano and then go into the
dot SSH directory and then I could have a file called config and within here I could actually
specify user specific configurations so really when we want to be using SSH as a client maybe
a game we're going to be using secure copy whatever it may be understanding this order of
precedence it really is very very important again we go with CLI then the user specific and then
the system-wide configurations try to remember the particular locations of these configuration files
because understanding these locations certainly will be beneficial for the purposes of the examination
but now we have the general understanding of these client configurations let's dive in and begin
working with these client configurations doing things like using scp using sftp those are the
things that we'll be looking at in the very next nuggets I hope this has been informative for you
and I'd like to thank you for viewing