{"id":4068,"date":"2026-09-17T17:00:47","date_gmt":"2026-09-17T11:30:47","guid":{"rendered":"https:\/\/cybx.in\/blog\/?p=4068"},"modified":"2026-09-17T17:00:48","modified_gmt":"2026-09-17T11:30:48","slug":"how-does-ssh-work","status":"publish","type":"post","link":"https:\/\/cybx.in\/blog\/how-does-ssh-work\/","title":{"rendered":"How Does SSH Work?"},"content":{"rendered":"\n<meta name=\"description\" content=\"SSH stands for Secure Shell. It gives you a protected way to connect to another computer over a network. You might use it to manage a server from your laptop\">\n<meta property=\"og:title\" content=\"How Does SSH Work?\">\n<meta property=\"og:description\" content=\"SSH stands for Secure Shell. It gives you a protected way to connect to another computer over a network. You might use it to manage a server from your laptop\">\n<meta name=\"twitter:card\" content=\"summary_large_image\">\n<meta name=\"twitter:title\" content=\"How Does SSH Work?\">\n<meta name=\"twitter:description\" content=\"SSH stands for Secure Shell. It gives you a protected way to connect to another computer over a network. You might use it to manage a server from your laptop\">\n\n\n<p>SSH stands for Secure Shell. It gives you a protected way to connect to another computer over a network. You might use it to manage a server from your laptop without sitting in front of that server.<\/p>\n<h2>SSH Starts With a Connection<\/h2>\n<p>Say Raj needs to manage a Linux server from his laptop. He opens a terminal and runs an SSH command with the server&#8217;s address. The SSH client on his laptop contacts the SSH server running on the remote machine.<\/p>\n<p>Then they need to agree on how the connection will be protected. This happens during the SSH handshake, which sounds more complicated than it feels in practice.<\/p>\n<h3>The Handshake<\/h3>\n<p>During the handshake, the two sides exchange information about supported security methods. They settle on encryption and create session keys that will protect the connection. These keys are used for the current session rather than being something you type or carry around yourself.<\/p>\n<p>The server also proves its identity using a host key. Your SSH client can remember that key. If the server suddenly presents a different key later, you&#8217;ll get a warning, which is exactly the sort of interruption you want when something looks suspicious.<\/p>\n<p>\u2022 Encryption happens before your normal SSH session begins, so the commands don&#8217;t travel across the network as readable text.<\/p>\n<p>\u2022 The host key gives your computer a way to recognize the server, although you still need to pay attention to warnings instead of blindly accepting them.<\/p>\n<h2>Then SSH Checks Who You Are<\/h2>\n<p>A secure connection isn&#8217;t enough. The server also needs to know whether you&#8217;re allowed in.<\/p>\n<p>That&#8217;s where authentication comes in. Passwords work, but SSH keys are the better choice for regular server access, in my view. They avoid repeatedly typing passwords and are much harder to guess when properly protected.<\/p>\n<h3>SSH Keys<\/h3>\n<p>An SSH key comes as a pair. Your private key stays on your computer. The public key is placed on the server. They work together without sending your private key across the network.<\/p>\n<p>When you connect, the server asks you to prove that you have the matching private key. Your computer does that cryptographically. The private key itself stays where it belongs.<\/p>\n<p>Raj set up key-based access for a small server and stopped reopening the same five terminal tabs every morning just to find the right connection. After a while, logging in felt almost invisible.<\/p>\n<h2>What Happens After Login?<\/h2>\n<p>\u2022 Your terminal session is carried inside the encrypted connection, so typing commands feels like working directly on the remote machine.<\/p>\n<p>\u2022 File transfers use the same SSH foundation too. Tools such as SCP and SFTP rely on SSH rather than creating a completely separate security system.<\/p>\n<h2>Why SSH Works So Well<\/h2>\n<p>The clever part is how much SSH handles without making you think about it. The connection is negotiated. Your identity is checked. Data is encrypted. Then you get on with the actual work.<\/p>\n<p>You don&#8217;t need to watch encryption happening in the background. That&#8217;s the whole point. A good security tool should mostly get out of your way.<\/p>","protected":false},"excerpt":{"rendered":"<p>SSH stands for Secure Shell. It gives you a protected way to connect to another computer over a network. You&#8230;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[31],"tags":[],"class_list":["post-4068","post","type-post","status-publish","format-standard","hentry","category-learn"],"_links":{"self":[{"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/posts\/4068","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/comments?post=4068"}],"version-history":[{"count":1,"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/posts\/4068\/revisions"}],"predecessor-version":[{"id":4149,"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/posts\/4068\/revisions\/4149"}],"wp:attachment":[{"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/media?parent=4068"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/categories?post=4068"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cybx.in\/blog\/wp-json\/wp\/v2\/tags?post=4068"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}