Setting Up SSH Keys

  Рет қаралды 40,177

Nerd on the Street

Nerd on the Street

4 жыл бұрын

Are you still using passwords for your SSH sessions? Here's a quick tutorial for increasing your security by setting up key-based authentication instead.
---
Join the Nerd Club: nerdclub.nots.co
nerdonthestreet.com
discord.nots.co
/ nerdonthestreet
/ nerdonthestreet
/ nots_network
E-Mail: jacob@nerdonthestreet.com

Пікірлер: 31
@Borsting89
@Borsting89 4 жыл бұрын
This is great, thanks for sharing Jacob. I`ve actually been using key authentication for quite a while now since its required for rsync automated backup. For any of you guys watching, key based authentication not only let you secure your server at a higher level, but it is also necessary if you want to run a scheduled cronjob with backup using rsync. It allows for a fully encrypted, very robust backup over the network/internet. Maybe that would be a great follow up video for you, Jacob? And btw, 3:12 is one of the reasons I love this channel.
@TheKeule33
@TheKeule33 4 жыл бұрын
Thank you. For new users like me: when trying to login after the key setup is complete, make sure to login as the same user you setup the keys with. He mentions this, but I was an idiot and tried to login as root. Explanation: SSH looks for the key in the users directory /home/USER/.ssh/. When you are root, you use a different home directory, and therefore a different path to ~/.ssh, because roots home is /root/.ssh/
@davids9139
@davids9139 Жыл бұрын
Great video! Out of all the videos on the internet, this one helped the most with setting up keys and understanding the finer details. I really appreciate you taking the time to make this video. Thanks Jacob!
@deannalipowicz2862
@deannalipowicz2862 2 жыл бұрын
Thank you for finally explaining what a key is. I literally watched several videos and nobody actually explains the difference between this and a password the way you did.
@paulcodes
@paulcodes 3 жыл бұрын
Dude this was perfect! Thanks for going through all of the details. It finally clicked for me thanks for your talking through the thought process as well as each step. Thanks for putting this together! Keep it up!
@vincentlaw1016
@vincentlaw1016 4 жыл бұрын
Your videos are very informative and easy to understand for linux noobs like myself thanks for posting this.
@merkin3k
@merkin3k 4 жыл бұрын
Thanks for doing that extra step and configuring access from a second client. That cleared up something for me that I was just trying to work through last night. 👍
@mrherpes2971
@mrherpes2971 3 жыл бұрын
thank you very much, finally after so many years, ssh concept has been made clear!
@martymccafferty7510
@martymccafferty7510 4 жыл бұрын
Glad to see you using ssh keys now. Keys can also be assigned commands on remote sever, and not just the bash shell. I use this so my admins can see results of a command. Of couse sshfs is another magical tool to use with ssh to mount a share over ssh. There is lots of magic that can be done with ssh.
@EnglishRain
@EnglishRain 2 жыл бұрын
Excellent tutorial, thank you so much!
@ProgrammingwithPeter
@ProgrammingwithPeter 4 жыл бұрын
This is important and useful if you have to do it a lot, in general it's a good practice to use ssh
@daniellevitski6703
@daniellevitski6703 11 ай бұрын
Respect!! One of the best tutorials!
@hakkadesu1322
@hakkadesu1322 Жыл бұрын
Incredibly well explained, thank you very much.
@rcdenis1
@rcdenis1 4 жыл бұрын
Public/private keys made sense to me when someone suggested I think of a lock and its key. The public key is the lock on the server's gate and the private key is my key to open the lock so i can get in. Simple concept. Thanks for the video.
@mrherpes2971
@mrherpes2971 3 жыл бұрын
yeah this simple analogy made this concept so simple to understand.
@JNET_Reloaded
@JNET_Reloaded 2 жыл бұрын
om on a rpi4 running raspbian os for arm and 3cx is onit all working, now i want to put that all as is onto a vmware, the stand alone refuses to connect i tried all kinds root account normal account thats added to sudoers file tried all kinds of ssh keys and nothing connects any ideas? can i just image the sd card and give that img file to vmware and it just work? i thought i could just add the public ssh key from w.e the vmware stand alone crap uses to auth hosts file but i dont know where to find the pubolic key for my windows i can generate 1 but not sure if that works i did try but it failed!
@jayleeh65
@jayleeh65 3 жыл бұрын
What if my server is not configured for password authentication and only requires an ssh key authentication? How would I be able to ssh copy the key from my local machine to the remote server without doing the manual copy paste format?
@martymccafferty7510
@martymccafferty7510 4 жыл бұрын
With Ssh-agent you will only have to type your passphrase once and you will not get prompted again for that key when you ssh again, until you logout of your desktop session, which would end the ssh-agent session.
@mariadeclaret540
@mariadeclaret540 Жыл бұрын
Hello, I generated ssh key but I cant find where it is saved, thus unable to log in to the server
@wolfganggosejacob779
@wolfganggosejacob779 3 жыл бұрын
a mathematical question: can i change the private key and the public key before first usage by changing the filenames? result is that i spread my "private key" and save my "public key". the function and security should be the same! or not?
@NerdOnTheStreet
@NerdOnTheStreet 3 жыл бұрын
The private key and public key use different formats (and the private key is larger.) While it might be acceptable from a security standpoint in some scenarios, I wouldn't expect it to work in practice with most software. There are several good Stack Exchange answers about this if you do a web search for your question.
@wolfganggosejacob779
@wolfganggosejacob779 3 жыл бұрын
@@NerdOnTheStreet thank you for explaining the difference. so i can look for the length
@m4l490n
@m4l490n 4 жыл бұрын
Why are you going to change your file run for nextcloud?
@NerdOnTheStreet
@NerdOnTheStreet 4 жыл бұрын
Because Nextcloud is open-source. I'm actually not a fan of the Nextcloud developers (they tend to think they "know what's best" for their users), but Filerun being proprietary makes it a stain for me, as well as it works.
@lechsiz1642
@lechsiz1642 2 жыл бұрын
@@NerdOnTheStreet How safe is it for me to store a copy of my private SHH key on nextcloud if I use a provider? I rent a room in a house with 2 other roommates and if my PCs/gear were ever stolen, I'd lose the key. granted, my server is a Pi4, so that might get stolen, too. That is one reason I don't want my own Nextcloud on my own server.
@eliashckr4913
@eliashckr4913 4 жыл бұрын
I want to translate your video, enable the translator option in the video
@user-kv3nt7fc8s
@user-kv3nt7fc8s 5 ай бұрын
ssh not working, pleaase help me .. /root/.ssh/config: line 2: Bad configuration option: username
@Itronyx1cz
@Itronyx1cz Жыл бұрын
I really don't know what to say, for me the tutorial is complicated, plus I don't understand one thing at 10:50 what is this supposed to be? Entering via root? And also some ip that you didn't even say if it belongs to the server or to the computer it owns. And another thing is that for me it says it found no ERROR No such file? Like doesn't it generate it rather than like search? What is this terminal behavior? All the procedures I tried to do according to the video and I have no other option but to give up and use another server instead of SSH because I really can't do it any other way.
@NerdOnTheStreet
@NerdOnTheStreet Жыл бұрын
"at 10:50 what is this supposed to be? Entering via root?" - Yes, that moment is logging into the root account of a server that is still configured with password-based authentication. "you didn't even say if it belongs to the server or to the computer it owns." - Servers do not "own" computers. I don't know where you got that idea, because it wasn't from this video. You can also deduce that if I'm on a client computer and I'm SSH'ing into something, it's not the client computer... because why would I SSH into the computer that I'm already on? "it found no ERROR No such file?" - It seems like you messed up the formation of this sentence, but you provided an incorrect filename or path to a command if you're seeing that message. If you're sure that the file path is correct, then you may be running a command meant for the client on the server (or vice versa). "All the procedures I tried to do according to the video" - You most certainly did not do the procedures according to the video if it's not working. This is a very basic process that doesn't change much between distros or over time. "I have no other option but to give up and use another server instead of SSH" - You're going to throw away a physical server because you can't log in with SSH? Or do you mean "use another authentication mechanism," like a password? SSH is extremely common and there are many resources about how to set it up, so please do not insinuate that your failure to follow my tutorial means that I have deprived you of the ability to use a server.
@chessgo5028
@chessgo5028 5 ай бұрын
Man it is too technical. I was looking for simpler explanation. dislike.
SSH Key Authentication | How to Create SSH Key Pairs
18:46
Akamai Developer
Рет қаралды 99 М.
How SSH Works
8:54
Mental Outlaw
Рет қаралды 444 М.
Help Herobrine Escape From Spike
00:28
Garri Creative
Рет қаралды 56 МЛН
АВДА КЕДАВРАААААА😂
00:11
Romanov BY
Рет қаралды 7 МЛН
And what’s your age? 🥰 @karina-kola
00:12
Andrey Grechka
Рет қаралды 6 МЛН
SSH Keys
10:12
RobEdwards
Рет қаралды 94 М.
I KNEW I’d Hate this (I Was Wrong)
12:19
Linus Tech Tips
Рет қаралды 568 М.
SSH Tunneling Explained
6:37
Tinkernut
Рет қаралды 460 М.
How to know if your PC is hacked? Suspicious Network Activity 101
10:19
The PC Security Channel
Рет қаралды 995 М.
Intro to SSH and SSH Keys
13:38
Paul Turner
Рет қаралды 134 М.
LibreWolf & Brave - Web Browsers in 2023
1:03:58
Nerd on the Street
Рет қаралды 39 М.
Crack SSH Private Key Passwords with John the Ripper [Tutorial]
12:51
How Secure Shell Works (SSH) - Computerphile
9:20
Computerphile
Рет қаралды 806 М.
The PA042 SAMSUNG S24 Ultra phone cage turns your phone into a pro camera!
0:24
Какой Смартфон Купить в 2024 Году? Выбор бюджетного телефона
14:21
Thebox - о технике и гаджетах
Рет қаралды 265 М.