Permalink
Browse files

Merge pull request #178 from jsyeo/jsyeo-csrf-protection

Protect upmin controllers from CSRF attacks
  • Loading branch information...
mbrookes committed Mar 31, 2016
2 parents 499501b + e4e3125 commit 49252e6ae6655642d5c0a23e4ef2fca2535212e7
Showing with 5 additions and 0 deletions.
  1. +5 −0 app/controllers/upmin/application_controller.rb
@@ -1,4 +1,9 @@
module Upmin
class ApplicationController < ActionController::Base
if ::Rails.version.to_i < 4
protect_from_forgery
else
protect_from_forgery with: :exception
end
end
end

0 comments on commit 49252e6

Please sign in to comment.