author | Andreas Ericsson <ae@op5.se> | |
Fri, 17 Apr 2009 08:20:11 +0000 (10:20 +0200) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Tue, 21 Apr 2009 07:05:21 +0000 (00:05 -0700) | ||
commit | 47abd85ba06ed7209d1caa3e5ac7cc6b232bece4 | |
tree | b8d5bde85778454775769c6d5cfa680cb9615916 | tree | snapshot |
parent | 66996ecc28f001d3dcc73090717bb8c6e47c0d75 | commit | diff |
fetch: Strip usernames from url's before storing them
When pulling from a remote, the full URL including username
is by default added to the commit message. Since it adds
very little value but could be used by malicious people to
glean valid usernames (with matching hostnames), we're far
better off just stripping the username before storing the
remote URL locally.
Note that this patch has no lasting visible effect when
"git pull" does not create a merge commit. It simply
alters what gets written to .git/FETCH_HEAD, which is used
by "git merge" to automagically create its messages.
Signed-off-by: Andreas Ericsson <ae@op5.se>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
When pulling from a remote, the full URL including username
is by default added to the commit message. Since it adds
very little value but could be used by malicious people to
glean valid usernames (with matching hostnames), we're far
better off just stripping the username before storing the
remote URL locally.
Note that this patch has no lasting visible effect when
"git pull" does not create a merge commit. It simply
alters what gets written to .git/FETCH_HEAD, which is used
by "git merge" to automagically create its messages.
Signed-off-by: Andreas Ericsson <ae@op5.se>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-fetch.c | diff | blob | history | |
transport.c | diff | blob | history | |
transport.h | diff | blob | history |