This file is indexed.

/usr/lib/ruby/vendor_ruby/chef_zero/endpoints/role_environments_endpoint.rb is in chef-zero 3.1.3-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
require 'json'
require 'chef_zero/rest_base'

module ChefZero
  module Endpoints
    # /roles/NAME/environments
    class RoleEnvironmentsEndpoint < RestBase
      def get(request)
        role = JSON.parse(get_data(request, request.rest_path[0..3]), :create_additions => false)
        json_response(200, [ '_default' ] + (role['env_run_lists'].keys || []))
      end
    end
  end
end