Force user to be System user?

Martin Geisler mg at lazybytes.net
Thu Aug 6 16:42:47 CDT 2009


On Thu, Aug 6, 2009 at 21:42, Michael Thomas<mlists at bigrideau.com> wrote:
>
>
>  Noob question but googling provided no answers.
>
> Is there a way to force the user name of the commiter to be that of the
> user account  being used? My naive understanding is that using -u one
> can make the user be anything one wants?

That is not naive -- that is correct :-) Mercurial is a distributed
system where everybody can make commits while being offline. As such,
there is nothing you can do to prevent me from using a made up
username for my local commit.

The only thing you can do is to refuse pulling changesets from me with
strange usernames.

> In that scenario how do people audit who has commited what?

You can ask people to sign their repository with the gpg extension
before pushing. It is enough to sign the tip before pushing/pulling.

I worked on an extension that would make it easy to embed signatures
into every changeset:

  http://bitbucket.org/mg/commitsigs/

As far as I remember, it already does all the basic stuff correctly.
But it has not been tested much. Some people wanted to finish it, but
nothing ever came from that.

-- 
Martin Geisler



More information about the Mercurial mailing list