š„Letās Do DevOps post: Cryptographically Signing Your Commits on GitHub with PGPš
Aka, was it really you that pushed this commit?
This blog series focuses on presenting complex DevOps projects as simple and approachable via plain language and lots of pictures. You can do it!
Iāve moved to LetsDoDevOps.com, you can find the article here. This content has a paywall for 1 week, and then will be free starting at 8/27 9a CT. Feedback on the paywall model is welcome!
Hey all!
āGitā is a nearly universal tool for managing code. Itās incredibly influential and pervasive. Itās also really insecure.
āGitHubā is in a similar position ā itās a nearly universal tool among software engineers, and (unsurprisingly), it relies on āgitā a ton. Something that most users donāt recognize is the Author name you see on your PRs on GitHub is whatās configured in your local git install, and that name can be set arbitrarily to anything. Like, anything.
Thatās hilarious and really unsafe.
> git config set user.name "Ronald McDonald"
> git touch stuff && git add . && git commit -m "I promise my name is ronald mcdonald" && ggpush
> git config set user.name "37337 H4x0r"
> git touch stuff2 && git add . && git commit -m "Totally a real person I promise" && ggpush
Weāve been playing around with improving our security posture on GitHub, and there are tons of tools and settings you can deploy thatāll improve things for your orgs.
One of those is called Commit Signature Verification, and itās the process of using a cryptographic operation to āsignā a commit with your private key, which proves that you and only you were the person to construct the code. In theory, this should help prove that the commit wasnāt modified once you generated it, and that you generated it, separate and apart from the key used to push code to GitHub.
Commit verification links your git commit to a GitHub identity ā thatās a huge security boon.
On most pages youāll also see that pretty āVerifiedā badge on your PRs, and that means that the commit is signed cryptographically with a key linked to a GitHub Profile.
Alright, now that weāve talked about why this matters, letās talk about how. Itās surprisingly easy.
Letās Do DevOps
From here on out, all content will be published on Letās Do DevOps. I want to give back to the community as much as Iām able. Please subscribe there to avoid missing any content. Thanks all ā¤.
This content has a paywall for 1 week, and then will be free starting at 8/27/2024 9a CT.
You can find this article here: https://www.letsdodevops.com/p/lets-do-devops-cryptographically