securenative 0.1.33 → 0.1.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a3fe3afee2e1f23bf0d5170952904e4e66078fb392a791dee566da36b39df2e7
4
- data.tar.gz: 8b36837fe92f5a823a12d456cfc33f462a754bac28917a85a736fc37988ec72c
3
+ metadata.gz: 8d37acae083e992b50287c1531d21bf1dc5794a94de5198dd3e7cf0dd29fd53c
4
+ data.tar.gz: 0aec5e752e9cb16c05b3ba70e4f05d9e842e34c63198575815c1f7f9f8590a52
5
5
  SHA512:
6
- metadata.gz: ee1cde9a072ac6292dcb80ca41da67d925ede12be54f10c79ff59c17a2be29b566b2a0ae4cdcd17c69446e996bcc863ae4e98c4079748b184842fb2c55f171f1
7
- data.tar.gz: c2c3cd008ffd8719acf11d4b31792b303cd649f090c2bb81567995fe5802d205c97601ff050f03d8bd33c1931a9cc65cca6873405df674768cfcca3a134c9f38
6
+ metadata.gz: a69cf0db09fa4de8d1e3973f718d880d0ec43cef652b3a556fbfd57188907a52f0ecce1b1f452088423e05e4b44453da21c1f84f30a6ec510c906fff7217ea9c
7
+ data.tar.gz: 2e1949c2c0b4924eab51b93a36a5e092516830edb424ef7914389b9ec6b1d235cc50f5f62b36e7ef72d0343fe05ee7c871c486ef57a89cfd061332b886a63e17
@@ -1,61 +1,61 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- securenative (0.1.33)
4
+ securenative (0.1.34)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
8
8
  specs:
9
- actioncable (6.0.3.3)
10
- actionpack (= 6.0.3.3)
9
+ actioncable (6.0.3.4)
10
+ actionpack (= 6.0.3.4)
11
11
  nio4r (~> 2.0)
12
12
  websocket-driver (>= 0.6.1)
13
- actionmailbox (6.0.3.3)
14
- actionpack (= 6.0.3.3)
15
- activejob (= 6.0.3.3)
16
- activerecord (= 6.0.3.3)
17
- activestorage (= 6.0.3.3)
18
- activesupport (= 6.0.3.3)
13
+ actionmailbox (6.0.3.4)
14
+ actionpack (= 6.0.3.4)
15
+ activejob (= 6.0.3.4)
16
+ activerecord (= 6.0.3.4)
17
+ activestorage (= 6.0.3.4)
18
+ activesupport (= 6.0.3.4)
19
19
  mail (>= 2.7.1)
20
- actionmailer (6.0.3.3)
21
- actionpack (= 6.0.3.3)
22
- actionview (= 6.0.3.3)
23
- activejob (= 6.0.3.3)
20
+ actionmailer (6.0.3.4)
21
+ actionpack (= 6.0.3.4)
22
+ actionview (= 6.0.3.4)
23
+ activejob (= 6.0.3.4)
24
24
  mail (~> 2.5, >= 2.5.4)
25
25
  rails-dom-testing (~> 2.0)
26
- actionpack (6.0.3.3)
27
- actionview (= 6.0.3.3)
28
- activesupport (= 6.0.3.3)
26
+ actionpack (6.0.3.4)
27
+ actionview (= 6.0.3.4)
28
+ activesupport (= 6.0.3.4)
29
29
  rack (~> 2.0, >= 2.0.8)
30
30
  rack-test (>= 0.6.3)
31
31
  rails-dom-testing (~> 2.0)
32
32
  rails-html-sanitizer (~> 1.0, >= 1.2.0)
33
- actiontext (6.0.3.3)
34
- actionpack (= 6.0.3.3)
35
- activerecord (= 6.0.3.3)
36
- activestorage (= 6.0.3.3)
37
- activesupport (= 6.0.3.3)
33
+ actiontext (6.0.3.4)
34
+ actionpack (= 6.0.3.4)
35
+ activerecord (= 6.0.3.4)
36
+ activestorage (= 6.0.3.4)
37
+ activesupport (= 6.0.3.4)
38
38
  nokogiri (>= 1.8.5)
39
- actionview (6.0.3.3)
40
- activesupport (= 6.0.3.3)
39
+ actionview (6.0.3.4)
40
+ activesupport (= 6.0.3.4)
41
41
  builder (~> 3.1)
42
42
  erubi (~> 1.4)
43
43
  rails-dom-testing (~> 2.0)
44
44
  rails-html-sanitizer (~> 1.1, >= 1.2.0)
45
- activejob (6.0.3.3)
46
- activesupport (= 6.0.3.3)
45
+ activejob (6.0.3.4)
46
+ activesupport (= 6.0.3.4)
47
47
  globalid (>= 0.3.6)
48
- activemodel (6.0.3.3)
49
- activesupport (= 6.0.3.3)
50
- activerecord (6.0.3.3)
51
- activemodel (= 6.0.3.3)
52
- activesupport (= 6.0.3.3)
53
- activestorage (6.0.3.3)
54
- actionpack (= 6.0.3.3)
55
- activejob (= 6.0.3.3)
56
- activerecord (= 6.0.3.3)
48
+ activemodel (6.0.3.4)
49
+ activesupport (= 6.0.3.4)
50
+ activerecord (6.0.3.4)
51
+ activemodel (= 6.0.3.4)
52
+ activesupport (= 6.0.3.4)
53
+ activestorage (6.0.3.4)
54
+ actionpack (= 6.0.3.4)
55
+ activejob (= 6.0.3.4)
56
+ activerecord (= 6.0.3.4)
57
57
  marcel (~> 0.3.1)
