ssh
Skill0 starsChanged 8 months agoMITView on GitHub
SSH remote access patterns and utilities for connecting to servers, managing keys, configuring connections, creating tunnels, and transferring files.
- Reads credentials
8 other projects use a version of this, 1 of them edited.
Adopted by
Most recently taken up by
- Suge8/friedbuntheir own version, first seen Oct 11, 2026
- OpenHands/extensionstheir own version, first seen Oct 8, 2026
- yanggujun/open-axletheir own version, first seen Sep 5, 2026
- zhinkgit/embeddedskillstheir own version, first seen Sep 3, 2026
- Dicklesworthstone/agent_flywheel_clawdbot_skills_and_integrationsedited, first seen Jun 19, 2026
- reddydamodar38/claude-skillstheir own version, first seen May 27, 2026
Other versions8 projects use a version of this.
Word for word · 0
None found.
Edited · 1
Wrote their own version · 7
- zhinkgit/embeddedskills★ 764same name
- OpenHands/extensions★ 167same name
- Suge8/friedbun★ 12same name
- bigph00t/SSH-Skill★ 9same name
- nguyenvanhuy0612/claude-skills★ 0same name
- reddydamodar38/claude-skills★ 0same name
- yanggujun/open-axle★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository13 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- ccswitchSkill
- code-rulesSkill
- leanmgr-cache-managerSkill
- learn-math-by-lean-notebookSkill
- lmfdb-cliSkill
- mathlib-styleSkill
- mathlib-workflowSkill
- openclaw-rssSkill
- pre-initSkill
- pr-worktree-workflowSkill
- tmuxSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
13 rules. 0 are common, 10 are distinctive, and 3 are very specific to this project.
0
Common
Most of the 5 edited versions we read keep these.
10
Distinctive
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 31
Create or edit for easier connections:
- Distinctive: line 93
Add key to agent:
- Distinctive: line 98
Add with macOS keychain:
- Distinctive: line 120
Run with pseudo-terminal (for interactive):
- Distinctive: line 234
Remove old host key:
- Distinctive: line 274
Test SSH config syntax:
- Distinctive: line 279
Check SSH service status:
- Distinctive: line 362
Use Ed25519 keys (faster, more secure than RSA)
- Very specific: line 364
Use fail2ban to block brute force attempts
- Distinctive: line 365
Keep keys encrypted with passphrases
- Very specific: line 366
Use ssh-agent to avoid typing passphrase repeatedly
- Distinctive: line 368
Always test new SSH config before restarting (keep session open)
- Very specific: line 369
Use AllowUsers or AllowGroups to limit access
“Common” is measured: kept by at least 6 in 10 of the 5 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
SSH Skill
Comprehensive SSH for secure remote access, file transfers, tunneling, and server hardening.
Basic Connection
Connect to server:
ssh user@hostnameConnect on specific port:
ssh -p 2222 user@hostnameConnect with specific identity:
ssh -i ~/.ssh/my_key user@hostnameSSH Config
Config file location: ~/.ssh/config
Create or edit for easier connections:
mkdir -p ~/.ssh
chmod 700 ~/.ssh
cat > ~/.ssh/config << 'EOF'
Host myserver
HostName 192.168.1.100
User deploy
Port 22
IdentityFile ~/.ssh/myserver_key
ForwardAgent yes
ServerAliveInterval 60
EOF
chmod 600 ~/.ssh/configThen connect with just:
ssh myserverKey Management
Generate new key (Ed25519, recommended):
ssh-keygen -t ed25519 -C "your_email@example.com"Generate RSA key (legacy compatibility):
ssh-keygen -t rsa -b 4096 -C "your_email@example.com"Copy public key to server:
ssh-copy-id user@hostCopy specific key:
ssh-copy-id -i ~/.ssh/mykey.pub user@hostManual key copy:
# Display public key
cat ~/.ssh/id_ed25519.pub
# On server, as the user
mkdir -p ~/.ssh
chmod 700 ~/.ssh
nano ~/.ssh/authorized_keys # Paste public key
chmod 600 ~/.ssh/authorized_keysSSH Agent
Start agent:
eval "$(ssh-agent -s)"Add key to agent:
ssh-add ~/.ssh/id_ed25519Add with macOS keychain:
ssh-add --apple-use-keychain ~/.ssh/id_ed25519List loaded keys:
ssh-add -lRunning Remote Commands
Execute single command:
ssh user@host "ls -la /var/log"Execute multiple commands:
ssh user@host "cd /app && git pull && pm2 restart all"Run with pseudo-terminal (for interactive):
ssh -t user@host "htop"File Transfer
SCP
Copy file to remote:
scp local.txt user@host:/remote/path/Copy file from remote:
scp user@host:/remote/file.txt ./local/Copy directory recursively:
scp -r ./local_dir user@host:/remote/path/rsync (preferred)
Sync directory to remote:
rsync -avz ./local/ user@host:/remote/path/Sync from remote:
rsync -avz user@host:/remote/path/ ./local/With progress and compression:
rsync -avzP ./local/ user@host:/remote/path/Dry run first:
rsync -avzn ./local/ user@host:/remote/path/Port Forwarding (Tunnels)
Local Forward
Access remote service locally:
ssh -L 8080:localhost:80 user@host
# Now localhost:8080 connects to host's port 80Forward to another host:
ssh -L 5432:db-server:5432 user@jumphost
# Access db-server:5432 via localhost:5432Remote Forward
Expose local service to remote:
ssh -R 9000:localhost:3000 user@host
# Remote's port 9000 connects to your local 3000Dynamic SOCKS Proxy
ssh -D 1080 user@host
# Use localhost:1080 as SOCKS5 proxy for network pivotingJump Hosts / Bastion
Connect through jump host:
ssh -J jumphost user@internal-serverMultiple jumps:
ssh -J jump1,jump2 user@internal-serverIn config file:
Host internal
HostName 10.0.0.50
User deploy
ProxyJump bastionMultiplexing (Connection Sharing)
In ~/.ssh/config:
Host *
ControlMaster auto
ControlPath ~/.ssh/sockets/%r@%h-%p
ControlPersist 600Create socket directory:
mkdir -p ~/.ssh/socketsKnown Hosts
Remove old host key:
ssh-keygen -R hostnameScan and add host key:
ssh-keyscan hostname >> ~/.ssh/known_hostsCommon SSH Options
| Option | Description |
-p PORT | Connect to specific port |
-X | Enable X11 forwarding |
-L local:remote:port | Local port forwarding |
-R remote:local:port | Remote port forwarding |
-D port | Dynamic SOCKS proxy |
-N | Don't execute remote command (for tunnels) |
-f | Run in background |
-v | Verbose mode (use -vv, -vvv for more) |
Debugging
Verbose output:
ssh -v user@hostVery verbose:
ssh -vv user@hostMaximum verbosity:
ssh -vvv user@hostTest SSH config syntax:
sudo sshd -tCheck SSH service status:
sudo systemctl status sshdSSH Hardening (Server Side)
Create Non-Root User
# Create user
sudo adduser deployer
# Add to sudo group
sudo usermod -aG sudo deployer
# Test sudo access
su - deployer
sudo whoami # Should output: rootHardened sshd_config
Edit /etc/ssh/sshd_config:
# Disable root login
PermitRootLogin no
# Disable password authentication
PasswordAuthentication no
# Disable empty passwords
PermitEmptyPasswords no
# Limit authentication attempts
MaxAuthTries 3
# Allow specific users
AllowUsers deployer
# Use only SSH protocol 2
Protocol 2
# Disable X11 forwarding (unless needed)
X11Forwarding no
# Set login grace time
LoginGraceTime 60
# Disable host-based authentication
HostbasedAuthentication noOptional Advanced Settings
# Change default port (reduces automated scanner noise)
Port 2222
# Disable agent forwarding
AllowAgentForwarding no
# Disable TCP forwarding (if not needed)
AllowTcpForwarding no
# Set idle timeout
ClientAliveInterval 300
ClientAliveCountMax 2Test and Restart
# Test configuration
sudo sshd -t
# Restart SSH service
sudo systemctl restart sshdSecurity Best Practices
- Use Ed25519 keys (faster, more secure than RSA)
- Set
PasswordAuthentication noon production servers - Use
fail2banto block brute force attempts - Keep keys encrypted with passphrases
- Use
ssh-agentto avoid typing passphrase repeatedly - Restrict key usage with
command=in authorized_keys - Always test new SSH config before restarting (keep session open)
- Use
AllowUsersorAllowGroupsto limit access - Monitor authentication logs:
/var/log/auth.log - Rotate SSH keys periodically
File Permissions
# Private key (MUST be 600)
chmod 600 ~/.ssh/id_ed25519
# Public key (can be 644)
chmod 644 ~/.ssh/id_ed25519.pub
# SSH directory
chmod 700 ~/.ssh
# Authorized keys
chmod 600 ~/.ssh/authorized_keys
# SSH config
chmod 600 ~/.ssh/configTroubleshooting
| Issue | Solution |
| Connection refused | Verify SSH running; check firewall; confirm port |
| Auth failed | Check key permissions (600); verify authorized_keys format |
| Host key changed | Remove old entry: ssh-keygen -R hostname |
| Tunnel not working | Check GatewayPorts in sshd_config; verify firewall |
| Permission denied | Check file permissions; verify user has access |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

