~ubuntu-branches/ubuntu/vivid/gitolite3/vivid-proposed

« back to all changes in this revision

Viewing changes to src/gitolite-shell

  • Committer: Package Import Robot
  • Author(s): David Bremner
  • Date: 2014-05-25 20:09:36 UTC
  • mfrom: (1.1.3)
  • Revision ID: package-import@ubuntu.com-20140525200936-el6hezd1fym50pxh
Tags: 3.6-1
* New upstream release
* Depend on ssh-server instead of openssh-server (Closes: #735176).

Show diffs side-by-side

added added

removed removed

Lines of Context:
123
123
    # more information.
124
124
    unless ( $ENV{GL_BYPASS_ACCESS_CHECKS} ) {
125
125
        my $ret = access( $repo, $user, $aa, 'any' );
126
 
        trace( 1, "access($repo, $user, $aa, 'any')", "-> $ret" );
127
126
        trigger( 'ACCESS_1', $repo, $user, $aa, 'any', $ret );
128
127
        _die $ret . "\n(or you mis-spelled the reponame)" if $ret =~ /DENIED/;
129
128
 
131
130
    }
132
131
 
133
132
    trigger( 'PRE_GIT', $repo, $user, $aa, 'any', $verb );
134
 
    if ($ENV{REQUEST_URI}) {
 
133
    if ( $ENV{REQUEST_URI} ) {
135
134
        _system( "git", "http-backend" );
136
135
    } else {
137
136
        my $repodir = "'$rc{GL_REPO_BASE}/$repo.git'";
158
157
    # after this we should not return; caller expects us to handle it all here
159
158
    # and exit out
160
159
 
161
 
    _die "suspicious characters loitering about '$soc'" if $soc !~ $REMOTE_COMMAND_PATT;
162
160
 
163
161
    my @words = split ' ', $soc;
164
162
    if ( $rc{COMMANDS}{ $words[0] } ) {
 
163
        _die "suspicious characters loitering about '$soc'"
 
164
          if $rc{COMMANDS}{ $words[0] } ne 'ua' and $soc !~ $REMOTE_COMMAND_PATT;
165
165
        trace( 2, "gitolite command", $soc );
166
166
        _system( "gitolite", @words );
167
167
        exit 0;