58
- activesupport (6.0.3.3)
58
+ activesupport (6.0.3.4)
59
59
  concurrent-ruby (~> 1.0, >= 1.0.2)
60
60
  i18n (>= 0.7, < 2)
61
61
  minitest (~> 5.1)
@@ -64,7 +64,7 @@ GEM
64
64
  addressable (2.7.0)
65
65
  public_suffix (>= 2.0.2, < 5.0)
66
66
  builder (3.2.4)
67
- codecov (0.2.11)
67
+ codecov (0.2.12)
68
68
  json
69
69
  simplecov
70
70
  concurrent-ruby (1.1.7)
@@ -177,29 +177,29 @@ GEM
177
177
  rack
178
178
  rack-test (1.1.0)
179
179
  rack (>= 1.0, < 3)
180
- rails (6.0.3.3)
181
- actioncable (= 6.0.3.3)
182
- actionmailbox (= 6.0.3.3)
183
- actionmailer (= 6.0.3.3)
184
- actionpack (= 6.0.3.3)
185
- actiontext (= 6.0.3.3)
186
- actionview (= 6.0.3.3)
187
- activejob (= 6.0.3.3)
188
- activemodel (= 6.0.3.3)
189
- activerecord (= 6.0.3.3)
190
- activestorage (= 6.0.3.3)
191
- activesupport (= 6.0.3.3)
180
+ rails (6.0.3.4)
181
+ actioncable (= 6.0.3.4)
182
+ actionmailbox (= 6.0.3.4)
183
+ actionmailer (= 6.0.3.4)
184
+ actionpack (= 6.0.3.4)
185
+ actiontext (= 6.0.3.4)
186
+ actionview (= 6.0.3.4)
187
+ activejob (= 6.0.3.4)
188
+ activemodel (= 6.0.3.4)
189
+ activerecord (= 6.0.3.4)
190
+ activestorage (= 6.0.3.4)
191
+ activesupport (= 6.0.3.4)
192
192
  bundler (>= 1.3.0)
193
- railties (= 6.0.3.3)
193
+ railties (= 6.0.3.4)
194
194
  sprockets-rails (>= 2.0.0)
195
195
  rails-dom-testing (2.0.3)
196
196
  activesupport (>= 4.2.0)
197
197
  nokogiri (>= 1.6)
198
198
  rails-html-sanitizer (1.3.0)
199
199
  loofah (~> 2.3)
200
- railties (6.0.3.3)
201
- actionpack (= 6.0.3.3)
202
- activesupport (= 6.0.3.3)
200
+ railties (6.0.3.4)
201
+ actionpack (= 6.0.3.4)
202
+ activesupport (= 6.0.3.4)
203
203
  method_source
204
204
  rake (>= 0.8.7)
205
205
  thor (>= 0.20.3, < 2.0)
@@ -242,7 +242,7 @@ GEM
242
242
  thread_safe (~> 0.1)
243
243
  url_mount (0.2.1)
244
244
  rack
245
- webmock (3.9.1)
245
+ webmock (3.9.2)
246
246
  addressable (>= 2.3.6)
247
247
  crack (>= 0.3.2)
248
248
  hashdiff (>= 0.4.0, < 2.0.0)
@@ -35,8 +35,11 @@ module SecureNative
35
35
 
36
36
  def self.get_headers(request)
37
37
  begin
38
- # Note: At the moment we're filtering out everything but user-agent since ruby's payload is way too big
39
- { 'user-agent' => request.env['HTTP_USER_AGENT'] }
38
+ headers = []
39
+ request.headers.env.select { |k, _| k.in?(ActionDispatch::Http::Headers::CGI_VARIABLES) || k =~ /^HTTP_/ }.each { |header|
40
+ headers.append(header[0].downcase.gsub("http_", "").gsub("_", "-"))
41
+ }
42
+ return headers
40
43
  rescue StandardError
41
44
  nil
42
45
  end
@@ -37,8 +37,11 @@ module SecureNative
37
37
 
38
38
  def self.get_headers(request)
39
39
  begin
40
- # Note: At the moment we're filtering out everything but user-agent since ruby's payload is way too big
41
- {'user-agent' => request.env['HTTP_USER_AGENT']}
40
+ headers = []
41
+ request.headers.env.select { |k, _| k.in?(ActionDispatch::Http::Headers::CGI_VARIABLES) || k =~ /^HTTP_/ }.each { |header|
42
+ headers.append(header[0].downcase.gsub("http_", "").gsub("_", "-"))
43
+ }
44
+ return headers
42
45
  rescue StandardError
43
46
  nil
44
47
  end
@@ -35,8 +35,11 @@ module SecureNative
35
35
 
36
36
  def self.get_headers(request)
37
37
  begin
38
- # Note: At the moment we're filtering out everything but user-agent since ruby's payload is way too big
39
- {'user-agent' => request.env['HTTP_USER_AGENT']}
38
+ headers = []
39
+ request.headers.env.select { |k, _| k.in?(ActionDispatch::Http::Headers::CGI_VARIABLES) || k =~ /^HTTP_/ }.each { |header|
40
+ headers.append(header[0].downcase.gsub("http_", "").gsub("_", "-"))
41
+ }
42
+ return headers
40
43
  rescue StandardError
41
44
  nil
42
45
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SecureNative
4
- VERSION = '0.1.33'
4
+ VERSION = '0.1.34'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: securenative
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.33
4
+ version: 0.1.34
5
5
  platform: ruby
6
6
  authors:
7
7
  - SecureNative
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-10-04 00:00:00.000000000 Z
11
+ date: 2020-10-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler