Ruby on Rails | Screencasts | Download | Documentation | Weblog | Community | Source

Ticket #11578: filter_parameter_logging__by_default.diff

File filter_parameter_logging__by_default.diff, 0.6 kB (added by yaroslav, 3 months ago)
  • railties/helpers/application.rb

    old new  
    77  # See ActionController::RequestForgeryProtection for details 
    88  # Uncomment the :secret if you're not using the cookie session store 
    99  protect_from_forgery # :secret => '<%= app_secret %>' 
     10   
     11  # Filter parameter logging for all fields with names like "password". This prevents the logging of your users' passwords. 
     12  filter_parameter_logging :password 
    1013end