2

I have a gitosis system that seems to be working correctly except for a common problem we run into where I can't distingush permissions between two users who have the same username, but different hosts.

For example:

jsmith@computer.pub 's SSH key is in the key folder.

And so is jsmith@machine.pub 's SSH is also in the key folder.

These two jsmith's are two different people on two different computers. However, when I configure them in the gitosis.conf file with the usernames jsmith@computer or jsmith@machine, it seems like each user just gets the same permission.

Can gitosis not distinguish the full username (name and host)? If not, how do I deal with multiple users accessing our system with common usernames? Thanks for any help.

bryan kennedy
  • 1,721
  • 3
  • 16
  • 31

1 Answers1

2

Well, I finally figured out what my difficulty was.

Gitosis doesn't care what you name the key files in the keydir. So, even though I have two keys that both have username@host1 and username@host2 I can name those files username_host1 and username_host2 in the keydir. Heck, I could call them raspberry and apple. Then I just need to use the filenames I defined in the gitosis.conf.

Since no one answered, maybe no one else has this issue, but I figured I should report in case someone else stumbled on this difficulty.

bryan kennedy
  • 1,721
  • 3
  • 16
  • 31
  • if you run into clashing usernames often, you might want to consider modifying your policy from (fi)(lastname) to (fi)(mi)(lastname) ... *shrug* – cpbills Feb 25 '11 at 22:25
  • We regularly use external contractors, and I have no control over their usernames, so any solution for this type of thing should allow for username collisions. Gitosis does, I just didn't know how to implement it. – bryan kennedy Feb 27 '11 at 02:31