Class: Gitlab::RequestForgeryProtection::Controller

Inherits:
BaseActionController show all
Defined in:
lib/gitlab/request_forgery_protection.rb

Instance Method Summary collapse

Methods included from ContentSecurityPolicyPatch

#content_security_policy_with_context

Constructor Details

#initializeController

Returns a new instance of Controller.



12
13
14
15
16
17
18
# File 'lib/gitlab/request_forgery_protection.rb', line 12

def initialize
  super

  # Squelch noisy and unnecessary "Can't verify CSRF token authenticity." messages.
  # X-Csrf-Token is only one authentication mechanism for API helpers.
  self.logger = ActiveSupport::Logger.new(File::NULL)
end

Instance Method Details

#indexObject



20
21
22
# File 'lib/gitlab/request_forgery_protection.rb', line 20

def index
  head :ok
end