devel/git: Git via Apache 2.4 HTTPS - info/refs not valid: could not determine hash algorithm

Hartmann, O. o.hartmann at walstatt.org
Mon Mar 29 17:56:25 UTC 2021


On Mon, 29 Mar 2021 11:42:28 +0200
Michael Gmelin <freebsd at grem.de> wrote:

> On Sun, 28 Mar 2021 13:08:19 +0200
> "Hartmann, O." <ohartmann at walstatt.org> wrote:
> 
> > What am I missing here?
> >   
> 
> The man page of git-http-backend has an apache2 example[0].
> Also, the top answer to this stackoverflow question might give you a
> hint: https://stackoverflow.coo-set-up-git-over-http
> 
> Best,
> Michael
> 
> [0]https://www.freebsd.org/cgi/man.cgi?query=git-http-backend&apropos=0&sektion=0&manpath=FreeBSD+12.2-RELEASE+and+Ports&arch=default&format=html
> 
> 

Hello Michael,

thanks for responding.
The first tip I came across was the Stackoverflow HowTo - whatever I did and do, it
doesn't work. I also tried the several variants shown in [0], starting with the simplest
towards more complex ones.

Following strictly the reference at 

https://stackoverflow.com/questions/26734933/how-to-set-up-git-over-http

with minor local adaptions (for FreeBSD and the Git base folder), even with anonymous
access allowed the failure is the same as with some Basic authentication via LDAP.

As decribed in my initial email: first access with a "git push -u origin master" is
logged by Apache with 401, requesting credentials. If provided, the line
(httpd-access.log):

xx.xx.xx.xx - USERNAME [29/Mar/2021:17:44:55 +0000] "GET \
/git/test.git/info/refs?service=git-upload-pack HTTP/1.1" 200 1689032 "-" "git/2.31.0" \
323 1691601

status code 200 indicates OK - so authetication is all right and I should proceed, but I
get on the client

fatal: https://[url]/git/test.git/info/refs not valid: could not
determine hash algorithm; is this a git repository?

On both sides, I had disabled sslVerify (due to self signed cert issue with git, another
pitfall) and according to stackoverflow howto, hooks are also prepared and the root
folder and its subsequent folders /pool/gitbase (PROJECT_ROOT) is owned by www:www and
has ACL 0775 set.

And this is why it gets desperate to me ...

Kind regards,

O. Hartmann
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 228 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20210329/454ca50b/attachment.sig>


More information about the freebsd-ports mailing list