Module: Cloudfront::Rails::Railtie::CheckTrustedProxies

Defined in:
lib/cloudfront/rails/railtie.rb

Instance Method Summary collapse

Instance Method Details

#trusted_proxy?(ip) ⇒ Boolean

Returns:

  • (Boolean)


6
7
8
# File 'lib/cloudfront/rails/railtie.rb', line 6

def trusted_proxy?(ip)
  ::Rails.application.config.cloudfront.ips.any?{ |proxy| proxy === ip } || super
end