breach-mitigation-rails 0.2.1 → 0.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 552f77a2f8db017504d2357a189bc0c9a154a34e
4
- data.tar.gz: fcb86ce3d3637b5a4aa9a8848ff3e147be1cc80f
3
+ metadata.gz: 480a732f16dc3032e48ef2db07f80824f1c0e51d
4
+ data.tar.gz: edbfde41c332657ae98a6aa1dcd83dc223d32191
5
5
  SHA512:
6
- metadata.gz: cb939e4c02545bb55de00335ebe857d946eb8f3b231df5b50f5a413c5b0ffaeaf0cc287cac45d673557c0ea78f8fe77d6b3e42a34e246aec4b486f24209d672c
7
- data.tar.gz: e1763744407fc1ac94f04e5b834c665e55c0af7f0749cab91dc5dd9db55420e16a98b0088b2753a5d7f2e2b727e741215508e98844cf31986e434befe746c427
6
+ metadata.gz: 48dc6f96c379c4004550d99bfe01b68af776aa8692dbb8bb4c874dd2f5ebe569a55285f4d427b29953a112955ca34b51ea3fb81a0a70805092a7f428a7afc5c5
7
+ data.tar.gz: 06fa934194687b5fda391691c1baf2e238012ed401e9a41358dbc1020a4a71c6e4c87145249262855c253cec404b46b807ad1166751d35abe0bb74a782c0bd64
@@ -10,7 +10,7 @@ module BreachMitigation
10
10
  status, headers, body = @app.call(env)
11
11
 
12
12
  # Only pad HTML/XHTML documents
13
- if headers['Content-Type'] =~ /text\/x?html/ && env['rack.url_scheme'] == 'https'
13
+ if headers['Content-Type'] =~ /text\/x?html/ && Rack::Request.new(env).ssl?
14
14
  # Copy the existing response to a new object
15
15
  response = Rack::Response.new(body, status, headers)
16
16
 
@@ -1,3 +1,3 @@
1
1
  module BreachMitigation
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: breach-mitigation-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bradley Buda