Most Linux administration happens from somewhere else. You sit at one machine and work on another, through SSH — the Secure Shell protocol, served by the sshd service on port 22 by default. It gives you an encrypted shell on a remote machine: your keystrokes travel protected, and the session feels, reassuringly, secure by itself.
That reassurance is the misconception to retire. SSH encrypts the road. It does not decide who holds the keys to the door at the end of it. Password authentication left enabled, a private key readable by every account on your machine, a fingerprint warning waved through in a hurry — each leaves the front door weak behind an encrypted path to it. The protocol's strength is real, and it is entirely conditional on checks that are the operator's job, not the tool's.
The fingerprint is an identity check, not a nuisance
The first connection to a host asks you to confirm the host's fingerprint — the remote machine's identity presented as a short digest. Accepting it records the host's key in your ~/.ssh/known_hosts file, and future connections verify against that record, warning loudly if the key ever changes.
That prompt deserves more respect than it usually gets. A changed key can mean a rebuilt machine. It can also mean an impostor. The check that separates the two is confirming the new fingerprint through a second channel — asking the machine's owner, or reading it from a trusted console — never simply accepting through the warning because you are in a hurry. The warning is the security working. Treating it as an obstacle to click past turns a real protection into a ceremony.
Keys prove possession; passwords prove knowledge
Authentication comes in two forms, and the difference decides how strong the door is. A password proves you know a secret the account holds. Secrets that are known can be guessed, phished, and tried a great many times by strangers — and port 22 faces the internet on many hosts.
A key pair proves you hold a file. You generate a pair: a private key that never leaves your machine, commonly ~/.ssh/id_ed25519, and a public key that you place on the server, in the target account's ~/.ssh/authorized_keys. The server issues a challenge, your private key answers it, and nothing guessable travels across the network. That is why the professional standard for administrative access is key-based, with passwords for SSH disabled on internet-facing machines wherever possible: a door strangers cannot rattle.
Permissions are what make a key a secret
Keys only work when permissions protect them, and SSH enforces this itself. Your .ssh directory should be 700, so that you alone may enter it. Your private key should be 600, so that you alone may read it, and authorized_keys likewise 600.
A private key readable by others is treated by SSH as already compromised: connections fail with an explicit complaint about permissions. SSH is right to refuse. A secret that everyone on the machine can read is not a secret, whatever the file is named. This is where the earlier lessons on permissions stop being bookkeeping and become security in the plain sense — the numbers on a listing decide whether your strongest authentication method functions at all, and whether the file it depends on deserves the trust placed in it.
A transfer command has two addresses
The same discipline governs the tools that ride on SSH. The scp command copies a file to or from a remote machine through the same authentication, and sftp provides an interactive transfer session. Both inherit the front door's rules, and both carry a risk the local copy never did: a remote path is a path on another machine.
Read a transfer command as a sentence with two addresses, because that is what it is. In scp report.txt henrik@shop-host:/srv/reports/, the first address is local, a plain path on your machine. The second, after the colon, is a path on the named host, in the named account's world, where relative paths resolve from that account's home directory on that machine. Copying from a host reverses the sentence, bringing the file here, to the current directory.
The discipline follows from the grammar. Before a consequential transfer, state both addresses aloud with their machines attached: from my laptop's current folder, to the shop host's reports folder. Where the remote destination matters — and it usually does, for configuration files, data drops, and anything a service will read — list the remote directory through an SSH command first, and read back the landed file afterward with a remote listing and its size. Silence after a copy command reports that bytes moved. Only the read-back reports that they arrived where the sentence said they would.
Small aids, and the exit discipline
Two working aids complete the picture. A per-host entry in your own ~/.ssh/config can give a machine a short alias carrying its hostname, user, and key, so a short command replaces a paragraph of flags — and reduces the chance of typing the right command at the wrong host.
And there is the exit discipline. The exit command closes the session, and the habit of glancing at the prompt — which machine am I administering right now — matters most precisely here, where two terminals can hold two different hosts and a command meant for the lab can land, in the wrong window, on a customer's production server. Read the hostname in the prompt before every consequential remote command. The front door deserves a careful operator: one who verifies the house, holds the only copy of the key, keeps that key unreadable to others, and checks the address twice before anything crosses the threshold.
Experience it, don’t just read about it
Keys, permissions, and the front door in remote access with SSH is Concept 16 of Linux Essentials: Work Confidently on Linux Systems (Course No. 290), from Cognosco Learning, a learning company powered by AI. The course builds confident operation beyond this distinction — Permissions — Reading the Listing, Networking from the Host, and The Safe Operator — each worked through with an Agentic Socratic AI coach, one learner at a time. Try a Free Preview at cognoscolearning.com.
Navigate your own course.
© 2026 Cognosco Learning. All rights reserved.