From: Marc Weber <marco-oweber@gmx.de>
To: git <git@vger.kernel.org>
Subject: Re: verifying git file contents without checking out history?
Date: Mon, 19 Nov 2012 06:32:50 +0100 [thread overview]
Message-ID: <1353303050-sup-4193@nixos> (raw)
In-Reply-To: <7vtxsmxkcp.fsf@alter.siamese.dyndns.org>
Excerpts from Junio C Hamano's message of Mon Nov 19 05:55:18 +0100 2012:
> Define what you mean by "contents".
contents = the files git archive HEAD would put into an archive, those
determining a build result.
How could the repo be compromised:
1) An attacker triest to find a hash collision in the HEAD tree.
However finding a hash collision which also is a useful attack should
be very hard.
2) The attacker modifies a file the way he likes (thus the attack is
easy), then he tries to modify the history in a way causing the same
commit hash.
Probably this is very hard, too.
Does this make sense? I feared that having a HEAD^ you can manipulate to
change the hash of HEAD makes it easier to cause a collision without the
user noticing.
However adding additional useless files to HEAD could be used to cause a
imaginary hash collision, too. Thus having a second hash would not be of
any benefit. Thus referring to commit by hash (using all hash digits) is
best you can do. I finally got it.
Thanks
Marc Weber
prev parent reply other threads:[~2012-11-19 5:34 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-19 1:50 verifying git file contents without checking out history? Marc Weber
2012-11-19 4:55 ` Junio C Hamano
2012-11-19 5:32 ` Marc Weber [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1353303050-sup-4193@nixos \
--to=marco-oweber@gmx.de \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.