git_shell.rb revision afb19cddf7fe560b1d75716742176e3202c5a6ba
require 'open3'
@command = command
end
def exec
exit 1
end
exit 1 unless @command
if GIT_CMDS.include?(@git_cmd)
# required to pass the ID to the update hook
else
message = "git-shell: Access denied for git command <#{@command}> by #{log_username}."
end
else
message = "git-shell: Attempt to execute disallowed command <#{@command}> by #{log_username}."
puts 'Not allowed command'
end
end
end
cmd = "#{@git_cmd} #{repo_full_path}"
Rails.logger.info "git-shell: executing git command <#{cmd}> for #{log_username}."
end
end
end
end
"user with key #{@key_id}"
end
end