newrelic_rpm 9.12.0 → 9.17.0

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.
Files changed (114) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +217 -1
  3. data/CONTRIBUTING.md +2 -2
  4. data/README.md +16 -20
  5. data/lib/boot/strap.rb +4 -3
  6. data/lib/new_relic/agent/agent.rb +4 -0
  7. data/lib/new_relic/agent/agent_helpers/connect.rb +3 -0
  8. data/lib/new_relic/agent/agent_helpers/harvest.rb +3 -0
  9. data/lib/new_relic/agent/agent_helpers/shutdown.rb +3 -0
  10. data/lib/new_relic/agent/agent_helpers/start_worker_thread.rb +1 -0
  11. data/lib/new_relic/agent/agent_helpers/startup.rb +7 -0
  12. data/lib/new_relic/agent/aws.rb +6 -0
  13. data/lib/new_relic/agent/configuration/default_source.rb +363 -31
  14. data/lib/new_relic/agent/configuration/environment_source.rb +5 -1
  15. data/lib/new_relic/agent/configuration/manager.rb +23 -0
  16. data/lib/new_relic/agent/configuration/yaml_source.rb +6 -1
  17. data/lib/new_relic/agent/database/obfuscation_helpers.rb +11 -11
  18. data/lib/new_relic/agent/database.rb +41 -1
  19. data/lib/new_relic/agent/distributed_tracing.rb +2 -2
  20. data/lib/new_relic/agent/health_check.rb +136 -0
  21. data/lib/new_relic/agent/instrumentation/active_merchant.rb +0 -13
  22. data/lib/new_relic/agent/instrumentation/active_record.rb +1 -8
  23. data/lib/new_relic/agent/instrumentation/active_record_helper.rb +5 -1
  24. data/lib/new_relic/agent/instrumentation/active_record_subscriber.rb +9 -16
  25. data/lib/new_relic/agent/instrumentation/active_support_broadcast_logger.rb +0 -2
  26. data/lib/new_relic/agent/instrumentation/active_support_logger.rb +0 -2
  27. data/lib/new_relic/agent/instrumentation/async_http.rb +1 -2
  28. data/lib/new_relic/agent/instrumentation/aws_sdk_firehose/chain.rb +21 -0
  29. data/lib/new_relic/agent/instrumentation/aws_sdk_firehose/instrumentation.rb +66 -0
  30. data/lib/new_relic/agent/instrumentation/aws_sdk_firehose/prepend.rb +15 -0
  31. data/lib/new_relic/agent/instrumentation/aws_sdk_firehose.rb +22 -0
  32. data/lib/new_relic/agent/instrumentation/aws_sdk_kinesis/chain.rb +21 -0
  33. data/lib/new_relic/agent/instrumentation/aws_sdk_kinesis/instrumentation.rb +91 -0
  34. data/lib/new_relic/agent/instrumentation/aws_sdk_kinesis/prepend.rb +15 -0
  35. data/lib/new_relic/agent/instrumentation/aws_sdk_kinesis.rb +22 -0
  36. data/lib/new_relic/agent/instrumentation/aws_sdk_lambda/chain.rb +33 -0
  37. data/lib/new_relic/agent/instrumentation/aws_sdk_lambda/instrumentation.rb +93 -0
  38. data/lib/new_relic/agent/instrumentation/aws_sdk_lambda/prepend.rb +23 -0
  39. data/lib/new_relic/agent/instrumentation/aws_sdk_lambda.rb +23 -0
  40. data/lib/new_relic/agent/instrumentation/aws_sqs.rb +0 -2
  41. data/lib/new_relic/agent/instrumentation/bunny.rb +3 -4
  42. data/lib/new_relic/agent/instrumentation/concurrent_ruby.rb +0 -2
  43. data/lib/new_relic/agent/instrumentation/curb.rb +3 -4
  44. data/lib/new_relic/agent/instrumentation/delayed_job_instrumentation.rb +0 -23
  45. data/lib/new_relic/agent/instrumentation/dynamodb/instrumentation.rb +1 -1
  46. data/lib/new_relic/agent/instrumentation/dynamodb.rb +0 -2
  47. data/lib/new_relic/agent/instrumentation/elasticsearch.rb +0 -2
  48. data/lib/new_relic/agent/instrumentation/ethon.rb +0 -4
  49. data/lib/new_relic/agent/instrumentation/excon.rb +0 -16
  50. data/lib/new_relic/agent/instrumentation/fiber.rb +0 -2
  51. data/lib/new_relic/agent/instrumentation/grape/instrumentation.rb +0 -3
  52. data/lib/new_relic/agent/instrumentation/grape.rb +1 -1
  53. data/lib/new_relic/agent/instrumentation/httpclient.rb +0 -1
  54. data/lib/new_relic/agent/instrumentation/httprb.rb +0 -1
  55. data/lib/new_relic/agent/instrumentation/httpx.rb +0 -4
  56. data/lib/new_relic/agent/instrumentation/logger.rb +1 -3
  57. data/lib/new_relic/agent/instrumentation/logstasher.rb +0 -2
  58. data/lib/new_relic/agent/instrumentation/memcache.rb +0 -1
  59. data/lib/new_relic/agent/instrumentation/opensearch/chain.rb +21 -0
  60. data/lib/new_relic/agent/instrumentation/opensearch/instrumentation.rb +66 -0
  61. data/lib/new_relic/agent/instrumentation/opensearch/prepend.rb +13 -0
  62. data/lib/new_relic/agent/instrumentation/opensearch.rb +23 -0
  63. data/lib/new_relic/agent/instrumentation/padrino.rb +3 -3
  64. data/lib/new_relic/agent/instrumentation/rake.rb +0 -1
  65. data/lib/new_relic/agent/instrumentation/rdkafka/chain.rb +72 -0
  66. data/lib/new_relic/agent/instrumentation/rdkafka/instrumentation.rb +70 -0
  67. data/lib/new_relic/agent/instrumentation/rdkafka/prepend.rb +67 -0
  68. data/lib/new_relic/agent/instrumentation/rdkafka.rb +25 -0
  69. data/lib/new_relic/agent/instrumentation/redis.rb +7 -6
  70. data/lib/new_relic/agent/instrumentation/resque.rb +7 -5
  71. data/lib/new_relic/agent/instrumentation/roda.rb +4 -4
  72. data/lib/new_relic/agent/instrumentation/ruby_kafka/chain.rb +55 -0
  73. data/lib/new_relic/agent/instrumentation/ruby_kafka/instrumentation.rb +67 -0
  74. data/lib/new_relic/agent/instrumentation/ruby_kafka/prepend.rb +60 -0
  75. data/lib/new_relic/agent/instrumentation/ruby_kafka.rb +25 -0
  76. data/lib/new_relic/agent/instrumentation/sidekiq/extensions/delayed_class.rb +1 -1
  77. data/lib/new_relic/agent/instrumentation/sidekiq.rb +0 -14
  78. data/lib/new_relic/agent/instrumentation/sinatra.rb +3 -19
  79. data/lib/new_relic/agent/instrumentation/thread.rb +0 -2
  80. data/lib/new_relic/agent/instrumentation/tilt.rb +0 -4
  81. data/lib/new_relic/agent/instrumentation/typhoeus.rb +0 -1
  82. data/lib/new_relic/agent/instrumentation/view_component/instrumentation.rb +11 -5
  83. data/lib/new_relic/agent/instrumentation/view_component.rb +0 -2
  84. data/lib/new_relic/agent/javascript_instrumentor.rb +2 -3
  85. data/lib/new_relic/agent/local_log_decorator.rb +12 -2
  86. data/lib/new_relic/agent/log_event_aggregator.rb +28 -2
  87. data/lib/new_relic/agent/messaging.rb +11 -5
  88. data/lib/new_relic/agent/new_relic_service.rb +8 -2
  89. data/lib/new_relic/agent/serverless_handler.rb +241 -12
  90. data/lib/new_relic/agent/serverless_handler_event_sources.json +155 -0
  91. data/lib/new_relic/agent/serverless_handler_event_sources.rb +49 -0
  92. data/lib/new_relic/agent/span_event_primitive.rb +4 -2
  93. data/lib/new_relic/agent/system_info.rb +14 -0
  94. data/lib/new_relic/agent/threading/backtrace_node.rb +10 -1
  95. data/lib/new_relic/agent/transaction/message_broker_segment.rb +3 -0
  96. data/lib/new_relic/agent/transaction/request_attributes.rb +13 -1
  97. data/lib/new_relic/agent/transaction/trace_context.rb +1 -1
  98. data/lib/new_relic/agent.rb +95 -2
  99. data/lib/new_relic/control/frameworks/grape.rb +14 -0
  100. data/lib/new_relic/control/frameworks/padrino.rb +14 -0
  101. data/lib/new_relic/control/frameworks/rails4.rb +1 -3
  102. data/lib/new_relic/dependency_detection.rb +11 -13
  103. data/lib/new_relic/environment_report.rb +2 -2
  104. data/lib/new_relic/helper.rb +15 -0
  105. data/lib/new_relic/language_support.rb +3 -1
  106. data/lib/new_relic/local_environment.rb +1 -4
  107. data/lib/new_relic/version.rb +1 -1
  108. data/lib/sequel/extensions/new_relic_instrumentation.rb +1 -1
  109. data/lib/tasks/helpers/newrelicyml.rb +73 -11
  110. data/lib/tasks/instrumentation_generator/instrumentation.thor +1 -1
  111. data/lib/tasks/instrumentation_generator/templates/dependency_detection.tt +11 -8
  112. data/newrelic.yml +224 -79
  113. data/test/agent_helper.rb +8 -1
  114. metadata +32 -6
