title: GIT support for branch based user authorization - Best Practices or Tools?
body: <p>For a product based GIT repository, wherein there are branches for maintenance, testing as well as future development, how do I control user access to these branches. By access, I mean that even though others may read from it, they should not be able to inadvertently push changes to the repo.</p>
  
  <p>For example,</p>
  
  <pre><code>A - B - C - D - E - F -&gt; master
      |   |       |
      V1  V2'     exp
          |
          V2
  </code></pre>
  
  <p>"B" is the commit used for Branch with tag V1 - meant for released version of the product. Only support/maintenance engineers should have access to this. </p>
  
  <p>C is used for a recently frozen pre-release product V2' and should only allow critical show-stopper bug fixes, so only certain developers and the Testing team should have access to it. when V2 is released from this branch, only Support should access it as is the case with V1.</p>
  
  <p>E is used for branching off for testing a new feature for future V3 - only developers and not Support should access it.</p>
  
  <p>"master" changes should only be merged on a request basis (similar to say, GitHub) by a central integration team.</p>
  
  <p>How can the above be achieved with git? I recall seeing gitosis and some other external tools - are these essential for secure operation with git or are there any other best practices?</p>
  
  <p>Thanks.</p>
  
  <p><strong>ADDED</strong>
  <a href="http://nvie.com/posts/a-successful-git-branching-model/" rel="noreferrer" title="One of the best practice branching models used by gitflow">Gitflow best practice branching model</a></p>