Sha256: 7254110c7e743ee2b6daede37c0715c1a05cdd97b510ad4b14ec704c62fee478

Contents?: true

Size: 850 Bytes

Versions: 5

Compression:

Stored size: 850 Bytes

Contents

=begin
                  Arachni
  Copyright (c) 2010-2012 Tasos "Zapotek" Laskos <tasos.laskos@gmail.com>

  This is free software; you can copy and distribute and modify
  this program under the term of the GPL v2.0 License
  (See LICENSE file for details)

=end

module Arachni::Parser::Extractors

#
# Extracts paths from frames.
#
# @author: Tasos "Zapotek" Laskos
#                                      <tasos.laskos@gmail.com>
#                                      <zapotek@segfault.gr>
# @version: 0.1
#
class Frames < Paths

    #
    # Returns an array of paths as plain strings
    #
    # @param    [Nokogiri]  Nokogiri document
    #
    # @return   [Array<String>]  paths
    #
    def run( doc )
        doc.css( 'frame', 'iframe' ).map {
            |a|
            a.attributes['src'].content rescue next
        }
    end

end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
arachni-0.4.0.4 path_extractors/frames.rb
arachni-0.4.0.3 path_extractors/frames.rb
arachni-0.4.0.2 path_extractors/frames.rb
arachni-0.4.0.1 path_extractors/frames.rb
arachni-0.4 path_extractors/frames.rb