diff options
author | Richard Ipsum <richard.ipsum@codethink.co.uk> | 2014-02-15 18:53:02 +0000 |
---|---|---|
committer | Richard Ipsum <richard.ipsum@codethink.co.uk> | 2014-02-15 18:53:02 +0000 |
commit | 7e4e22955f61e8fa04a788091431bacfc2115ff0 (patch) | |
tree | 04f8b37c9d1e45a21708c5ce2fdb19fd174163b7 | |
parent | 94be71069c2c5106d9a4d5929dcd1d1a31e2484e (diff) | |
download | gitano-7e4e22955f61e8fa04a788091431bacfc2115ff0.tar.gz |
username -> user
-rw-r--r-- | lib/gitano/auth.lua | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/gitano/auth.lua b/lib/gitano/auth.lua index cd65d2d..7cab4c0 100644 --- a/lib/gitano/auth.lua +++ b/lib/gitano/auth.lua @@ -54,7 +54,6 @@ end -- TODO: this must be split up, it is far too long local function is_authorized(user, source, cmdline) local repo_root = os.getenv("GITANO_ROOT") - local username = user local keytag = "" local authorized = false @@ -77,7 +76,7 @@ local function is_authorized(user, source, cmdline) local admin_conf = load_admin_conf(repo_root) - if admin_conf.groups["gitano-admin"].filtered_members[username] then + if admin_conf.groups["gitano-admin"].filtered_members[user] then log.set_level(start_log_level) end @@ -86,7 +85,7 @@ local function is_authorized(user, source, cmdline) end ip = os.getenv("REMOTE_ADDR") or "unknown ip" - log.syslog.info("Client connected from", ip, "as", username, + log.syslog.info("Client connected from", ip, "as", user, "(" .. keytag .. ")", "Executing command:", cmdline) local cmd = command.get(parsed_cmdline[1]) @@ -115,7 +114,7 @@ local function is_authorized(user, source, cmdline) return nil end - local context = {source = source, user = username, keytag = keytag} + local context = {source = source, user = user, keytag = keytag} local action, reason = cmd.prep(admin_conf, repo, parsed_cmdline, context) if not action then |