tcell_agent 2.2.1 → 2.5.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (84) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE +2 -2
  3. data/bin/tcell_agent +6 -11
  4. data/lib/tcell_agent/agent.rb +18 -13
  5. data/lib/tcell_agent/config_initializer.rb +2 -5
  6. data/lib/tcell_agent/configuration.rb +6 -6
  7. data/lib/tcell_agent/hooks/login_fraud.rb +1 -1
  8. data/lib/tcell_agent/instrumentation/cmdi.rb +32 -0
  9. data/lib/tcell_agent/instrumentation/lfi.rb +55 -9
  10. data/lib/tcell_agent/instrumentation/monkey_patches/ruby_2/file.rb +21 -0
  11. data/lib/tcell_agent/instrumentation/monkey_patches/ruby_2/io.rb +75 -0
  12. data/lib/tcell_agent/instrumentation/monkey_patches/ruby_2/kernel.rb +80 -0
  13. data/lib/tcell_agent/instrumentation/monkey_patches/ruby_3/file.rb +21 -0
  14. data/lib/tcell_agent/instrumentation/monkey_patches/ruby_3/io.rb +75 -0
  15. data/lib/tcell_agent/instrumentation/monkey_patches/ruby_3/kernel.rb +80 -0
  16. data/lib/tcell_agent/instrumentation.rb +14 -6
  17. data/lib/tcell_agent/logger.rb +2 -2
  18. data/lib/tcell_agent/policies/dataloss_policy.rb +15 -8
  19. data/lib/tcell_agent/policies/headers_policy.rb +2 -2
  20. data/lib/tcell_agent/policies/patches_policy.rb +8 -4
  21. data/lib/tcell_agent/policies/policies_manager.rb +1 -0
  22. data/lib/tcell_agent/policies/policy_polling.rb +4 -3
  23. data/lib/tcell_agent/rails/auth/doorkeeper.rb +1 -0
  24. data/lib/tcell_agent/rails/better_ip.rb +7 -19
  25. data/lib/tcell_agent/rails/dlp/process_request.rb +5 -0
  26. data/lib/tcell_agent/rails/dlp.rb +48 -48
  27. data/lib/tcell_agent/rails/dlp_handler.rb +9 -10
  28. data/lib/tcell_agent/rails/js_agent_insert.rb +2 -3
  29. data/lib/tcell_agent/rails/middleware/context_middleware.rb +2 -1
  30. data/lib/tcell_agent/rails/middleware/global_middleware.rb +1 -5
  31. data/lib/tcell_agent/rails/middleware/headers_middleware.rb +1 -0
  32. data/lib/tcell_agent/rails/routes/grape.rb +2 -1
  33. data/lib/tcell_agent/rails/settings_reporter.rb +3 -6
  34. data/lib/tcell_agent/rails/tcell_body_proxy.rb +4 -6
  35. data/lib/tcell_agent/routes/table.rb +3 -0
  36. data/lib/tcell_agent/rust/agent_config.rb +20 -2
  37. data/lib/tcell_agent/rust/{libtcellagent-5.0.2.so → libtcellagent-alpine.so} +0 -0
  38. data/lib/tcell_agent/rust/{tcellagent-5.0.2.dll → libtcellagent-x64.dll} +0 -0
  39. data/lib/tcell_agent/rust/{libtcellagent-5.0.2.dylib → libtcellagent.dylib} +0 -0
  40. data/lib/tcell_agent/rust/{libtcellagent-alpine-5.0.2.so → libtcellagent.so} +0 -0
  41. data/lib/tcell_agent/rust/native_agent.rb +51 -59
  42. data/lib/tcell_agent/rust/native_library.rb +7 -10
  43. data/lib/tcell_agent/sensor_events/server_agent.rb +3 -100
  44. data/lib/tcell_agent/sensor_events/util/sanitizer_utilities.rb +1 -0
  45. data/lib/tcell_agent/servers/puma.rb +25 -8
  46. data/lib/tcell_agent/servers/rack_puma_handler.rb +13 -3
  47. data/lib/tcell_agent/servers/webrick.rb +13 -3
  48. data/lib/tcell_agent/settings_reporter.rb +0 -14
  49. data/lib/tcell_agent/sinatra.rb +1 -0
  50. data/lib/tcell_agent/tcell_context.rb +15 -6
  51. data/lib/tcell_agent/utils/headers.rb +0 -1
  52. data/lib/tcell_agent/utils/strings.rb +2 -2
  53. data/lib/tcell_agent/version.rb +1 -1
  54. data/spec/cruby_spec_helper.rb +26 -0
  55. data/spec/lib/tcell_agent/instrument_servers_spec.rb +1 -1
  56. data/spec/lib/tcell_agent/instrumentation/cmdi/io_cmdi_spec.rb +2 -2
  57. data/spec/lib/tcell_agent/instrumentation/lfi/file_lfi_spec.rb +211 -272
  58. data/spec/lib/tcell_agent/instrumentation/lfi/io_lfi_spec.rb +207 -223
  59. data/spec/lib/tcell_agent/instrumentation/lfi/kernel_lfi_spec.rb +89 -70
  60. data/spec/lib/tcell_agent/instrumentation/lfi_spec.rb +73 -0
  61. data/spec/lib/tcell_agent/patches_spec.rb +2 -1
  62. data/spec/lib/tcell_agent/policies/clickjacking_policy_spec.rb +1 -2
  63. data/spec/lib/tcell_agent/policies/content_security_policy_spec.rb +5 -6
  64. data/spec/lib/tcell_agent/policies/patches_policy_spec.rb +21 -2
  65. data/spec/lib/tcell_agent/policies/policies_manager_spec.rb +1 -1
  66. data/spec/lib/tcell_agent/policies/secure_headers_policy_spec.rb +13 -8
  67. data/spec/lib/tcell_agent/rails/better_ip_spec.rb +9 -11
  68. data/spec/lib/tcell_agent/rails/csrf_exception_spec.rb +6 -6
  69. data/spec/lib/tcell_agent/rails/dlp_spec.rb +1 -0
  70. data/spec/lib/tcell_agent/rails/js_agent_insert_spec.rb +10 -2
  71. data/spec/lib/tcell_agent/rails/middleware/tcell_body_proxy_spec.rb +2 -1
  72. data/spec/lib/tcell_agent/rails/routes/route_id_spec.rb +4 -4
  73. data/spec/lib/tcell_agent/settings_reporter_spec.rb +2 -16
  74. data/spec/lib/tcell_agent/tcell_context_spec.rb +6 -5
  75. data/spec/spec_helper.rb +3 -1
  76. data/spec/support/builders.rb +2 -1
  77. data/spec/support/server_mocks/puma_mock.rb +4 -0
  78. data/spec/support/shared_spec.rb +29 -0
  79. data/tcell_agent.gemspec +14 -14
  80. metadata +23 -19
  81. data/Rakefile +0 -18
  82. data/lib/tcell_agent/instrumentation/monkey_patches/file.rb +0 -25
  83. data/lib/tcell_agent/instrumentation/monkey_patches/io.rb +0 -131
  84. data/lib/tcell_agent/instrumentation/monkey_patches/kernel.rb +0 -102
