Skip to content

Instantly share code, notes, and snippets.

@NeilMadden
NeilMadden / crypto.py
Last active February 4, 2025 14:06
A Lazy Developer’s Guide to Modern Cryptography
#!/usr/bin/env python3
# Copyright 2024 Neil Madden.
# License: https://creativecommons.org/licenses/by-sa/4.0/deed.en.
# Like this? I do training courses & consultancy:
# https://illuminated-security.com/
import hashlib
import math
import os