data/newrelic.yml CHANGED
@@ -65,9 +65,16 @@ common: &default_settings
65
65
  # If true, the agent captures log records emitted by your application.
66
66
  # application_logging.forwarding.enabled: true
67
67
 
68
+ # If true, the agent attaches labels to log records.
69
+ # application_logging.forwarding.labels.enabled: false
70
+
71
+ # A case-insensitive array or comma-delimited string containing the labels to
72
+ # exclude from log records.
73
+ # application_logging.forwarding.labels.exclude: []
74
+
68
75
  # Sets the minimum level a log event must have to be forwarded to New Relic.
69
76
  # This is based on the integer values of Ruby's Logger::Severity constants:
70
- # https://github.com/ruby/ruby/blob/master/lib/logger/severity.rb
77
+ # https://github.com/ruby/logger/blob/113b82a06b3076b93a71cd467e1605b23afb3088/lib/logger/severity.rb
71
78
  # The intention is to forward logs with the level given to the configuration, as
72
79
  # well as any logs with a higher level of severity.
73
80
  # For example, setting this value to "debug" will forward all log events to New
@@ -113,6 +120,54 @@ common: &default_settings
113
120
  # Specifies a path to the audit log file (including the filename).
114
121
  # audit_log.path: log/newrelic_audit.log
