2

I have been searching, but I couldn't find a tutorial with a step by step guide to creating authentication for Mercurial. From what I have found, a lot of people are pointing to this resource, but it doesn't seem to show what I am trying to achieve: http://mercurial.selenic.com/wiki/PublishingRepositories

Can someone please show me where I can find a guide to setup authentication with Mercurial? HTTPS, or public key system, they both work!

Thank you

3
  • authentication heavy depends from access protocol. http OR ssh, you have to select Feb 26, 2012 at 6:21
  • Lenny is End of Life.
    – Zoredache
    Feb 26, 2012 at 8:23
  • @Zoredache Should I be upgrading to Squeeze?
    – Strawberry
    Feb 26, 2012 at 11:58

1 Answer 1

3

The page you've found has the information for HTTP, it's in section 6.3: Adding authentication. You need to configure Apache to do Basic authentication for requests to hgwebdir.cgi, that's all.

Just remember that Mercurial does not authenticate HTTP users. It's the job of the front-end webserver, such as Apache. That has the advantage that you can re-use your existing infrastructure for authentication: if you've already got a setup where Apache uses LDAP for Active Directory authentication, then Mercurial will inherit that.

For SSH you can look in the Hg Book and the Shared SSH and Multiple Committers wiki pages. Here you must remember that access control boils down to normal file system permissions once the user has been logged into the server.

Finally, I wrote a guide about interacting with remote repositories that might contain a hint or two that you can use.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .