From 64b33914986ec5c20ee666b8bab23f70bc0cc8bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakobus=20Sch=C3=BCrz?= Date: Sat, 3 Aug 2019 15:21:13 +0200 Subject: [PATCH] a line for each principal --- gitosis/principals.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/gitosis/principals.py b/gitosis/principals.py index 4c8947d..b69ec41 100644 --- a/gitosis/principals.py +++ b/gitosis/principals.py @@ -21,11 +21,12 @@ def serve_principal(cfg, sshUser, principals): TEMPLATE=('command="gitosis-serve %(user)s",no-port-forwarding,' +'no-X11-forwarding,no-agent-forwarding,no-pty %(principals)s') - print TEMPLATE % dict(user=sshUser, - principals=util.getAllowedSSHPrincipals(config=cfg)) + for principal in util.getAllowedSSHPrincipals(config=cfg): + print TEMPLATE % dict(user=sshUser, + principals=principal) - return TEMPLATE % dict(user=sshUser, - principals=util.getAllowedSSHPrincipals(config=cfg)) + return TEMPLATE % dict(user=sshUser, + principals=util.principal) class Main(app.App):