115
122
 
123
+ # An array of CLASS#METHOD (for instance methods) and/or CLASS.METHOD (for class
124
+ # methods) strings representing Ruby methods that the agent can automatically
125
+ # add custom instrumentation to. This doesn't require any modifications of the
126
+ # source code that defines the methods.
127
+ # Use fully qualified class names (using the :: delimiter) that include any
128
+ # module or class namespacing.
129
+ # Here is some Ruby source code that defines a render_png instance method for an
130
+ # Image class and a notify class method for a User class, both within a
131
+ # MyCompany module namespace:
132
+ #
133
+ # module MyCompany
134
+ # class Image
135
+ # def render_png
136
+ # # code to render a PNG
137
+ # end
138
+ # end
139
+ #
140
+ # class User
141
+ # def self.notify
142
+ # # code to notify users
143
+ # end
144
+ # end
145
+ # end
146
+ #
147
+ # Given that source code, the newrelic.yml config file might request
148
+ # instrumentation for both of these methods like so:
149
+ #
150
+ # automatic_custom_instrumentation_method_list:
151
+ # - MyCompany::Image#render_png
152
+ # - MyCompany::User.notify
153
+ #
154
+ # That configuration example uses YAML array syntax to specify both methods.
155
+ # Alternatively, you can use a comma-delimited string:
156
+ #
157
+ # automatic_custom_instrumentation_method_list: 'MyCompany::Image#render_png,
158
+ # MyCompany::User.notify'
159
+ #
160
+ # Whitespace around the comma(s) in the list is optional. When configuring the
161
+ # agent with a list of methods via the
162
+ # NEW_RELIC_AUTOMATIC_CUSTOM_INSTRUMENTATION_METHOD_LIST environment variable,
163
+ # use this comma-delimited string format:
164
+ #
165
+ # export
166
+ # NEW_RELIC_AUTOMATIC_CUSTOM_INSTRUMENTATION_METHOD_LIST='MyCompany::Image#render_png,
167
+ # MyCompany::User.notify'
168
+ #
169
+ # automatic_custom_instrumentation_method_list: []
170
+
116
171
  # Specify a list of constants that should prevent the agent from starting
117
172
  # automatically. Separate individual constants with a comma ,. For example,
118
173
  # "Rails::Console,UninstrumentedBackgroundJob".
@@ -150,9 +205,8 @@ common: &default_settings
150
205
  # monitoring scripts. For now, auto-injection only works with Rails 5.2+.
151
206
  # browser_monitoring.content_security_policy_nonce: true
152
207
 
153
- # Manual override for the path to your local CA bundle. This CA bundle will be
154
- # used to validate the SSL certificate presented by New Relic's data collection
155
- # service.
208
+ # Manual override for the path to your local CA bundle. This CA bundle validates
209
+ # the SSL certificate presented by New Relic's data collection service.
156
210
  # ca_bundle_path: nil
157
211
 
158
212
  # Enable or disable the capture of memcache keys from transaction traces.
@@ -169,6 +223,9 @@ common: &default_settings
169
223
  # If true, the agent will clear Tracer::State in Agent.drop_buffered_data.
170
224
  # clear_transaction_state_after_fork: false
171
225
 
226
+ # The AWS account ID for the AWS account associated with this app
227
+ # cloud.aws.account_id: nil
228
+
172
229
  # If true, the agent will report source code level metrics for traced methods.
173
230
  # See:
174
231
  # https://docs.newrelic.com/docs/apm/agents/ruby-agent/features/ruby-codestream-integration/
