Learn / Lessons

Keys and security

Your server holds your work. Who can get in, and how would you know? Use a password manager. A different password everywhere. Turn on two step sign in.

Chapters

  1. 0:00Introduction
  2. 0:05Sign-ins: Strong sign-ins
  3. 0:14SSH keys: Make a key
  4. 0:23App secrets: Keys for programs
  5. 0:31Less is safer: Only what's needed
  6. 0:39The network: Shut the front door
  7. 0:50If it leaks: Act fast
  8. 0:57Recover: Keep backups
  9. 1:05Wrap up
Read the transcript

Introduction

Your server holds your work. Who can get in, and how would you know?

Sign-ins: Strong sign-ins

Use a password manager. A different password everywhere. Turn on two step sign in. Passkeys are better still, where offered.

SSH keys: Make a key

An SSH key replaces a password. Create one with a passphrase, and copy only the public half to the server.

ssh-keygen -t ed25519
ssh-copy-id you@your-spark

App secrets: Keys for programs

Programs need keys too. Keep them out of your code and out of Git. Store them in a secrets store or a protected file.

Less is safer: Only what's needed

Give each person their own account. Give only the access the job needs. Remove it when the job ends.

The network: Shut the front door

Don't open services to the internet unless you must. Reach them over a private network instead. Keep a firewall on. And install updates.

If it leaks: Act fast

If a key leaks, revoke it first. Make a new one. Then check what the old one was used for.

Recover: Keep backups

Backups are part of security. Keep a copy somewhere else. Protect it. And practise restoring.

Wrap up

Strong sign-ins, careful keys, and a way back.

Sources

More lessons