Re: Suggestion on hashing
- From
- Chris West (Faux) <faux@goeswhere.com>
- Date
- Dec 6, 2011, 01:56 UTC
- Message-ID
- <alpine.DEB.2.00.1112060146121.15104@hoki.goeswhere.com>
- In-Reply-To
- <CACsJy8CO1GtpZVo-oA2eKbQadsXYBEKVLfUH0GONR5jovuvH+Q@mail.gmail.com>
Nguyen Thai Ngoc Duy wrote:
> SHA-1 charateristics (like 20 byte length) are hard coded everywhere > in git, it'd be a big audit.
I was planning to look at this anyway. My branch[1] allows init/add/commit with SHA-256, SHA-512 and all the SHA-3 candidates.
log/fsck/etc. are all broken. Don't even dare try packs. Fixing things is painful but not impossible. I'm not convinced the task is even remotely insurmountable.
(This is not a request-for-comments, just an informational notification. It does not even attempt to address compatability or the like.)
$ make HASH=sha512 -j6
$ PATH=bin-wrappers:..
$ git init && echo hi > foo && git add foo && git commit -m "bang"
Initialized empty Git repository in /.../.git/
[master (root-commit)
8d3ae658dff0c6e398bb4a0d193974e49acfadedfcd61daca42c931ac18d5ac46f0a068e08d81c25d7b79b1c3f4951e4340eeb90f0ef39de355c9bab7e75faba]
bang
1 files changed, 1 insertions(+), 0 deletions(-)
create mode 100644 foo1. (Please use the hash-v0.0.1 tag, I rebase.) gitweb: http://preview.tinyurl.com/bsufh92 git://git.goeswhere.com/git/git.git https://github.com/FauxFaux/git/tree/hash-v0.0.1
--- Chris West (Faux) Freenode #git: FauxFaux https://ssl.goeswhere.com/key-transition-2011-10-10.txt.asc gpg: 408A E4F1 4EA7 33EF 1265 82C1 B195 E1C4 779B A9B2