Sha256: 53eafd256bf31e76482a3a50e8b57f373bb3ff005cfd33114602f4601f213a6d
Contents?: true
Size: 751 Bytes
Versions: 3
Compression:
Stored size: 751 Bytes
Contents
=begin Copyright 2010-2015 Tasos Laskos <tasos.laskos@arachni-scanner.com> This file is part of the Arachni Framework project and is subject to redistribution and commercial restrictions. Please see the Arachni Framework web site for more information on licensing and terms of use. =end # Extract paths from HTML comments. # # @author Tasos "Zapotek" Laskos <tasos.laskos@arachni-scanner.com> # @version 0.2.1 class Arachni::Parser::Extractors::Comments < Arachni::Parser::Extractors::Base def run return [] if !includes?( '<!--' ) document.xpath( '//comment()' ).map do |comment| comment.text.scan( /(^|\s)(\/[\/a-zA-Z0-9%._-]+)/ ) end.flatten.select { |s| s.start_with? '/' } end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
arachni-1.3.2 | components/path_extractors/comments.rb |
arachni-1.3.1 | components/path_extractors/comments.rb |
arachni-1.3 | components/path_extractors/comments.rb |