This file is indexed.

/usr/lib/ruby/vendor_ruby/rack/cache.rb is in ruby-rack-cache 1.2-4.

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
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
require 'rack'

# = HTTP Caching For Rack
#
# Rack::Cache is suitable as a quick, drop-in component to enable HTTP caching
# for Rack-enabled applications that produce freshness (+Expires+, +Cache-Control+)
# and/or validation (+Last-Modified+, +ETag+) information.
#
# * Standards-based (RFC 2616 compliance)
# * Freshness/expiration based caching and validation
# * Supports HTTP Vary
# * Portable: 100% Ruby / works with any Rack-enabled framework
# * Disk, memcached, and heap memory storage backends
#
# === Usage
#
# Create with default options:
#   require 'rack/cache'
#   Rack::Cache.new(app, :verbose => true, :entitystore => 'file:cache')
#
# Within a rackup file (or with Rack::Builder):
#   require 'rack/cache'
#   use Rack::Cache do
#     set :verbose, true
#     set :metastore, 'memcached://localhost:11211/meta'
#     set :entitystore, 'file:/var/cache/rack'
#   end
#   run app
module Rack::Cache
  autoload :Request,      'rack/cache/request'
  autoload :Response,     'rack/cache/response'
  autoload :Context,      'rack/cache/context'
  autoload :Storage,      'rack/cache/storage'
  autoload :CacheControl, 'rack/cache/cachecontrol'

  # Create a new Rack::Cache middleware component that fetches resources from
  # the specified backend application. The +options+ Hash can be used to
  # specify default configuration values (see attributes defined in
  # Rack::Cache::Options for possible key/values). When a block is given, it
  # is executed within the context of the newly create Rack::Cache::Context
  # object.
  def self.new(backend, options={}, &b)
    Context.new(backend, options, &b)
  end
end