[sysadmin-bin] Disallow the creation of new repositories under git.g.o



commit 8876bb2b12964b74b86b0fd66ad14bc8660a3338
Author: Andrea Veri <averi redhat com>
Date:   Tue May 29 12:05:21 2018 +0200

    Disallow the creation of new repositories under git.g.o

 run-git-or-special-cmd | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)
---
diff --git a/run-git-or-special-cmd b/run-git-or-special-cmd
index cdf5668..82ce519 100755
--- a/run-git-or-special-cmd
+++ b/run-git-or-special-cmd
@@ -71,11 +71,6 @@ def rungitcommand(args):
     write_git_cmds = [ 'git-receive-pack' ]
 
     special_cmds = {
-        'create-repository': '/home/admin/bin/git/create-repository',
-        'finish-import': '/home/admin/bin/git/finish-import',
-        # These allow 'git push --exec=force/import'
-        'force': '/home/admin/bin/git/receive-pack-force',
-        'import': '/home/admin/bin/git/receive-pack-import',
     }
 
     if args[0] in read_git_cmds or args[0] in write_git_cmds:
@@ -85,7 +80,7 @@ def rungitcommand(args):
         cmd = [special_cmds[args[0]]]
         cmd.extend(args[1:])
     else:
-        print >>sys.stderr, 'Unknown command.'
+        print >>sys.stderr, 'Unknown or disallowed command.'
         sys.exit(1)
 
     os.execv(cmd[0], cmd)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]