@@ -1,4 +1,3 @@
1
-
2
1
  require 'spec_helper'
3
2
 
4
3
  module TCellAgent
@@ -16,13 +15,7 @@ module TCellAgent
16
15
  ).update_attribute(
17
16
  'route_id', 'route-id'
18
17
  ).build
19
- end
20
-
21
- after(:each) do
22
- TCellAgent::Rust::NativeAgent.free_agent(@native_agent.agent_ptr)
23
- end
24
18
 
25
- it 'should return csp header' do
26
19
  enablements = @native_agent.update_policies(
27
20
  {
28
21
  'secure-headers' => {
@@ -41,14 +34,26 @@ module TCellAgent
41
34
 
42
35
  @policy = HeadersPolicy.new(@native_agent, enablements)
43
36
  expect(@policy.enabled).to eq(true)
37
+ end
44
38
 
39
+ after(:each) do
40
+ TCellAgent::Rust::NativeAgent.free_agent(@native_agent.agent_ptr)
41
+ end
42
+
43
+ it 'should return csp header' do
45
44
  expect(
46
- @policy.get_headers(@tcell_context)
45
+ @policy.get_headers('text/html', @tcell_context)
47
46
  ).to eq(
48
47
  [{ 'name' => 'X-Content-Type-Options',
49
48
  'value' => 'nosniff' }]
50
49
  )
51
50
  end
51
+
52
+ it 'should not return csp header on json' do
53
+ expect(
54
+ @policy.get_headers('application/json', @tcell_context)
55
+ ).to eq([])
56
+ end
52
57
  end
53
58
  end
54
59
  end
@@ -4,37 +4,34 @@ module TCellAgent
4
4
  module Utils
5
5
  describe '.better_ip' do
6
6
  context 'with reverse_proxy off' do
7
- it 'should return the normal ip' do
7
+ it 'returns null' do
8
8
  configuration = double('configuration')
9
9
  request = double('request', :ip => '127.0.0.0')
10
10
 
11
11
  expect(TCellAgent).to receive(:configuration).and_return(configuration)
12
12
  expect(configuration).to receive(:reverse_proxy).and_return(false)
13
- expect(Rails.better_ip(request)).to eq('127.0.0.0')
13
+ expect(Rails.reverse_proxy_header(request)).to eq(nil)
14
14
  end
15
15
  end
16
16
 
17
17
  context 'with reverse_proxy on' do
18
18
  context 'with empty reverse_proxy_ip_address_header' do
19
- it 'should return normal ip' do
19
+ it 'returns null' do
20
20
  configuration = double('configuration')
21
21
  request = double('request', :ip => '127.0.0.0')
22
- env = double('env')
23
22
 
24
23
  expect(TCellAgent).to receive(:configuration).and_return(configuration)
25
24
  expect(configuration).to receive(:reverse_proxy).and_return(true)
26
25
  expect(TCellAgent).to receive(:configuration).and_return(configuration)
27
26
  expect(configuration).to receive(:reverse_proxy_ip_address_header).and_return('')
28
- expect(request).to receive(:env).and_return(env)
29
- expect(env).to receive(:[]).with('HTTP_X_FORWARDED_FOR').and_return('')
30
- expect(Rails.better_ip(request)).to eq('127.0.0.0')
27
+ expect(Rails.reverse_proxy_header(request)).to eq(nil)
31
28
  end
32
29
  end
33
30
 
34
31
  context "with reverse_proxy_ip_address_header that doesn't exist" do
35
- it 'should return normal ip' do
32
+ it 'returns null' do
36
33
  configuration = double('configuration')
37
- request = double('request', :ip => '127.0.0.0')
34
+ request = double('request', :ip => '127.0.0.0', :env => {})
38
35
  env = double('env')
39
36
 
40
37
  expect(TCellAgent).to receive(:configuration).and_return(configuration)
@@ -45,7 +42,7 @@ module TCellAgent
45
42
  )
46
43
  expect(request).to receive(:env).and_return(env)
47
44
  expect(env).to receive(:[]).with('HTTP_WEIRD_HTTP_PROXY_HEADER').and_return(nil)
48
- expect(Rails.better_ip(request)).to eq('127.0.0.0')
45
+ expect(Rails.reverse_proxy_header(request)).to eq(nil)
49
46
  end
50
47
  end
51
48
 
@@ -57,13 +54,14 @@ module TCellAgent
57
54
 
58
55
  expect(TCellAgent).to receive(:configuration).and_return(configuration)
59
56
  expect(configuration).to receive(:reverse_proxy).and_return(true)
57
+
60
58
  expect(TCellAgent).to receive(:configuration).and_return(configuration)
61
59
  expect(configuration).to receive(:reverse_proxy_ip_address_header).and_return(
62
60
  'X-Real-IP'
63
61
  )
64
62
  expect(request).to receive(:env).and_return(env)
65
63
  expect(env).to receive(:[]).with('HTTP_X_REAL_IP').and_return('192.168.99.100')
66
- expect(Rails.better_ip(request)).to eq('192.168.99.100')
64
+ expect(Rails.reverse_proxy_header(request)).to eq('192.168.99.100')
67
65
  end
68
66
  end
69
67
  end
@@ -1,13 +1,13 @@
1
1
  require 'spec_helper'
2
2
 
3
- module TCellAgent
4
- describe 'CsrfExceptionReporter' do
5
- class WrapperClass
6
- include TCellAgent::CsrfExceptionReporter
3
+ class WrapperClass
4
+ include TCellAgent::CsrfExceptionReporter
7
5
 
8
- def request; end
9
- end
6
+ def request; end
7
+ end
10
8
 
9
+ module TCellAgent
10
+ describe 'CsrfExceptionReporter' do
11
11
  before(:all) do
12
12
  @csrf_class = WrapperClass.new
13
13
  end
@@ -4,6 +4,7 @@ module TCellAgent
4
4
  module DLP
5
5
  class SomeColumn
6
6
  attr_accessor :name
7
+
7
8
  def initialize(name = nil)
8
9
  @name = name
9
10
  end
@@ -127,10 +127,10 @@ module TCellAgent
127
127
  end
128
128
 
129
129
  context 'with a <HEAD> tag' do
130
- it 'should not append script after <HEAD> tag' do
130
+ it 'should append script after <HEAD> tag' do
131
131
  response = JSAgent.handle_js_agent_insert('SCRIPT', 'i am the <HEAD> response')
132
132
 
133
- expect(response).to eq('i am the <HEAD> response')
133
+ expect(response).to eq('i am the <HEAD>SCRIPT response')
134
134
  end
135
135
  end
136
136
 
@@ -142,6 +142,14 @@ module TCellAgent
142
142
  end
143
143
  end
144
144
 
145
+ context 'with a <HEAD\n> tag' do
146
+ it 'should append script after <HEAD\n> tag' do
147
+ response = JSAgent.handle_js_agent_insert('SCRIPT', "i am the <HEAD\n> response")
148
+
149
+ expect(response).to eq("i am the <HEAD\n>SCRIPT response")
150
+ end
151
+ end
152
+
145
153
  context 'with invalid parameters' do
146
154
  context 'with nil response' do
147
155
  it 'should return the unmodified response' do
@@ -13,7 +13,8 @@ module TCellAgent
13
13
  'session_id',
14
14
  'user_id',
15
15
  'transaction_id',
16
- 'http://test.com/'
16
+ 'http://test.com/',
17
+ '0.0.0.0'
17
18
  )
18
19
  end
19
20
 
@@ -3,7 +3,7 @@ require 'spec_helper'
3
3
  module TCellAgent
4
4
  module Instrumentation
5
5
  describe RouteId do
6
- TCELL_CONTEXT_KEY = TCellAgent::Instrumentation::TCELL_ID
6
+ tcell_context_key = TCellAgent::Instrumentation::TCELL_ID
7
7
 
8
8
  describe '.update_context' do
9
9
  context 'with nil route' do
@@ -11,7 +11,7 @@ module TCellAgent
11
11
  tcell_context = TCellData.new
12
12
  tcell_context.route_id = nil
13
13
 
14
- RouteId.update_context({ TCELL_CONTEXT_KEY => tcell_context }, {}, nil)
14
+ RouteId.update_context({ tcell_context_key => tcell_context }, {}, nil)
15
15
 
16
16
  expect(tcell_context.route_id).to eq(nil)
17
17
  expect(tcell_context.grape_mount_endpoint).to eq(nil)
@@ -41,7 +41,7 @@ module TCellAgent
41
41
 
42
42
  expect(TCellAgent::Instrumentation).to receive(:grape_route?).with(route).and_return(false)
43
43
 
44
- RouteId.update_context({ TCELL_CONTEXT_KEY => tcell_context }, { :id => 1 }, route)
44
+ RouteId.update_context({ tcell_context_key => tcell_context }, { :id => 1 }, route)
45
45
 
46
46
  expect(tcell_context.route_id).to eq(
47
47
  TCellAgent::SensorEvents::Util.calculate_route_id('GET', '/some/regular/path')
@@ -64,7 +64,7 @@ module TCellAgent
64
64
 
65
65
  expect(TCellAgent::Instrumentation).to receive(:grape_route?).with(route).and_return(true)
66
66
 
67
- RouteId.update_context({ TCELL_CONTEXT_KEY => tcell_context }, { :id => 1 }, route)
67
+ RouteId.update_context({ tcell_context_key => tcell_context }, { :id => 1 }, route)
68
68
 
69
69
  expect(tcell_context.route_id).to eq(nil)
70
70
  expect(tcell_context.grape_mount_endpoint).to eq('/grape_api')
@@ -27,26 +27,12 @@ module TCellAgent
27
27
  ).at_least(:once)
28
28
  expect(TCellAgent).to receive(:logger).and_return(logger).at_least(:once)
29
29
  expect(Thread).to receive(:new).and_yield
30
- expect(logger).to receive(:debug).with('TCellAgent::SensorEvents::ServerAgentDetailsSensorEvent', 'User unknown')
31
- expect(logger).to receive(:debug).with('TCellAgent::SensorEvents::ServerAgentDetailsSensorEvent', 'Group unknown')
32
- expect(TCellAgent).to receive(:send_event).with(
33
- {
34
- 'event_type' => 'server_agent_details',
35
- 'user' => 'unknown',
36
- 'group' => 'unknown'
37
- }
38
- )
30
+
39
31
  expect(logger).to receive(:debug).with(anything, anything).at_least(:once)
40
32
  expect(TCellAgent).to receive(:send_event).with(
41
33
  hash_including('event_type' => 'server_agent_packages')
42
- ) # packages event
43
- expect(TCellAgent).to receive(:send_event).with(
44
- {
45
- 'event_type' => 'server_agent_details',
46
- 'language' => 'Ruby',
47
- 'language_version' => RUBY_VERSION
48
- }
49
34
  )
35
+
50
36
  expect(TCellAgent).to receive(:send_event).with(
51
37
  {
52
38
  'event_type' => 'app_config_setting',
@@ -4,9 +4,9 @@ module TCellAgent
4
4
  describe MetaData do
5
5
  describe '#set_headers_dict' do
6
6
  it 'should set all headers that start with http and skip cookies' do
7
- method = remote_address = route_id = session_id = user_id = transaction_id = location = nil
7
+ method = remote_address = route_id = session_id = user_id = transaction_id = location = reverse_proxy_header_value = nil
8
8
 
9
- meta = MetaData.new(method, remote_address, route_id, session_id, user_id, transaction_id, location)
9
+ meta = MetaData.new(method, remote_address, route_id, session_id, user_id, transaction_id, location, reverse_proxy_header_value)
10
10
  meta.headers_dict = {
11
11
  'rack.version' => [1, 2],
12
12
  'REQUEST_METHOD' => 'POST',
@@ -24,9 +24,9 @@ module TCellAgent
24
24
  end
25
25
 
26
26
  it 'should set all headers that start with http and include content_length and content_type' do
27
- method = remote_address = route_id = session_id = user_id = transaction_id = location = nil
27
+ method = remote_address = route_id = session_id = user_id = transaction_id = location = reverse_proxy_header_value = nil
28
28
 
29
- meta = MetaData.new(method, remote_address, route_id, session_id, user_id, transaction_id, location)
29
+ meta = MetaData.new(method, remote_address, route_id, session_id, user_id, transaction_id, location, reverse_proxy_header_value)
30
30
  meta.headers_dict = {
31
31
  'REQUEST_METHOD' => 'POST',
32
32
  'HTTP_VERSION' => 'HTTP/1.1',
@@ -71,7 +71,8 @@ module TCellAgent
71
71
  'session_id',
72
72
  'user_id',
73
73
  'transaction_id',
74
- 'http://test.com'
74
+ 'http://test.com',
75
+ '0.0.0.0'
75
76
  )
76
77
  end
77
78
 
data/spec/spec_helper.rb CHANGED
@@ -12,12 +12,14 @@ end
12
12
  ENV['TCELL_AGENT_SERVER'] = 'mock'
13
13
  require File.join(File.dirname(__FILE__), '..', 'lib', 'tcell_agent')
14
14
 
15
- Dir[File.join(File.dirname(__FILE__), 'support', '**', '*.rb')].each { |f| require f }
15
+ Dir[File.join(File.dirname(__FILE__), 'support', '**', '*.rb')].sort.each { |f| require f }
16
16
 
17
17
  def get_test_resource_path(name)
18
18
  File.join(File.dirname(__FILE__), 'support', 'resources', name)
19
19
  end
20
20
 
21
+ NEW_FILE_NAME ||= "/tmp/#{SecureRandom.uuid}".freeze
22
+
21
23
  require 'tcell_agent/agent'
22
24
  require 'tcell_agent/rails/routes'
23
25
 
@@ -73,7 +73,8 @@ module TCellAgent
73
73
  'session-id',
74
74
  'user-id',
75
75
  SecureRandom.uuid,
76
- 'http://domain.com/some/path?hide-my-value=sensitive'
76
+ 'http://domain.com/some/path?hide-my-value=sensitive',
77
+ '0.0.0.0'
77
78
  )
78
79
 
79
80
  @meta_data.path = '/some/path'
@@ -14,4 +14,8 @@ module Puma
14
14
  def self.cli_config
15
15
  Config
16
16
  end
17
+
18
+ module Const
19
+ PUMA_VERSION = '5.1.0'
20
+ end
17
21
  end
@@ -0,0 +1,29 @@
1
+ def test_ruby2_ruby3_keywords(cls, func, args, options, res, min_ruby = '2.0.0')
2
+ ruby_version = Gem::Version.new(RUBY_VERSION)
3
+
4
+ context 'using ruby2_3 helper function' do
5
+ after(:each) do
6
+ expect(@result).to eq res unless res.nil?
7
+ end
8
+
9
+ if ruby_version >= Gem::Version.new(min_ruby) && \
10
+ ruby_version < Gem::Version.new('3.0.0')
11
+ # This spec tests the following format:
12
+ # File.new('/dev/null', 'w', 0o644, { :binmode => true })
13
+ it 'behaves correctly in ruby < 2.7' do
14
+ args_cp = Array.new(args)
15
+ args_cp << options
16
+
17
+ @result = cls.send(func, *args_cp)
18
+ end
19
+ end
20
+
21
+ if ruby_version >= Gem::Version.new(min_ruby)
22
+ # This spec tests the following format:
23
+ # File.new('/dev/null', 'w', 0o644, :binmode => true )
24
+ it 'behaves correctly in ruby >= 3.0' do
25
+ @result = cls.send(func, *args, **options)
26
+ end
27
+ end
28
+ end
29
+ end
data/tcell_agent.gemspec CHANGED
@@ -6,23 +6,23 @@ require 'tcell_agent/version'
6
6
  Gem::Specification.new do |spec|
7
7
  spec.name = 'tcell_agent'
8
8
  spec.version = TCellAgent::VERSION
9
- spec.authors = %w[Rafael]
10
- spec.email = ['rafael@tcell.io']
11
- spec.summary = 'tCell.io Agent for Rails'
12
- spec.description = 'This agent allows users to use the tCell.io service with their Rails app.'
13
- spec.homepage = 'https://www.tcell.io'
14
- spec.license = 'Copyright (c) 2017 tCell.io (see LICENSE file)'
9
+ spec.authors = 'Rapid7, Inc.'
10
+ spec.summary = 'tCell Agent for Rails'
11
+ spec.description = 'This agent allows users to use the tCell service with their Rails app.'
12
+ spec.homepage = 'https://www.rapid7.com/tcell'
13
+ spec.license = 'Copyright (c) 2020 Rapid7, Inc. (see LICENSE file)'
15
14
 
16
15
  spec.files = Dir[
17
- 'Rakefile',
16
+ 'README.md',
17
+ 'LICENSE',
18
+ 'tcell_agent.gemspec',
19
+ 'spec/**/*',
18
20
  'lib/tcell_agent.rb',
19
- '{lib/tcell_agent,spec}/**/*',
20
- 'lib/tcell_agent/rust/libtcellagent-*.so',
21
- 'lib/tcell_agent/rust/libtcellagent-*.dylib',
22
- 'lib/tcell_agent/rust/tcellagent-*.dll',
23
- 'README*',
24
- 'LICENSE*',
25
- 'tcell_agent.gemspec'
21
+ 'lib/tcell_agent/**/*rb',
22
+ 'lib/tcell_agent/rust/libtcellagent.dylib',
23
+ 'lib/tcell_agent/rust/libtcellagent.so',
24
+ 'lib/tcell_agent/rust/libtcellagent-alpine.so',
25
+ 'lib/tcell_agent/rust/libtcellagent-x64.dll',
26
26
  ]
27
27
  spec.executables = `git ls-files -- bin/*`.split("\n").map { |f| File.basename(f) }
28
28
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tcell_agent
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.2.1
4
+ version: 2.5.0
5
5
  platform: ruby
6
6
  authors:
7
- - Rafael
7
+ - Rapid7, Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-08-04 00:00:00.000000000 Z
11
+ date: 2021-09-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ffi
@@ -94,10 +94,8 @@ dependencies:
94
94
  - - ">="
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0'
97
- description: This agent allows users to use the tCell.io service with their Rails
98
- app.
99
- email:
100
- - rafael@tcell.io
97
+ description: This agent allows users to use the tCell service with their Rails app.
98
+ email:
101
99
  executables:
102
100
  - tcell_agent
103
101
  extensions: []
@@ -105,7 +103,6 @@ extra_rdoc_files: []
105
103
  files:
106
104
  - LICENSE
107
105
  - README.md
108
- - Rakefile
109
106
  - bin/tcell_agent
110
107
  - lib/tcell_agent.rb
111
108
  - lib/tcell_agent/agent.rb
@@ -118,9 +115,12 @@ files:
118
115
  - lib/tcell_agent/instrumentation.rb
119
116
  - lib/tcell_agent/instrumentation/cmdi.rb
120
117
  - lib/tcell_agent/instrumentation/lfi.rb
121
- - lib/tcell_agent/instrumentation/monkey_patches/file.rb
122
- - lib/tcell_agent/instrumentation/monkey_patches/io.rb
123
- - lib/tcell_agent/instrumentation/monkey_patches/kernel.rb
118
+ - lib/tcell_agent/instrumentation/monkey_patches/ruby_2/file.rb
119
+ - lib/tcell_agent/instrumentation/monkey_patches/ruby_2/io.rb
120
+ - lib/tcell_agent/instrumentation/monkey_patches/ruby_2/kernel.rb
121
+ - lib/tcell_agent/instrumentation/monkey_patches/ruby_3/file.rb
122
+ - lib/tcell_agent/instrumentation/monkey_patches/ruby_3/io.rb
123
+ - lib/tcell_agent/instrumentation/monkey_patches/ruby_3/kernel.rb
124
124
  - lib/tcell_agent/logger.rb
125
125
  - lib/tcell_agent/patches.rb
126
126
  - lib/tcell_agent/policies/appfirewall_policy.rb
@@ -163,14 +163,14 @@ files:
163
163
  - lib/tcell_agent/rails/tcell_body_proxy.rb
164
164
  - lib/tcell_agent/routes/table.rb
165
165
  - lib/tcell_agent/rust/agent_config.rb
166
- - lib/tcell_agent/rust/libtcellagent-5.0.2.dylib
167
- - lib/tcell_agent/rust/libtcellagent-5.0.2.so
168
- - lib/tcell_agent/rust/libtcellagent-alpine-5.0.2.so
166
+ - lib/tcell_agent/rust/libtcellagent-alpine.so
167
+ - lib/tcell_agent/rust/libtcellagent-x64.dll
168
+ - lib/tcell_agent/rust/libtcellagent.dylib
169
+ - lib/tcell_agent/rust/libtcellagent.so
169
170
  - lib/tcell_agent/rust/models.rb
170
171
  - lib/tcell_agent/rust/native_agent.rb
171
172
  - lib/tcell_agent/rust/native_agent_response.rb
172
173
  - lib/tcell_agent/rust/native_library.rb
173
- - lib/tcell_agent/rust/tcellagent-5.0.2.dll
174
174
  - lib/tcell_agent/sensor_events/agent_setting_event.rb
175
175
  - lib/tcell_agent/sensor_events/app_config_setting_event.rb
176
176
  - lib/tcell_agent/sensor_events/discovery.rb
@@ -193,6 +193,7 @@ files:
193
193
  - lib/tcell_agent/utils/params.rb
194
194
  - lib/tcell_agent/utils/strings.rb
195
195
  - lib/tcell_agent/version.rb
196
+ - spec/cruby_spec_helper.rb
196
197
  - spec/lib/tcell_agent/configuration_spec.rb
197
198
  - spec/lib/tcell_agent/hooks/login_fraud_spec.rb
198
199
  - spec/lib/tcell_agent/instrument_servers_spec.rb
@@ -245,11 +246,12 @@ files:
245
246
  - spec/support/server_mocks/rails_mock.rb
246
247
  - spec/support/server_mocks/thin_mock.rb
247
248
  - spec/support/server_mocks/unicorn_mock.rb
249
+ - spec/support/shared_spec.rb
248
250
  - spec/support/static_agent_overrides.rb
249
251
  - tcell_agent.gemspec
250
- homepage: https://www.tcell.io
252
+ homepage: https://www.rapid7.com/tcell
251
253
  licenses:
252
- - Copyright (c) 2017 tCell.io (see LICENSE file)
254
+ - Copyright (c) 2020 Rapid7, Inc. (see LICENSE file)
253
255
  metadata: {}
254
256
  post_install_message:
255
257
  rdoc_options: []
@@ -268,11 +270,12 @@ required_rubygems_version: !ruby/object:Gem::Requirement
268
270
  - !ruby/object:Gem::Version
269
271
  version: '0'
270
272
  requirements: []
271
- rubygems_version: 3.0.3
273
+ rubygems_version: 3.2.22
272
274
  signing_key:
273
275
  specification_version: 4
274
- summary: tCell.io Agent for Rails
276
+ summary: tCell Agent for Rails
275
277
  test_files:
278
+ - spec/cruby_spec_helper.rb
276
279
  - spec/lib/tcell_agent/configuration_spec.rb
277
280
  - spec/lib/tcell_agent/hooks/login_fraud_spec.rb
278
281
  - spec/lib/tcell_agent/instrument_servers_spec.rb
@@ -325,4 +328,5 @@ test_files:
325
328
  - spec/support/server_mocks/rails_mock.rb
326
329
  - spec/support/server_mocks/thin_mock.rb
327
330
  - spec/support/server_mocks/unicorn_mock.rb
331
+ - spec/support/shared_spec.rb
328
332
  - spec/support/static_agent_overrides.rb