QA
Senior LevelGit & GitHub

How does Git handle Object Format migration from SHA-1 to SHA-256 cryptographic hashes?

❓ Interview Prompt: Explain SHA-1 collision vulnerabilities (SHAttered attack), 256-bit SHA-256 object formats, loose object compatibility layers, and repository migration.

Git is migrating from 160-bit SHA-1 to 256-bit SHA-256 object formats to eliminate cryptographic collision vulnerabilities (SHAttered attack) while maintaining translation compatibility layers.

Code Implementation Example

bash
git init --object-format=sha256 my-secure-repo
💡Initializing a Git repository using 256-bit SHA-256 cryptographic hashing.
🎯 Interview Key Takeaway

Git is migrating from SHA-1 to SHA-256 object formats to eliminate cryptographic collision vulnerabilities.

#SHA-256#SHAttered#Cryptography#Senior
Back to all Git & GitHub Questions→

More Git & GitHub Interview Questions

Beginner LevelGit & GitHub

Compare git rebase versus git merge and explain how git bisect finds regressions.

Beginner LevelGit & GitHub

What is the difference between git init and git clone?

Beginner LevelGit & GitHub

What are the Three Trees in Git (Working Directory, Staging Area / Index, Commit History)?