From 118908a1152eb5f9300deca6e5977dd03a6e61d3 Mon Sep 17 00:00:00 2001 From: Isaac Betesh Date: Tue, 18 Nov 2014 12:53:14 -0500 Subject: [PATCH] improved Sinatra example by making it use the ParameterFilter correctly for better security --- examples/sinatra/sinatra_app.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/examples/sinatra/sinatra_app.rb b/examples/sinatra/sinatra_app.rb index fbfd3993..c71315f3 100644 --- a/examples/sinatra/sinatra_app.rb +++ b/examples/sinatra/sinatra_app.rb @@ -4,6 +4,10 @@ require 'exception_notification' class SinatraApp < Sinatra::Base + use Rack::Config do |env| + env["action_dispatch.parameter_filter"] = [:password] # This is highly recommended. It will prevent the ExceptionNotification email from including your users' passwords + end + use ExceptionNotification::Rack, :email => { :email_prefix => "[Example] ",