finds.dev

mikepound/tls-exercises

Programming secure connections in Python and Java

View on GitHub

★ 272JavaNOASSERTIONupdated Aug 2025

// the take

A hands-on exercise set for learning TLS in Python and Java, covering basic SSL connections, mutual TLS authentication, and certificate pinning. It's companion material for a Computerphile-affiliated O'Reilly course by a University of Nottingham lecturer. Aimed at developers who know the language but have never touched TLS code directly.

The three exercises build on each other in the right order — basic connection, then mTLS, then pinning — which matches how you'd actually need TLS features in production. The CA directory is fully materialized with real OpenSSL-generated certs and keys, so you're not fighting certificate setup before you even start the exercises. Having answers checked in means you can diff your attempt against a working solution without hunting for one. Both Python ssl and Java javax.net.ssl are covered, which surfaces how differently the two ecosystems expose the same underlying concepts.

The certificates were generated with OpenSSL 1.1.1b and the Python exercises target 3.6/3.7 — both well past end of life, so learners on current tooling may hit subtle compatibility issues before they even get to the TLS concepts. Private keys are committed to the repo (ca/intermediate/private/), which is fine for a throwaway teaching CA but trains bad habits in exactly the audience that needs good ones. There's no exercise covering TLS 1.3-specific features or session resumption, so the coverage stops short of what you'd care about in 2025. No automated test or verification step — you run the client and server manually and infer success from the absence of exceptions, which is a shaky feedback loop for learners.

We read the README, the directory tree and a key source file in July 2026. Nobody pays to be listed. How we judge →

// at a glance

Stars
272
Forks
142
Language
Java
License
NOASSERTION
Last commit
6 Aug 2025

// nearby

If tls-exercises isn't quite it.

All repos →