# File mod_docs/cgi.rb, line 35
  def scan_cgi(script_name, request_path)
    Request.scan(request_path) do |cgi_script_name, path_info|
      if (cgi_script_name == script_name) then
        break
      end
      subpath = cgi_script_name[(script_name.length)..-1]
      cgi_local_path = File.expand_path(@base_dir + http2local(subpath))
      if (cgi_local_path !~ @local_path_check) then
        next
      end
      if (File.file? cgi_local_path) then
        return cgi_script_name, cgi_local_path
      end
    end
    raise HTTPError.new(404)    # Not Found
  end