@@ -265,18 +322,6 @@ common: &default_settings
265
322
  # If true, disables agent middleware for Sinatra. This middleware is responsible
266
323
  # for advanced feature support such as cross application tracing, page load
267
324
  # timing, and error collection.
268
- # Cross application tracing is deprecated in favor of distributed tracing.
269
- # Distributed tracing is on by default for Ruby agent versions 8.0.0 and above.
270
- # Middlewares are not required to support distributed tracing.
271
- # To continue using cross application tracing, update the following options in
272
- # your newrelic.yml configuration file:
273
- # ``yaml
274
- # # newrelic.yml
275
- # cross_application_tracer:
276
- # enabled: true
277
- # distributed_tracing:
278
- # enabled: false
279
- # ``
280
325
  # disable_sinatra_auto_middleware: false
281
326
 
282
327
  # If true, disables view instrumentation.
@@ -408,6 +453,18 @@ common: &default_settings
408
453
  # prepend, chain, disabled.
409
454
  # instrumentation.async_http: auto
410
455
 
456
+ # Controls auto-instrumentation of the aws-sdk-firehose library at start-up. May
457
+ # be one of auto, prepend, chain, disabled.
458
+ # instrumentation.aws_sdk_firehose: auto
459
+
460
+ # Controls auto-instrumentation of the aws-sdk-kinesis library at start-up. May
461
+ # be one of auto, prepend, chain, disabled.
462
+ # instrumentation.aws_sdk_kinesis: auto
463
+
464
+ # Controls auto-instrumentation of the aws_sdk_lambda library at start-up. May
465
+ # be one of auto, prepend, chain, disabled.
466
+ # instrumentation.aws_sdk_lambda: auto
467
+
411
468
  # Controls auto-instrumentation of the aws-sdk-sqs library at start-up. May be
412
469
  # one of: auto, prepend, chain, disabled.
413
470
  # instrumentation.aws_sqs: auto
@@ -509,6 +566,10 @@ common: &default_settings
509
566
  # prepend, chain, disabled.
510
567
  # instrumentation.net_http: auto
511
568
 
569
+ # Controls auto-instrumentation of the opensearch-ruby library at start-up. May
570
+ # be one of auto, prepend, chain, disabled.
571
+ # instrumentation.opensearch: auto
572
+
512
573
  # Controls auto-instrumentation of Puma::Rack. When enabled, the agent hooks
513
574
  # into the to_app method in Puma::Rack::Builder to find gems to instrument
514
575
  # during application startup. May be one of: auto, prepend, chain, disabled.
@@ -531,6 +592,10 @@ common: &default_settings
531
592
  # prepend, chain, disabled.
532
593
  # instrumentation.rake: auto
533
594
 
595
+ # Controls auto-instrumentation of the rdkafka library at start-up. May be one
596
+ # of auto, prepend, chain, disabled.
597
+ # instrumentation.rdkafka: auto
598
+
534
599
  # Controls auto-instrumentation of Redis at start-up. May be one of: auto,
535
600
  # prepend, chain, disabled.
536
601
  # instrumentation.redis: auto
@@ -543,6 +608,10 @@ common: &default_settings
543
608
  # prepend, chain, disabled.
544
609
  # instrumentation.roda: auto
545
610
 
611
+ # Controls auto-instrumentation of the ruby-kafka library at start-up. May be
612
+ # one of auto, prepend, chain, disabled.
613
+ # instrumentation.ruby_kafka: auto
614
+
546
615
  # Controls auto-instrumentation of the ruby-openai gem at start-up. May be one
547
616
  # of: auto, prepend, chain, disabled. Defaults to disabled in high security
548
617
  # mode.
@@ -607,6 +676,12 @@ common: &default_settings
607
676
  # When true, the agent transmits data about your app to the New Relic collector.
608
677
  # monitor_mode: true
609
678
 
679
+ # If true, the agent captures OpenSearch queries in transaction traces.
680
+ # opensearch.capture_queries: true
681
+
682
+ # If true, the agent obfuscates OpenSearch queries in transaction traces.
683
+ # opensearch.obfuscate_queries: true
684
+
610
685
  # If true, uses Module#prepend rather than alias_method for ActiveRecord
611
686
  # instrumentation.
612
687
  # prepend_active_record_instrumentation: false
@@ -645,60 +720,6 @@ common: &default_settings
645
720
  # ignoring specific transactions.
646
721
  # rules.ignore_url_regexes: []
647
722
 
