"Fossies" - the Fresh Open Source Software Archive

Member "WhatWeb-0.5.5/plugins-disabled/adobe-flash-urls.rb" (15 Jan 2021, 1332 Bytes) of package /linux/www/WhatWeb-0.5.5.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Ruby source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file.

    1 ##
    2 # This file is part of WhatWeb and may be subject to
    3 # redistribution and commercial restrictions. Please see the WhatWeb
    4 # web site for more information on licensing and terms of use.
    5 # https://www.morningstarsecurity.com/research/whatweb
    6 ##
    7 Plugin.define do
    8 name "Adobe-Flash-URLs"
    9 authors [
   10   "Caleb Anderson",
   11   "Brendan Coles <bcoles@gmail.com>", # v0.2 # Added JavaScript detection. Added <embed> element detection. Added flash file path retrieval. 
   12 ]
   13 version "0.2"
   14 description "This plugin identifies instances of embedded adobe flash files and attempts to retrieve the flash file path."
   15 
   16 # Google results as at 2010-10-14 #
   17 # 244 for "your browser does not support flash"
   18 
   19 
   20 
   21 # Matches #
   22 matches [
   23 
   24 # Object tag
   25 { :regexp=>/<object[^>]+application\/x-shockwave-flash[^>]+>.*?<\/object>/im },
   26 
   27 # Extract flash file path from <embed> elements
   28 { :string=>/<embed[^>]+src[\s]*=[\s]*'([^\s^'^>]+)/i },
   29 { :string=>/<embed[^>]+src[\s]*=[\s]*"([^\s^"^>]+)/i },
   30 
   31 # Extract flash file path from Javascript
   32 { :string=>/new[\s]+FlashObject[\s]*\([\s]*'([^\']+)/ },
   33 { :string=>/new[\s]+FlashObject[\s]*\([\s]*"([^\"]+)/ },
   34 { :string=>/new[\s]+SWFObject[\s]*\([\s]*'([^\']+)/ },
   35 { :string=>/new[\s]+SWFObject[\s]*\([\s]*"([^\"]+)/ },
   36 { :string=>/.embedSWF[\s]*\([\s]*'([^\']+)/},
   37 { :string=>/.embedSWF[\s]*\([\s]*"([^\"]+)/ },
   38 
   39 ]
   40 
   41 end
   42