method
generate_csrf_token
v7.0.0 -
Show latest stable
- Class:
ActionController::RequestForgeryProtection
generate_csrf_token()private
No documentation available.
# File actionpack/lib/action_controller/metal/request_forgery_protection.rb, line 519
def generate_csrf_token # :nodoc:
if urlsafe_csrf_tokens
SecureRandom.urlsafe_base64(AUTHENTICITY_TOKEN_LENGTH)
else
SecureRandom.base64(AUTHENTICITY_TOKEN_LENGTH)
end
end