648
- # BEGIN security agent
649
- #
650
- # NOTE: At this time, the security agent is intended for use only within
651
- # a dedicated security testing environment with data that can tolerate
652
- # modification or deletion. The security agent is available as a
653
- # separate Ruby gem, newrelic_security. It is recommended that this
654
- # separate gem only be introduced to a security testing environment
655
- # by leveraging Bundler grouping like so:
656
- #
657
- # # Gemfile
658
- # gem 'newrelic_rpm' # New Relic APM observability agent
659
- # gem 'newrelic-infinite_tracing' # New Relic Infinite Tracing
660
- #
661
- # group :security do
662
- # gem 'newrelic_security', require: false # New Relic security agent
663
- # end
664
- #
665
- # NOTE: All "security.*" configuration parameters are related only to the
666
- # security agent, and all other configuration parameters that may
667
- # have "security" in the name some where are related to the APM agent.
668
- #
669
-
670
- # If true, the security agent is loaded (a Ruby 'require' is performed)
671
- # security.agent.enabled: false
672
-
673
- # The port the application is listening on. This setting is mandatory for
674
- # Passenger servers. Other servers should be detected by default.
675
- # security.application_info.port: nil
676
-
677
- # If true, enables deserialization detection
678
- # security.detection.deserialization.enabled: true
679
-
680
- # If true, enables RCI (remote code injection) detection
681
- # security.detection.rci.enabled: true
682
-
683
- # If true, enables RXSS (reflected cross-site scripting) detection
684
- # security.detection.rxss.enabled: true
685
-
686
- # If true, the security agent is started (the agent runs in its event loop)
687
- # security.enabled: false
688
-
689
- # Defines the mode for the security agent to operate in. Currently only IAST is
690
- # supported
691
- # security.mode: IAST
692
-
693
- # Defines the request body limit to process in security events (in KB). The
694
- # default value is 300, for 300KB.
695
- # security.request.body_limit: 300
696
-
697
- # Defines the endpoint URL for posting security-related data
698
- # security.validator_service_url: wss://csec.nr-data.net
699
-
700
- # END security agent
701
-
702
723
  # Applies Language Agent Security Policy settings.
703
724
  # security_policies_token: ""
704
725
 
@@ -708,8 +729,8 @@ common: &default_settings
708
729
 
709
730
  # If true, the agent will operate in a streamlined mode suitable for use with
710
731
  # short-lived serverless functions. NOTE: Only AWS Lambda functions are
711
- # supported currently and this option is not intended for use without New
712
- # Relic's Ruby Lambda layer offering.
732
+ # supported currently and this option isn't intended for use without New Relic's
733
+ # Ruby Lambda layer offering.
713
734
  # serverless_mode.enabled: false
714
735
 
715
736
  # An array of strings that will collectively serve as a denylist for filtering
@@ -780,7 +801,7 @@ common: &default_settings
780
801
  # strip_exception_messages.allowed_classes: ""
781
802
 
782
803
  # If true, the agent strips messages from all exceptions except those in the
783
- # allowlist. Enabled automatically in high security mode.
804
+ # allowed classes list. Enabled automatically in high security mode.
784
805
  # strip_exception_messages.enabled: false
785
806
 
786
807
  # An array of strings to specify which keys and/or values inside a Stripe
@@ -788,17 +809,17 @@ common: &default_settings
788
809
  # not be reported to New Relic. Each string in this array will be turned into a
789
810
  # regular expression via
790
811
  # Regexp.new to permit advanced matching. For each hash pair, if either the key
791
- # or value is matched the
792
- # pair will not be reported. By default, no user_data is reported, so this
793
- # option should only be used if
794
- # the stripe.user_data.include option is being used.
812
+ # or value is matched the pair
813
+ # isn't reported. By default, no user_data is reported. Use this option only if
814
+ # the
815
+ # stripe.user_data.include option is also used.
795
816
  # stripe.user_data.exclude: []
796
817
 
797
818
  # An array of strings to specify which keys inside a Stripe event's user_data
798
819
  # hash should be reported
799
820
  # to New Relic. Each string in this array will be turned into a regular
800
821
  # expression via Regexp.new to
801
- # permit advanced matching. Setting the value to ["."] will report all
822
+ # enable advanced matching. Setting the value to ["."] will report all
802
823
  # user_data.
803
824
  # stripe.user_data.include: []
804
825
 
@@ -862,7 +883,7 @@ common: &default_settings
862
883
 
863
884
  # If true, enables the collection of explain plans in transaction traces. This
864
885
  # setting will also apply to explain plans in slow SQL traces if
865
- # slow_sql.explain_enabled is not set separately.
886
+ # slow_sql.explain_enabled isn't set separately.
866
887
  # transaction_tracer.explain_enabled: true
867
888
 
868
889
  # Threshold (in seconds) above which the agent will collect explain plans.
@@ -916,6 +937,130 @@ common: &default_settings
916
937
  # Foundry environment.
917
938
  # utilization.detect_pcf: true
918
939
 
