SSH (Secure Shell)

Secure remote access protocol with key-based authentication and encrypted communications

What is SSH?

SSH (Secure Shell) is a cryptographic network protocol that provides secure remote access to systems over an unsecured network. It replaces insecure protocols like Telnet and rlogin.

Key Features:
  • Encryption: All communication encrypted
  • Authentication: Multiple auth methods
  • Integrity: Data tampering detection
  • Port Forwarding: Tunnel other protocols
  • File Transfer: SCP and SFTP support
  • X11 Forwarding: Remote GUI applications
  • Agent Forwarding: Key management
  • Compression: Bandwidth optimization
SSH Connection Process:
1
TCP Connection

Client connects to server on port 22

2
Protocol Negotiation

Agree on SSH version and algorithms

3
Key Exchange

Establish encrypted session keys

4
Authentication

Verify user identity (keys/password)

5
Secure Session

Encrypted command execution

SSH vs Legacy Protocols

ProtocolPortEncryptionAuthenticationStatus
SSH22StrongKeys, Password, MFARecommended
Telnet23NonePassword (plaintext)Deprecated
rlogin513NoneHost-basedDeprecated
FTP21NonePassword (plaintext)Use SFTP

🔐 SSH Quick Facts

  • Created: 1995 by Tatu Ylönen
  • Current Version: SSH-2 (RFC 4251-4254)
  • Default Port: 22/tcp
  • Key Algorithms: RSA, ECDSA, Ed25519
  • Encryption: AES, ChaCha20-Poly1305

Common Use Cases

Remote Administration

Secure server management and configuration

Development & Deployment

Git operations, CI/CD, and code deployment

File Transfer

Secure file transfer with SCP and SFTP

Tunneling & Proxying

Port forwarding and SOCKS proxies