Sha256: c18ae2a8e39fd36ba59f4360f5b10fb8a1b1b71bc73748a42772c3e360f671ae

Contents?: true

Size: 899 Bytes

Versions: 24

Compression:

Stored size: 899 Bytes

Contents

# Copyright (c) 2022 Contrast Security, Inc. See https://www.contrastsecurity.com/enduser-terms-0317a for more details.
# frozen_string_literal: true

module Contrast
  module Utils
    module Assess
      # This module extends the Split class which is specifically for String#split & String#grapheme_clusters
      # propagation it propagates tag ranges from a string to elements within an untracked array
      module SplitUtils
        private

        # Quick hook to the String#split propagation node in our Assess policy
        #
        # @return [Contrast::Agent::Assess::Policy::PropagationNode] String#split node
        def split_node
          @_split_node ||= Contrast::Agent::Assess::Policy::Policy.instance.propagators.find do |node|
            node.class_name == 'String' && node.method_name == :split && node.instance_method?
          end
        end
      end
    end
  end
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
contrast-agent-6.11.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.10.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.9.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.8.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.7.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.6.5 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.6.4 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.6.3 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.6.2 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.6.1 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.6.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.5.1 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.5.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.4.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.3.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.2.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.1.2 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.1.1 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.1.0 lib/contrast/utils/assess/split_utils.rb
contrast-agent-6.0.0 lib/contrast/utils/assess/split_utils.rb