Module: Contrast::Agent::Assess

Defined in:
lib/contrast/agent/assess/assess.rb,
lib/contrast/agent/assess/tag.rb,
lib/contrast/agent/assess/tracker.rb,
lib/contrast/agent/assess/properties.rb,
lib/contrast/agent/assess/policy/policy.rb,
lib/contrast/agent/assess/rule/provider.rb,
lib/contrast/agent/assess/policy/patcher.rb,
lib/contrast/agent/assess/contrast_object.rb,
lib/contrast/agent/assess/finalizers/hash.rb,
lib/contrast/agent/assess/policy/preshift.rb,
lib/contrast/agent/assess/property/tagged.rb,
lib/contrast/agent/assess/property/evented.rb,
lib/contrast/agent/assess/property/updated.rb,
lib/contrast/agent/assess/events/event_data.rb,
lib/contrast/agent/assess/policy/propagator.rb,
lib/contrast/agent/assess/policy/policy_node.rb,
lib/contrast/agent/assess/policy/source_node.rb,
lib/contrast/agent/assess/policy/trigger_node.rb,
lib/contrast/agent/assess/policy/source_method.rb,
lib/contrast/agent/assess/policy/trigger/xpath.rb,
lib/contrast/agent/assess/policy/policy_scanner.rb,
lib/contrast/agent/assess/policy/trigger_method.rb,
lib/contrast/agent/assess/policy/propagator/base.rb,
lib/contrast/agent/assess/policy/propagator/keep.rb,
lib/contrast/agent/assess/policy/propagator/next.rb,
lib/contrast/agent/assess/policy/propagator/trim.rb,
lib/contrast/agent/assess/policy/propagation_node.rb,
lib/contrast/agent/assess/policy/propagator/splat.rb,
lib/contrast/agent/assess/policy/propagator/split.rb,
lib/contrast/agent/assess/rule/response/base_rule.rb,
lib/contrast/agent/assess/rule/response/body_rule.rb,
lib/contrast/agent/assess/policy/policy_node_utils.rb,
lib/contrast/agent/assess/policy/propagator/append.rb,
lib/contrast/agent/assess/policy/propagator/buffer.rb,
lib/contrast/agent/assess/policy/propagator/center.rb,
lib/contrast/agent/assess/policy/propagator/custom.rb,
lib/contrast/agent/assess/policy/propagator/insert.rb,
lib/contrast/agent/assess/policy/propagator/remove.rb,
lib/contrast/agent/assess/policy/propagator/select.rb,
lib/contrast/agent/assess/policy/propagation_method.rb,
lib/contrast/agent/assess/policy/propagator/prepend.rb,
lib/contrast/agent/assess/policy/propagator/replace.rb,
lib/contrast/agent/assess/policy/propagator/reverse.rb,
lib/contrast/agent/assess/rule/response/header_rule.rb,
lib/contrast/agent/assess/policy/propagator/response.rb,
lib/contrast/agent/assess/rule/provider/hardcoded_key.rb,
lib/contrast/agent/assess/policy/propagator/match_data.rb,
lib/contrast/agent/assess/policy/trigger/reflected_xss.rb,
lib/contrast/agent/assess/policy/dynamic_source_factory.rb,
lib/contrast/agent/assess/policy/propagator/substitution.rb,
lib/contrast/agent/assess/rule/response/hsts_header_rule.rb,
lib/contrast/agent/assess/policy/propagator/database_write.rb,
lib/contrast/agent/assess/rule/provider/hardcoded_password.rb,
lib/contrast/agent/assess/rule/response/auto_complete_rule.rb,
lib/contrast/agent/assess/policy/propagator/rack_protection.rb,
lib/contrast/agent/assess/rule/provider/hardcoded_value_rule.rb,
lib/contrast/agent/assess/policy/propagator/substitution_utils.rb,
lib/contrast/agent/assess/rule/response/csp_header_missing_rule.rb,
lib/contrast/agent/assess/rule/response/framework/rails_support.rb,
lib/contrast/agent/assess/rule/response/csp_header_insecure_rule.rb,
lib/contrast/agent/assess/policy/trigger_validation/xss_validator.rb,
lib/contrast/agent/assess/rule/response/cache_control_header_rule.rb,
lib/contrast/agent/assess/rule/response/click_jacking_header_rule.rb,
lib/contrast/agent/assess/rule/response/parameters_pollution_rule.rb,
lib/contrast/agent/assess/policy/trigger_validation/ssrf_validator.rb,
lib/contrast/agent/assess/rule/response/x_content_type_header_rule.rb,
lib/contrast/agent/assess/policy/trigger_validation/redos_validator.rb,
lib/contrast/agent/assess/policy/source_validation/source_validation.rb,
lib/contrast/agent/assess/rule/response/x_xss_protection_header_rule.rb,
lib/contrast/agent/assess/policy/trigger_validation/trigger_validation.rb,
lib/contrast/agent/assess/policy/source_validation/cross_site_validator.rb,
ext/cs__common/cs__common.c

Overview

This is the base module for our assess classes. It is intended to facilitate the patching of the application for Assess functionality. Any class under this namespace should be required here, providing a single point of require for this functionality.

Defined Under Namespace

Modules: Events, Finalizers, Policy, Property, Rule Classes: ContrastObject, PreShift, Properties, Tag, Tracker

Class Method Summary collapse

Class Method Details

.contrast_force_repatch_regexp(*args) ⇒ Object



9
10
11
12
# File 'ext/cs__assess_regexp/cs__assess_regexp.c', line 9

extern VALUE contrast_force_patch(const int argc, VALUE *argv) {
    return contrast_check_and_register_instance_patch(
        "Regexp", "=~", contrast_assess_regexp_equal_squiggle);
}

.cs__object_method_prepended?(object_name, method_name, is_instance) ⇒ Boolean

used for passing object to look if not called on itself. Contrast::Agent::Assess.cs__object_method_prepended? object, :method_name, true/false

Returns:

  • (Boolean)


191
192
193
194
195
196
197
198
# File 'ext/cs__common/cs__common.c', line 191

extern VALUE contrast_lookout_prepended(VALUE self, VALUE object_name,
                                        VALUE method_name, VALUE is_instance) {
    /* object_name must be the object, the self value is needed to prevent
     lookout for self, since is always passed first we skip it */
    VALUE result =
        _contrast_check_prepended(object_name, method_name, is_instance);
    return result;
}