1 points · by MidnightRocket · 7y ago · 2 comments
I imagine that either the SHA-1 hash of the commit is signed, or the working tree is directly signed, using the preferred hashing algorithm set in my GPG settings.
Because if it is just the SHA-1 hash of the commit is signed, then someone could make a collision attack on that hash, and introducing malicious code.
A good read on git hash https://link.medium.com/9S9R0cE5GV