940
+ # BEGIN security agent
941
+ #
942
+ # NOTE: At this time, the security agent is intended for use only within
943
+ # a dedicated security testing environment with data that can tolerate
944
+ # modification or deletion. The security agent is available as a
945
+ # separate Ruby gem, newrelic_security. It is recommended that this
946
+ # separate gem only be introduced to a security testing environment
947
+ # by leveraging Bundler grouping like so:
948
+ #
949
+ # # Gemfile
950
+ # gem 'newrelic_rpm' # New Relic APM observability agent
951
+ # gem 'newrelic-infinite_tracing' # New Relic Infinite Tracing
952
+ #
953
+ # group :security do
954
+ # gem 'newrelic_security', require: false # New Relic security agent
955
+ # end
956
+ #
957
+ # NOTE: All "security.*" configuration parameters are related only to the
958
+ # security agent, and all other configuration parameters that may
959
+ # have "security" in the name somewhere are related to the APM agent.
960
+
961
+ # If true, the security agent is loaded (a Ruby 'require' is performed)
962
+ # security.agent.enabled: false
963
+
964
+ # The port the application is listening on. This setting is mandatory for
965
+ # Passenger servers. The agent detects other servers by default.
966
+ # security.application_info.port: nil
967
+
968
+ # If true, the security agent is started (the agent runs in its event loop)
969
+ # security.enabled: false
970
+
971
+ # Defines API paths the security agent should ignore in IAST scans. Accepts an
972
+ # array of regex patterns matching the URI to ignore. The regex pattern should
973
+ # find a complete match for the URL without the endpoint. For example,
974
+ # [".*account.*"], [".*/\api\/v1\/.*?\/login"]
975
+ # security.exclude_from_iast_scan.api: []
976
+
977
+ # An array of HTTP request body keys the security agent should ignore in IAST
978
+ # scans.
979
+ # security.exclude_from_iast_scan.http_request_parameters.body: []
980
+
981
+ # An array of HTTP request headers the security agent should ignore in IAST
982
+ # scans. The array should specify a list of patterns matching the headers to
983
+ # ignore.
984
+ # security.exclude_from_iast_scan.http_request_parameters.header: []
985
+
986
+ # An array of HTTP request query parameters the security agent should ignore in
987
+ # IAST scans. The array should specify a list of patterns matching the HTTP
988
+ # request query parameters to ignore.
989
+ # security.exclude_from_iast_scan.http_request_parameters.query: []
990
+
991
+ # If true, disables system command injection detection in IAST scans.
992
+ # security.exclude_from_iast_scan.iast_detection_category.command_injection: false
993
+
994
+ # If true, disables the detection of low-severity insecure settings. For
995
+ # example, hash, crypto, cookie, random generators, trust boundary).
996
+ # security.exclude_from_iast_scan.iast_detection_category.insecure_settings: false
997
+
998
+ # If true, disables file operation-related IAST detections (File Access &
999
+ # Application integrity violation)
1000
+ # security.exclude_from_iast_scan.iast_detection_category.invalid_file_access: false
1001
+
1002
+ # If true, disables Javascript injection detection in IAST scans.
1003
+ # security.exclude_from_iast_scan.iast_detection_category.javascript_injection: false
1004
+
1005
+ # If true, disables LDAP injection detection in IAST scans.
1006
+ # security.exclude_from_iast_scan.iast_detection_category.ldap_injection: false
1007
+
1008
+ # If true, disables NOSQL injection detection in IAST scans.
1009
+ # security.exclude_from_iast_scan.iast_detection_category.nosql_injection: false
1010
+
1011
+ # If true, disables Reflected Cross-Site Scripting (RXSS) detection in IAST
1012
+ # scans.
1013
+ # security.exclude_from_iast_scan.iast_detection_category.rxss: false
1014
+
1015
+ # If true, disables SQL injection detection in IAST scans.
1016
+ # security.exclude_from_iast_scan.iast_detection_category.sql_injection: false
1017
+
1018
+ # If true, disables Sever-Side Request Forgery (SSRF) detection in IAST scans.
1019
+ # security.exclude_from_iast_scan.iast_detection_category.ssrf: false
1020
+
1021
+ # If true, disables XPATH injection detection in IAST scans.
1022
+ # security.exclude_from_iast_scan.iast_detection_category.xpath_injection: false
1023
+
1024
+ # A unique test identifier when runnning IAST in a CI/CD environment to
1025
+ # differentiate between different test runs. For example, a build number.
1026
+ # security.iast_test_identifier: nil
1027
+
1028
+ # Defines the mode for the security agent to operate in. Currently only IAST is
1029
+ # supported
1030
+ # security.mode: IAST
1031
+
1032
+ # Sets the maximum number of HTTP requests allowed for the IAST scan per minute.
1033
+ # Any Integer between 12 and 3600 is valid. The default value is 3600.
1034
+ # security.scan_controllers.iast_scan_request_rate_limit: 3600
1035
+
1036
+ # If true, enables the sending of HTTP responses bodies. Disabling this also
1037
+ # disables Reflected Cross-Site Scripting (RXSS) vulnerability detection.
1038
+ # security.scan_controllers.report_http_response_body: true
1039
+
1040
+ # The number of application instances for a specific entity to perform IAST
1041
+ # analysis on.
1042
+ # security.scan_controllers.scan_instance_count: 0
1043
+
1044
+ # If true, allows IAST to continuously gather trace data in the background. The
1045
+ # security agent uses collected data to perform an IAST scan at the scheduled
1046
+ # time.
1047
+ # security.scan_schedule.always_sample_traces: false
1048
+
1049
+ # Specifies the delay time (in minutes) before the IAST scan begins after the
1050
+ # application starts.
1051
+ # security.scan_schedule.delay: 0
1052
+
1053
+ # Indicates the duration (in minutes) for which the IAST scan will be performed.
1054
+ # security.scan_schedule.duration: 0
1055
+
1056
+ # Specifies a cron expression that sets when the IAST scan should run.
1057
+ # security.scan_schedule.schedule: ""
1058
+
1059
+ # Defines the endpoint URL for posting security-related data
1060
+ # security.validator_service_url: wss://csec.nr-data.net
1061
+
1062
+ # END security agent
1063
+
919
1064
  # Environment-specific settings are in this section.
