From: Ralf Jung <post@ralfj.de>
To: git@vger.kernel.org
Subject: gitweb bug: Existence if hidden repositories is leaked
Date: Tue, 09 Oct 2012 11:28:53 +0200 [thread overview]
Message-ID: <5073EE55.7010809@ralfj.de> (raw)
Hi list,
I am using gitweb, git-daemon and gitolite on my Debian Squeeze server.
I have some repositories however that I do not want to be available to
the public (currently, that is gitolite-admin only). Those repositories
do not have a "git-daemon-export-ok" file, and the gitweb config contains
# path to git projects (<project>.git)
$projectroot = "/home/git/repositories";
# only show repos which allow daemon access
$export_ok = "git-daemon-export-ok";
I am also using pathinfo to get prettier URLs. However, if I now try to
access gitolite-admin.git in the browser, I get "404 Project Not Found".
If I try to access some repository which dos not actually exist, I am
redirected to the project index. This way, the existence of hidden
repositories is disclosed.
The problem is in the function evaluate_path_info which uses
check_head_link to find out which part of the URL is the project.
Replacing this by check_export_ok fixes the problem.
Kind regards,
Ralf
PS: Please keep me in CC, I am not subscribed.
reply other threads:[~2012-10-09 9:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=5073EE55.7010809@ralfj.de \
--to=post@ralfj.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).