GeekCoding101 make your way to geek

Cybersecurity Tutorials and Notes

12 posts on cybersecurity, newest first.

12posts
2023first post

This page collects GeekCoding101’s hands-on cybersecurity posts. They cover how authentication actually works (passwords, HTTP Basic Auth, JWT, OAuth 2.0, ID tokens vs access tokens), how to secure AI tooling such as MCP servers and Claude Code, threat modeling with STRIDE, certificates with OpenSSL, and reverse engineering with Ghidra MCP. Most posts include code or commands you can run on your own machine. Everything is free to read, with no sign-up.

Start here

If you want to…ReadWhat you’ll get
Understand the OAuth 2.0 grant typesOAuth 2.0 Grant Types Explained (Is PKCE One?)Authorization code, implicit, password, client credentials and refresh tokens compared, plus where PKCE fits
Follow the authorization code flow request by requestOAuth 2.0 Authorization Code Flow, Step by StepEach redirect and request, and why the server returns a code instead of an access token
Know which token goes whereID Token vs Access Token: What Each One Is For (with a Demo)Real decode and validation runs
Protect an MCP serverMCP Authorization: Protect an MCP Server with OAuth 2.1The 401, protected resource metadata, and a runnable Python SDK server
Stop Claude Code permission prompts safelyClaude —dangerously-skip-permissions: What It Does and When to Use ItThe six permission modes and safer alternatives
Threat-model a systemSTRIDE Threat Modeling Explained with an ExampleAll six STRIDE categories applied to a chat app
Reverse engineer a binary with AI helpGhidra MCP: Let AI Help You Reverse Engineer BinariesInstall Ghidra 12.1.4 and GhidraMCP 2.0, then find Adler-32 in a stripped binary

Authentication fundamentals (Auth101 series)

The Auth101 series builds up authentication in Node.js one method at a time. Reading the posts in order works best:

  1. Password Authentication in Node.js: A Step-by-Step Guide. The username-and-password baseline that most systems still start from.
  2. HTTP Basic Authentication Explained (RFC 7617). Covers the Authorization header, Base64-encoded username:password, why it must run over HTTPS, and a Node.js and TypeScript middleware example.
  3. Unlocking Web Security: Master JWT Authentication. Explains JWT claims, token structure and signing algorithms, then builds JWT auth from scratch in Node.js with complete, runnable code.

OAuth 2.0 and tokens

OAuth is about delegated access: letting an app act for a user without handing it the user’s password. These three posts go from the overview down to the details:

Securing AI agents and MCP

AI coding agents and MCP servers bring new versions of old problems: who is calling, and what are they allowed to do?

Threat modeling

Certificates and PKI

  • Mastering OpenSSL Command and NSS Database Management. A practical OpenSSL and certutil guide. It covers inspecting certificates, managing PKCS#12 (PFX) files, and working with the NSS certificate database.

Reverse engineering

FAQ

Where should I start if I’m new to authentication? Start with the Auth101 series in order: password authentication, then HTTP Basic Auth, then JWT. After that, move on to OAuth 2.0 grant types.

What are the OAuth 2.0 grant types? The classic set is authorization code, implicit, resource owner password credentials and client credentials, plus refresh tokens for getting new access tokens. The grant types post compares them and explains where PKCE fits.

What’s the difference between an ID token and an access token? An ID token is for your app: it says who signed in. An access token is for your API: it says what the caller is allowed to do. The ID token vs access token post shows both being decoded and validated.

Is HTTP Basic Authentication secure? Only over HTTPS. The credentials are just Base64-encoded, not encrypted, so anyone who can read the traffic can read the password. The HTTP Basic Auth post covers this and shows a middleware example.

Is GeekCoding101 free? Yes. Every post is free to read, and there is no sign-up.