920
1065
  # RAILS_ENV or RACK_ENV (as appropriate) is used to determine the environment.
921
1066
  # If your application has other named environments, configure them here.
data/test/agent_helper.rb CHANGED
@@ -112,7 +112,14 @@ def assert_log_contains(log, message)
112
112
  lines = log.array
113
113
 
114
114
  assert (lines.any? { |line| line.match(message) }),
115
- "Could not find message. Log contained: #{lines.join("\n")}"
115
+ "Could not find message: '#{message.inspect}'. Log contained: #{lines.join("\n")}"
116
+ end
117
+
118
+ def refute_log_contains(log, message)
119
+ lines = log.array
120
+
121
+ refute (lines.any? { |line| line.match(message) }),
122
+ "Found message: '#{message.inspect}'. Log contained: #{lines.join("\n")}"
116
123
  end
117
124
 
118
125
  def assert_audit_log_contains(audit_log_contents, needle)
metadata CHANGED
@@ -1,17 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: newrelic_rpm
3
3
  version: !ruby/object:Gem::Version
4
- version: 9.12.0
4
+ version: 9.17.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tanna McClure
8
8
  - Kayla Reopelle
9
9
  - James Bunch
10
10
  - Hannah Ramadan
11
- autorequire:
12
11
  bindir: bin
13
12
  cert_chain: []
14
- date: 2024-07-24 00:00:00.000000000 Z
13
+ date: 2025-01-29 00:00:00.000000000 Z
15
14
  dependencies:
16
15
  - !ruby/object:Gem::Dependency
17
16
  name: bundler
@@ -344,6 +343,7 @@ files:
344
343
  - lib/new_relic/agent/external.rb
345
344
  - lib/new_relic/agent/guid_generator.rb
346
345
  - lib/new_relic/agent/harvester.rb
346
+ - lib/new_relic/agent/health_check.rb
347
347
  - lib/new_relic/agent/heap.rb
348
348
  - lib/new_relic/agent/hostname.rb
349
349
  - lib/new_relic/agent/http_clients/abstract.rb
@@ -392,6 +392,18 @@ files:
392
392
  - lib/new_relic/agent/instrumentation/async_http/chain.rb
393
393
  - lib/new_relic/agent/instrumentation/async_http/instrumentation.rb
394
394
  - lib/new_relic/agent/instrumentation/async_http/prepend.rb
395
+ - lib/new_relic/agent/instrumentation/aws_sdk_firehose.rb
396
+ - lib/new_relic/agent/instrumentation/aws_sdk_firehose/chain.rb
397
+ - lib/new_relic/agent/instrumentation/aws_sdk_firehose/instrumentation.rb
398
+ - lib/new_relic/agent/instrumentation/aws_sdk_firehose/prepend.rb
399
+ - lib/new_relic/agent/instrumentation/aws_sdk_kinesis.rb
400
+ - lib/new_relic/agent/instrumentation/aws_sdk_kinesis/chain.rb
401
+ - lib/new_relic/agent/instrumentation/aws_sdk_kinesis/instrumentation.rb
402
+ - lib/new_relic/agent/instrumentation/aws_sdk_kinesis/prepend.rb
403
+ - lib/new_relic/agent/instrumentation/aws_sdk_lambda.rb
404
+ - lib/new_relic/agent/instrumentation/aws_sdk_lambda/chain.rb
405
+ - lib/new_relic/agent/instrumentation/aws_sdk_lambda/instrumentation.rb
406
+ - lib/new_relic/agent/instrumentation/aws_sdk_lambda/prepend.rb
395
407
  - lib/new_relic/agent/instrumentation/aws_sqs.rb
396
408
  - lib/new_relic/agent/instrumentation/aws_sqs/chain.rb
397
409
  - lib/new_relic/agent/instrumentation/aws_sqs/instrumentation.rb
@@ -484,6 +496,10 @@ files:
484
496
  - lib/new_relic/agent/instrumentation/net_http/instrumentation.rb
485
497
  - lib/new_relic/agent/instrumentation/net_http/prepend.rb
486
498
  - lib/new_relic/agent/instrumentation/notifications_subscriber.rb
499
+ - lib/new_relic/agent/instrumentation/opensearch.rb
500
+ - lib/new_relic/agent/instrumentation/opensearch/chain.rb
501
+ - lib/new_relic/agent/instrumentation/opensearch/instrumentation.rb
502
+ - lib/new_relic/agent/instrumentation/opensearch/prepend.rb
487
503
  - lib/new_relic/agent/instrumentation/padrino.rb
488
504
  - lib/new_relic/agent/instrumentation/padrino/chain.rb
489
505
  - lib/new_relic/agent/instrumentation/padrino/instrumentation.rb
@@ -505,6 +521,10 @@ files:
505
521
  - lib/new_relic/agent/instrumentation/rake/chain.rb
506
522
  - lib/new_relic/agent/instrumentation/rake/instrumentation.rb
507
523
  - lib/new_relic/agent/instrumentation/rake/prepend.rb
524
+ - lib/new_relic/agent/instrumentation/rdkafka.rb
525
+ - lib/new_relic/agent/instrumentation/rdkafka/chain.rb
526
+ - lib/new_relic/agent/instrumentation/rdkafka/instrumentation.rb
527
+ - lib/new_relic/agent/instrumentation/rdkafka/prepend.rb
508
528
  - lib/new_relic/agent/instrumentation/redis.rb
509
529
  - lib/new_relic/agent/instrumentation/redis/chain.rb
510
530
  - lib/new_relic/agent/instrumentation/redis/cluster_middleware.rb
@@ -523,6 +543,10 @@ files:
523
543
  - lib/new_relic/agent/instrumentation/roda/instrumentation.rb
524
544
  - lib/new_relic/agent/instrumentation/roda/prepend.rb
525
545
  - lib/new_relic/agent/instrumentation/roda/roda_transaction_namer.rb
546
+ - lib/new_relic/agent/instrumentation/ruby_kafka.rb
547
+ - lib/new_relic/agent/instrumentation/ruby_kafka/chain.rb
548
+ - lib/new_relic/agent/instrumentation/ruby_kafka/instrumentation.rb
549
+ - lib/new_relic/agent/instrumentation/ruby_kafka/prepend.rb
526
550
  - lib/new_relic/agent/instrumentation/ruby_openai.rb
527
551
  - lib/new_relic/agent/instrumentation/ruby_openai/chain.rb
528
552
  - lib/new_relic/agent/instrumentation/ruby_openai/instrumentation.rb
@@ -606,6 +630,8 @@ files:
606
630
  - lib/new_relic/agent/samplers/object_sampler.rb
607
631
  - lib/new_relic/agent/samplers/vm_sampler.rb
608
632
  - lib/new_relic/agent/serverless_handler.rb
633
+ - lib/new_relic/agent/serverless_handler_event_sources.json
634
+ - lib/new_relic/agent/serverless_handler_event_sources.rb
609
635
  - lib/new_relic/agent/span_event_aggregator.rb
610
636
  - lib/new_relic/agent/span_event_primitive.rb
611
637
  - lib/new_relic/agent/sql_sampler.rb
@@ -668,6 +694,8 @@ files:
668
694
  - lib/new_relic/control/class_methods.rb
669
695
  - lib/new_relic/control/frameworks.rb
670
696
  - lib/new_relic/control/frameworks/external.rb
697
+ - lib/new_relic/control/frameworks/grape.rb
698
+ - lib/new_relic/control/frameworks/padrino.rb
671
699
  - lib/new_relic/control/frameworks/rails.rb
672
700
  - lib/new_relic/control/frameworks/rails3.rb
673
701
  - lib/new_relic/control/frameworks/rails4.rb
@@ -747,7 +775,6 @@ metadata:
747
775
  documentation_uri: https://docs.newrelic.com/docs/agents/ruby-agent
748
776
  source_code_uri: https://github.com/newrelic/newrelic-ruby-agent
749
777
  homepage_uri: https://newrelic.com/ruby
750
- post_install_message:
751
778
  rdoc_options: []
752
779
  require_paths:
753
780
  - lib
@@ -762,8 +789,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
762
789
  - !ruby/object:Gem::Version
763
790
  version: 1.3.1
764
791
  requirements: []
765
- rubygems_version: 3.5.11
766
- signing_key:
792
+ rubygems_version: 3.6.2
767
793
  specification_version: 4
768
794
  summary: New Relic Ruby Agent
769
795
  test_files: []