Renamed adapter to drivers, fixed FF driver bugs, added Programming Languages category

main
ElbertF 13 years ago
parent 3a0381cc9a
commit bef9b89ab0

2
.gitignore vendored

@ -1 +1 @@
adapters/firefox/wappalyzer.xpi
drivers/firefox/wappalyzer.xpi

@ -1,39 +0,0 @@
<!ENTITY wappalyzer.name "Wappalyzer">
<!ENTITY wappalyzer.showIcons "Show application icons">
<!ENTITY wappalyzer.tracking "Allow anonymous tracking">
<!ENTITY wappalyzer.addonBar "Place in addon-bar">
<!ENTITY wappalyzer.categories "Manage categories">
<!ENTITY wappalyzer.donate "Donate!">
<!ENTITY wappalyzer.feedback "Feedback">
<!ENTITY wappalyzer.github "Fork on Github">
<!ENTITY wappalyzer.twitter "Twitter">
<!ENTITY wappalyzer.gplus "Google Plus">
<!ENTITY wappalyzer.website "Visit wappalyzer.com">
<!ENTITY wappalyzer.cat1 "CMS">
<!ENTITY wappalyzer.cat2 "Message boards">
<!ENTITY wappalyzer.cat3 "Database managers">
<!ENTITY wappalyzer.cat4 "Documentation tools">
<!ENTITY wappalyzer.cat5 "Widgets">
<!ENTITY wappalyzer.cat6 "Web shops">
<!ENTITY wappalyzer.cat7 "Photo galleries">
<!ENTITY wappalyzer.cat8 "Wikis">
<!ENTITY wappalyzer.cat9 "Hosting panels">
<!ENTITY wappalyzer.cat10 "Analytics">
<!ENTITY wappalyzer.cat11 "Blogs">
<!ENTITY wappalyzer.cat12 "JavaScript frameworks">
<!ENTITY wappalyzer.cat13 "Issue trackers">
<!ENTITY wappalyzer.cat14 "Video players">
<!ENTITY wappalyzer.cat15 "Comment systems">
<!ENTITY wappalyzer.cat16 "CAPTCHAs">
<!ENTITY wappalyzer.cat17 "Font scripts">
<!ENTITY wappalyzer.cat18 "Web frameworks">
<!ENTITY wappalyzer.cat19 "Miscellaneous">
<!ENTITY wappalyzer.cat20 "Editors">
<!ENTITY wappalyzer.cat21 "LMS">
<!ENTITY wappalyzer.cat22 "Web servers">
<!ENTITY wappalyzer.cat23 "Cache tools">
<!ENTITY wappalyzer.cat24 "Rich text editors">
<!ENTITY wappalyzer.cat25 "Javascript Graphics">

@ -5,13 +5,11 @@
if ( content.document.contentType != 'text/html' ) return;
// Environment variables
var sandbox = Components.utils.Sandbox(content);
var env = new Array;
sandbox.win = content;
Components.utils.evalInSandbox('var env = new Array; for ( i in win.wrappedJSObject ) if ( typeof i === "string" ) env.push(i);', sandbox);
var env = sandbox.env;
for ( i in content.wrappedJSObject ) {
if ( typeof i === "string" ) env.push(i);
}
// HTML
var html = content.document.documentElement.innerHTML

@ -1,5 +1,5 @@
/**
* Firefox adapter
* Firefox driver
*/
(function() {
@ -7,9 +7,9 @@
var w = wappalyzer;
var $, prefs, strings;
var w$, prefs, strings;
w.adapter = {
w.driver = {
/**
* Log messages to console
*/
@ -28,7 +28,7 @@
var handler = function() {
window.removeEventListener('load', handler, false);
w.log('w.adapter: browser window loaded');
w.log('w.driver: browser window loaded');
strings = document.getElementById('wappalyzer-strings');
@ -37,9 +37,12 @@
(function () {
var window;
Services.scriptloader.loadSubScript(addon.getResourceURI('content/js/lib/jquery.min.js').spec, this);
Components.classes['@mozilla.org/moz/jssubscript-loader;1']
.getService(Components.interfaces.mozIJSSubScriptLoader)
.loadSubScript('chrome://wappalyzer/content/js/lib/jquery.min.js')
;
$ = jQuery.noConflict(true);
w$ = jQuery.noConflict(true);
})();
// Preferences
@ -67,7 +70,7 @@
gBrowser.addProgressListener({
// Listen for location changes
onLocationChange: function(progress, request, location, flags) {
w.adapter.displayApps();
w.driver.displayApps();
},
// Get response headers
@ -84,14 +87,14 @@
}
});
gBrowser.tabContainer.addEventListener('TabSelect', w.adapter.displayApps, false);
gBrowser.tabContainer.addEventListener('TabSelect', w.driver.displayApps, false);
callback();
});
};
window.addEventListener('load', handler, false);
window.addEventListener('unload', w.adapter.track, false);
window.addEventListener('unload', w.driver.track, false);
},
/**
@ -100,15 +103,15 @@
displayApps: function() {
var url = gBrowser.currentURI.spec;
$('#wappalyzer-container > image, #wappalyzer-menu > menuitem, #wappalyzer-menu > menuseparator').remove();
w$('#wappalyzer-container > image, #wappalyzer-menu > menuitem, #wappalyzer-menu > menuseparator').remove();
if ( w.detected[url] != null && w.detected[url].length ) {
if ( !prefs.getBoolPref('showIcons') ) {
var image = $('<image/>')
var image = w$('<image/>')
.attr('src', 'chrome://wappalyzer/skin/images/icon16x16_hot.ico')
;
$('#wappalyzer-container').prepend(image);
w$('#wappalyzer-container').prepend(image);
}
w.detected[url].map(function(app, i) {
@ -124,55 +127,60 @@
if ( display ) {
if ( prefs.getBoolPref('showIcons') ) {
var image = $('<image/>')
var image = w$('<image/>')
.attr('src', 'chrome://wappalyzer/skin/images/icons/' + app + '.ico')
;
$('#wappalyzer-container').prepend(image);
w$('#wappalyzer-container').prepend(image);
}
var menuSeparator = $('<menuseparator/>');
var menuSeparator = w$('<menuseparator/>');
$('#wappalyzer-menu').append(menuSeparator);
w$('#wappalyzer-menu').append(menuSeparator);
var menuItem = $('<menuitem/>')
var menuItem = w$('<menuitem/>')
.attr('class', 'wappalyzer-application')
.attr('image', 'chrome://wappalyzer/skin/images/icons/' + app + '.ico')
.attr('label', app)
;
menuItem.bind('command', function() {
w.adapter.goToURL({ url: w.config.websiteURL + 'stats/app/' + escape(app) });
w.driver.goToURL({ url: w.config.websiteURL + 'applications/' + app.toLowerCase().replace(/ /g, '-').replace(/[^a-z0-9-]/g, '') });
});
$('#wappalyzer-menu').append(menuItem);
w$('#wappalyzer-menu').append(menuItem);
for ( cat in w.apps[app].cats ) {
var menuItem = $('<menuitem/>')
.attr('disabled', 'true')
var menuItem = w$('<menuitem/>')
.attr('class', 'wappalyzer-category')
.attr('label', w.categories[w.apps[app].cats[cat]].name)
;
$('#wappalyzer-menu').append(menuItem);
menuItem.bind('command', function() {
w.driver.goToURL({ url: w.config.websiteURL + 'categories/' + w.categories[w.apps[app].cats[cat]].plural.toLowerCase().replace(/ /g, '-').replace(/[^a-z0-9-]/g, '') });
});
w$('#wappalyzer-menu').append(menuItem);
}
}
});
} else {
var image = $('<image/>')
var image = w$('<image/>')
.attr('src', 'chrome://wappalyzer/skin/images/icon16x16.ico')
;
$('#wappalyzer-container').prepend(image);
w$('#wappalyzer-container').prepend(image);
var menuSeparator = $('<menuseparator/>');
var menuSeparator = w$('<menuseparator/>');
$('#wappalyzer-menu').append(menuSeparator);
w$('#wappalyzer-menu').append(menuSeparator);
var menuItem = $('<menuitem/>')
var menuItem = w$('<menuitem/>')
.attr('disabled', 'true')
.attr('label', strings.getString('wappalyzer.noAppsDetected'))
;
$('#wappalyzer-menu').append(menuItem);
w$('#wappalyzer-menu').append(menuItem);
}
},
@ -215,7 +223,7 @@
if ( request.status == 200 ) {
w.history = new Object();
w.log('w.adapter.track: ' + report);
w.log('w.driver.track: ' + report);
}
report = '';
@ -247,74 +255,71 @@
* Move container to address or addon bar
*/
function container() {
$('#wappalyzer-container')
w$('#wappalyzer-container')
.remove()
.prependTo(prefs.getBoolPref('addonBar') ? $('#wappalyzer-addonbar') : $('#urlbar-icons'));
.prependTo(prefs.getBoolPref('addonBar') ? w$('#wappalyzer-addonbar') : w$('#urlbar-icons'));
// Menu items
var prefix = '#wappalyzer-menu-';
$(prefix + 'icons')
w$(prefix + 'icons')
.attr('checked', prefs.getBoolPref('showIcons') ? 'true' : 'false')
.bind('command', function() {
prefs.setBoolPref('showIcons', !prefs.getBoolPref('showIcons'));
$(this).attr('checked', prefs.getBoolPref('showIcons') ? 'true' : 'false');
w$(this).attr('checked', prefs.getBoolPref('showIcons') ? 'true' : 'false');
w.adapter.displayApps();
w.driver.displayApps();
});
$(prefix + 'tracking' )
.attr('checked', prefs.getBoolPref('tracking') ? 'true' : 'false')
w$(prefix + 'preferences' )
.bind('command', function() {
prefs.setBoolPref('tracking', !prefs.getBoolPref('tracking'));
$(this).attr('checked', prefs.getBoolPref('tracking') ? 'true' : 'false');
w.driver.goToURL({ url: 'chrome://wappalyzer/content/xul/preferences.xul' })
});
$(prefix + 'addonbar' )
w$(prefix + 'addonbar' )
.attr('checked', prefs.getBoolPref('addonBar') ? 'true' : 'false')
.bind('command', function() {
prefs.setBoolPref('addonBar', !prefs.getBoolPref('addonBar'));
$(this).attr('checked', prefs.getBoolPref('addonBar') ? 'true' : 'false');
w$(this).attr('checked', prefs.getBoolPref('addonBar') ? 'true' : 'false');
container();
});
$(prefix + 'categories')
w$(prefix + 'categories')
.bind('command', function() {
w.adapter.goToURL({ url: 'chrome://wappalyzer/content/xul/categories.xul' })
w.driver.goToURL({ url: 'chrome://wappalyzer/content/xul/categories.xul' })
});
$(prefix + 'donate')
w$(prefix + 'donate')
.bind('command', function() {
w.adapter.goToURL({ url: w.config.websiteURL + 'donate/' })
w.driver.goToURL({ url: w.config.websiteURL + 'donate' })
});
$(prefix + 'feedback')
w$(prefix + 'feedback')
.bind('command', function() {
w.adapter.goToURL({ url: w.config.websiteURL + '?redirect=feedback' })
w.driver.goToURL({ url: w.config.websiteURL + 'contact' })
});
$(prefix + 'website')
w$(prefix + 'website')
.bind('command', function() {
w.adapter.goToURL({ url: w.config.websiteURL })
w.driver.goToURL({ url: w.config.websiteURL })
});
$(prefix + 'github' )
w$(prefix + 'github' )
.bind('command', function() {
w.adapter.goToURL({ url: w.config.githubURL })
w.driver.goToURL({ url: w.config.githubURL })
});
$(prefix + 'twitter')
w$(prefix + 'twitter')
.bind('command', function() {
w.adapter.goToURL({ url: w.config.twitterURL})
w.driver.goToURL({ url: w.config.twitterURL})
});
$(prefix + 'gplus')
w$(prefix + 'gplus')
.bind('command', function() {
w.adapter.goToURL({ url: w.config.gplusURL })
w.driver.goToURL({ url: w.config.gplusURL })
});
}

@ -33,11 +33,14 @@
<preference id="wappalyzer-cat23" name="extensions.wappalyzer.cat23" type="bool"/>
<preference id="wappalyzer-cat24" name="extensions.wappalyzer.cat24" type="bool"/>
<preference id="wappalyzer-cat25" name="extensions.wappalyzer.cat25" type="bool"/>
<preference id="wappalyzer-tracking" name="extensions.wappalyzer.tracking" type="bool"/>
</preferences>
<tabbox>
<tabs>
<tab label="&wappalyzer.categories;"/>
<tab label="&wappalyzer.tracking;"/>
</tabs>
<tabpanels>
<tabpanel id="tab-categories">
@ -146,6 +149,22 @@
</grid>
</groupbox>
</tabpanel>
<tabpanel id="tab-tracking">
<groupbox>
<grid>
<columns>
<column flex="1"/>
</columns>
<rows>
<row>
<hbox align="center">
<checkbox preference="wappalyzer-tracking" id="wappalyzer-option-tracking" label="&wappalyzer.research;"/>
</hbox>
</row>
</rows>
</grid>
</groupbox>
</tabpanel>
</tabpanels>
</tabbox>
</prefpane>

@ -7,7 +7,7 @@
<overlay id="wappalyzer-overlay" xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<script type="application/x-javascript" src="chrome://wappalyzer/content/js/wappalyzer.js"/>
<script type="application/x-javascript" src="chrome://wappalyzer/content/js/apps.js"/>
<script type="application/x-javascript" src="chrome://wappalyzer/content/js/adapter.js"/>
<script type="application/x-javascript" src="chrome://wappalyzer/content/js/driver.js"/>
<stringbundleset id="stringbundleset">
<stringbundle id="wappalyzer-strings" src="chrome://wappalyzer/locale/wappalyzer.properties"/>
@ -19,9 +19,8 @@
<menu label="&wappalyzer.name;">
<menupopup>
<menuitem id="wappalyzer-menu-icons" label="&wappalyzer.showIcons;" />
<menuitem id="wappalyzer-menu-tracking" label="&wappalyzer.tracking;" />
<menuitem id="wappalyzer-menu-addonbar" label="&wappalyzer.addonBar;" />
<menuitem id="wappalyzer-menu-categories" label="&wappalyzer.categories;"/>
<menuitem id="wappalyzer-menu-preferences" label="&wappalyzer.preferences;"/>
<menuseparator/>

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

@ -3,7 +3,7 @@
<RDF xmlns="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:em="http://www.mozilla.org/2004/em-rdf#">
<Description about="urn:mozilla:install-manifest">
<em:id>wappalyzer@crunchlabz.com</em:id>
<em:version>2.0.0</em:version>
<em:version>2.0.1</em:version>
<em:type>2</em:type>
<em:unpack>true</em:unpack>

@ -0,0 +1,41 @@
<!ENTITY wappalyzer.name "Wappalyzer">
<!ENTITY wappalyzer.showIcons "Show application icons">
<!ENTITY wappalyzer.preferences "More options...">
<!ENTITY wappalyzer.addonBar "Place in addon-bar">
<!ENTITY wappalyzer.categories "Manage categories">
<!ENTITY wappalyzer.tracking "Tracking">
<!ENTITY wappalyzer.research "Anonymously send reports on detected applications to wappalyzer.com for research">
<!ENTITY wappalyzer.donate "Donate!">
<!ENTITY wappalyzer.feedback "Feedback">
<!ENTITY wappalyzer.github "Github">
<!ENTITY wappalyzer.twitter "Twitter">
<!ENTITY wappalyzer.gplus "Google Plus">
<!ENTITY wappalyzer.website "Go to wappalyzer.com">
<!ENTITY wappalyzer.cat1 "CMS">
<!ENTITY wappalyzer.cat2 "Message boards">
<!ENTITY wappalyzer.cat3 "Database managers">
<!ENTITY wappalyzer.cat4 "Documentation tools">
<!ENTITY wappalyzer.cat5 "Widgets">
<!ENTITY wappalyzer.cat6 "Web shops">
<!ENTITY wappalyzer.cat7 "Photo galleries">
<!ENTITY wappalyzer.cat8 "Wikis">
<!ENTITY wappalyzer.cat9 "Hosting panels">
<!ENTITY wappalyzer.cat10 "Analytics">
<!ENTITY wappalyzer.cat11 "Blogs">
<!ENTITY wappalyzer.cat12 "JavaScript frameworks">
<!ENTITY wappalyzer.cat13 "Issue trackers">
<!ENTITY wappalyzer.cat14 "Video players">
<!ENTITY wappalyzer.cat15 "Comment systems">
<!ENTITY wappalyzer.cat16 "CAPTCHAs">
<!ENTITY wappalyzer.cat17 "Font scripts">
<!ENTITY wappalyzer.cat18 "Web frameworks">
<!ENTITY wappalyzer.cat19 "Miscellaneous">
<!ENTITY wappalyzer.cat20 "Editors">
<!ENTITY wappalyzer.cat21 "LMS">
<!ENTITY wappalyzer.cat22 "Web servers">
<!ENTITY wappalyzer.cat23 "Cache tools">
<!ENTITY wappalyzer.cat24 "Rich text editors">
<!ENTITY wappalyzer.cat25 "Javascript Graphics">

@ -7,3 +7,7 @@
margin-left: 3px;
width: 16px;
}
menuitem.wappalyzer-application {
font-weight: bold;
}

Before

Width:  |  Height:  |  Size: 714 B

After

Width:  |  Height:  |  Size: 714 B

Before

Width:  |  Height:  |  Size: 782 B

After

Width:  |  Height:  |  Size: 782 B

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Before

Width:  |  Height:  |  Size: 22 KiB

After

Width:  |  Height:  |  Size: 22 KiB

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

Before

Width:  |  Height:  |  Size: 610 B

After

Width:  |  Height:  |  Size: 610 B

Before

Width:  |  Height:  |  Size: 1.1 KiB

After

Width:  |  Height:  |  Size: 1.1 KiB

Before

Width:  |  Height:  |  Size: 12 KiB

After

Width:  |  Height:  |  Size: 12 KiB

@ -8,7 +8,7 @@
<script type="text/javascript" src="js/wappalyzer.js"></script>
<script type="text/javascript" src="js/apps.js"></script>
<script type="text/javascript" src="js/adapter.js"></script>
<script type="text/javascript" src="js/driver.js"></script>
<style type="text/css">
body {

@ -3,7 +3,7 @@
var w = wappalyzer;
w.adapter = {
w.driver = {
/**
* Log messages to console
*/

Binary file not shown.

After

Width:  |  Height:  |  Size: 414 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 822 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Before

Width:  |  Height:  |  Size: 4.2 KiB

After

Width:  |  Height:  |  Size: 4.2 KiB

@ -29,7 +29,8 @@
23: { name: 'Cache tool', plural: 'Cache tools' },
24: { name: 'Rich text editor', plural: 'Rich text editors' },
25: { name: 'Javascript graphics', plural: 'Javascript graphics' },
26: { name: 'Mobile framework', plural: 'Mobile frameworks' }
26: { name: 'Mobile framework', plural: 'Mobile frameworks' },
27: { name: 'Programming Language', plural: 'Programming Languages' }
};
w.apps = {
@ -39,8 +40,9 @@
'Adobe GoLive': { cats: { 1: 20 }, meta: { 'generator': /Adobe GoLive/i } },
'Advanced Web Stats': { cats: { 1: 10 }, html: /aws.src = [^<]+caphyon\-analytics/i },
'Amiro.CMS': { cats: { 1: 1 }, meta: { 'generator': /Amiro/i } },
'Apache': { cats: { 1: 22 }, headers: { 'Server': /Apache/i } },
'Apache': { cats: { 1: 22 }, headers: { 'Server': /Apache($|[^-])/i } },
'Apache Tomcat': { cats: { 1: 22 }, headers: { 'Server': /Apache-Coyote/i } },
'Arc Forum': { cats: { 1: 2 }, html: /ping\.src = node\.href;/ },
'Atlassian Confluence': { cats: { 1: 8 }, html: /Powered by <a href=.http:\/\/www\.atlassian\.com\/software\/confluence/i },
'Atlassian Jira': { cats: { 1: 13 }, html: /Powered by <a href=.http:\/\/www\.atlassian\.com\/software\/jira/i },
'AWStats': { cats: { 1: 10 }, meta: { 'generator': /AWStats/i } },
@ -68,6 +70,7 @@
'ConversionLab': { cats: { 1: 10 }, script: /conversionlab\.trackset\.com\/track\/tsend\.js/ },
'Coppermine': { cats: { 1: 7 }, html: /<!--Coppermine Photo Gallery/i },
'Cotonti': { cats: { 1: 1 }, meta: { 'generator': /Cotonti/i } },
'CouchDB': { cats: { 1: 22 }, headers: { 'Server': /CouchDB/i } },
'cPanel': { cats: { 1: 9 }, html: /<!-- cPanel/i },
'Crazy Egg': { cats: { 1: 10 }, script: /cetrk\.com\/pages\/scripts\/[0-9]+\/[0-9]+\.js/ },
'CS Cart': { cats: { 1: 6 }, html: /&nbsp;Powered by (<a href=.http:\/\/www\.cs\-cart\.com|CS\-Cart)/i },
@ -84,7 +87,7 @@
'DokuWiki': { cats: { 1: 8 }, meta: { 'generator': /DokuWiki/i } },
'DotNetNuke': { cats: { 1: 1 }, meta: { 'generator': /DotNetNuke/i }, html: /<!\-\- by DotNetNuke Corporation/i },
'DreamWeaver': { cats: { 1: 20 }, html: /(<!\-\-[^>]*(InstanceBeginEditable|Dreamweaver[^>]+target|DWLayoutDefaultTable)|function MM_preloadImages\(\) {)/ },
'Drupal': { cats: { 1: 1 }, script: /drupal\.js/, html: /(jQuery\.extend\(Drupal\.settings, \{|Drupal\.extend\(\{ settings: \{|<link[^>]+sites\/(default|all)\/themes\/|<style[^>]+sites\/(default|all)\/(themes|modules)\/)/i, headers: { 'X-Drupal-Cache': /.*/, 'Expires': /19 Nov 1978/ }, env: /^Drupal$/ },
'Drupal': { cats: { 1: 1 }, script: /drupal\.js/, html: /(jQuery\.extend\(Drupal\.settings, \{|Drupal\.extend\(\{ settings: \{|<link[^>]+sites\/(default|all)\/themes\/|<style[^>]+sites\/(default|all)\/(themes|modules)\/)/i, headers: { 'X-Drupal-Cache': /.*/, 'X-Generator': /Drupal/, 'Expires': /19 Nov 1978/ }, env: /^Drupal$/ },
'Drupal Commerce': { cats: { 1: 6 }, html: /id\=\"block\-commerce\-cart\-cart|class\=\"commerce\-product\-field/i },
'Dynamicweb': { cats: { 1: 1 }, meta: { 'generator': /Dynamicweb/i } },
'e107': { cats: { 1: 1 }, script: /e107\.js/ },
@ -101,6 +104,7 @@
'Google Font API': { cats: { 1: 17 }, html: /<link[^>]* href=("|')http:\/\/fonts\.googleapis\.com/ },
'Google Friend Connect': { cats: { 1: 5 }, script: /google.com\/friendconnect/ },
'Google Maps': { cats: { 1: 5 }, script: /(maps\.google\.com\/maps\?file=api|maps\.google\.com\/maps\/api\/staticmap)/ },
'Google Sites': { cats: { 1: 1 }, url: /sites.google.com/ },
'Graffiti CMS': { cats: { 1: 1 }, meta: { 'generator': /Graffiti CMS/i } },
'Gravity Insights': { cats: { 1: 10 }, html: /gravityInsightsParams\.site_guid = '/ },
'Hiawatha': { cats: { 1: 22 }, headers: { 'Server': /Hiawatha/i } },
@ -166,6 +170,7 @@
'osCSS': { cats: { 1: 6 }, html: /<body onload=("|')window\.defaultStatus='oscss templates';("|')/i },
'PANSITE': { cats: { 1: 1 }, meta: { 'generator': /PANSITE/i } },
'papaya CMS': { cats: { 1: 1 }, html: /<link[^>]*\/papaya-themes\//i },
'PHP': { cats: { 1: 27 }, headers: { 'Server': /php/i, 'X-Powered-By': /php/i }, url: /\.php$/ },
'PHP-Fusion': { cats: { 1: 1 }, html: /Powered by <a href=("|')[^>]+php-fusion/i },
'PHP-Nuke': { cats: { 1: 2 }, meta: { 'generator': /PHP-Nuke/i }, html: /<[^>]+Powered by PHP\-Nuke/i },
'phpBB': { cats: { 1: 2 }, meta: { 'copyright': /phpBB Group/ }, html: /Powered by (<a href=("|')[^>]+)?phpBB/i },
@ -217,6 +222,7 @@
'Trac': { cats: { 1: 13 }, html: /(<a id=("|')tracpowered)/i },
'Tumblr': { cats: { 1: 11 }, html: /<iframe src=("|')http:\/\/www\.tumblr\.com/i, url: /^(www.)?.+\.tumblr\.com/i, headers: { 'X-Tumblr-Usec': /.*/ } },
'Twilight CMS': { cats: { 1: 1 }, headers: { 'X-Powered-CMS': /Twilight CMS/ } },
'Twitter Bootstrap': { cats: { 1: 18 }, script: /twitter\.github\.com\/bootstrap/, html: /<link[^>]+bootstrap[^>]+css/, env: /^Twipsy$/ },
'Typekit': { cats: { 1: 17 }, script: /use.typekit.com/, env: /^Typekit$/ },
'TypePad': { cats: { 1: 11 }, meta: { 'generator': /typepad/i }, url: /^(www.)?.+\.typepad\.com/i },
'TYPO3': { cats: { 1: 1 }, meta: { 'generator': /TYPO3/i }, html: /(<(script[^>]* src|link[^>]* href)=[^>]*fileadmin)/i, url: /\/typo3/i },
@ -244,7 +250,7 @@
'Webtrends': { cats: { 1: 10 }, html: /<img[^>]+id=("|')DCSIMG("|')[^>]+webtrends/i, env: /WTOptimize/i },
'Weebly': { cats: { 1: 1 }, html: /<[^>]+class=("|')weebly/i },
'WikkaWiki': { cats: { 1: 8 }, meta: { 'generator': /WikkaWiki/ }, html: /Powered by <a href=("|')[^>]+WikkaWiki/i },
'wink': { cats: { 1: 26, 2: 12 }, script: /(\_base\/js\/base|wink).*\.js/i, env:/^wink$/ },
'wink': { cats: { 1: 26, 2: 12 }, script: /(\_base\/js\/base|wink).*\.js/i, env: /^wink$/ },
'Wolf CMS': { cats: { 1: 1 }, html: /<a href=("|')[^>]+wolfcms.org.+Wolf CMS.+inside/i },
'Woopra': { cats: { 1: 10 }, script: /static\.woopra\.com/ },
'WordPress': { cats: { 1: 1, 2: 11 }, meta: { 'generator': /WordPress/i }, html: /<link rel=("|')stylesheet("|') [^>]+wp-content/i },
@ -252,7 +258,7 @@
'XenForo': { cats: { 1: 2 }, html: /(jQuery\.extend\(true, XenForo|Forum software by XenForo&trade;|<!\-\-XF:branding)/ },
'XiTi': { cats: { 1: 10 }, html: /<[^>]+src=("|')[^>]+xiti.com\/hit.xiti/i },
'XMB': { cats: { 1: 2 }, html: /<!-- Powered by XMB/i },
'XUI': { cats: { 1: 26, 2: 12 }, script: /[^a-zA-Z]xui.*\.js/i, env:/^x\$$/ },
'XUI': { cats: { 1: 26, 2: 12 }, script: /[^a-zA-Z]xui.*\.js/i, env: /^x\$$/ },
'XOOPS': { cats: { 1: 1 }, meta: { 'generator': /XOOPS/i } },
'xtCommerce': { cats: { 1: 6 }, meta: { 'generator': /xt:Commerce/ }, html: /<div class=("|')copyright("|')>.+<a[^>]+>xt:Commerce/i },
'YaBB': { cats: { 1: 2 }, html: /Powered by <a href=("|')[^>]+yabbforum/i },

@ -8,18 +8,18 @@
var wappalyzer = wappalyzer || (function() {
/**
* Call adapter functions
* Call driver functions
*/
var adapter = function(func, args) {
if ( typeof w.adapter[func] !== 'function' ) {
w.log('not implemented: w.adapter.' + func, 'warn');
var driver = function(func, args) {
if ( typeof w.driver[func] !== 'function' ) {
w.log('not implemented: w.driver.' + func, 'warn');
return;
}
if ( func != 'log' ) w.log('w.adapter.' + func);
if ( func != 'log' ) w.log('w.driver.' + func);
return w.adapter[func](args);
return w.driver[func](args);
};
/**
@ -51,7 +51,7 @@ var wappalyzer = wappalyzer || (function() {
if ( w.config.environment === 'dev' ) {
if ( type == null ) type = 'debug';
adapter('log', { message: '[wappalyzer ' + type + '] ' + message, type: type });
driver('log', { message: '[wappalyzer ' + type + '] ' + message, type: type });
}
},
@ -62,8 +62,8 @@ var wappalyzer = wappalyzer || (function() {
w.log('w.init');
// Checks
if ( w.adapter == null ) {
w.log('no adapter, exiting');
if ( w.driver == null ) {
w.log('no driver, exiting');
return;
}
@ -74,10 +74,10 @@ var wappalyzer = wappalyzer || (function() {
return;
}
// Initialize adapter
adapter('init', function() {
if ( w.config.firstRun ) adapter('goToURL', { url: w.config.websiteURL + 'install/success' });
if ( w.config.upgraded ) adapter('goToURL', { url: w.config.websiteURL + 'install/upgraded' });
// Initialize driver
driver('init', function() {
if ( w.config.firstRun ) driver('goToURL', { url: w.config.websiteURL + 'installed' });
if ( w.config.upgraded ) driver('goToURL', { url: w.config.websiteURL + 'upgraded' });
});
},
@ -138,7 +138,7 @@ var wappalyzer = wappalyzer || (function() {
if ( new RegExp('name=["\']' + meta + '["\']', 'i').test(match) ) {
var content = match.toString().match(/content=("|')([^"']+)("|')/i);
if ( w.apps[app].meta[meta].test(content[2]) ) {
if ( content && w.apps[app].meta[meta].test(content[2]) ) {
apps.push(app);
break;
@ -153,6 +153,7 @@ var wappalyzer = wappalyzer || (function() {
for ( var header in w.apps[app].headers ) {
if ( data[type][header] != null && w.apps[app][type][header].test(data[type][header]) ) {
if ( app == 'PHP' ) alert('x');
apps.push(app);
break;
@ -194,7 +195,7 @@ var wappalyzer = wappalyzer || (function() {
w.history[hostname][index].hits ++;
}
if ( Object.keys(w.history).length >= 200 ) adapter('track');
if ( Object.keys(w.history).length >= 200 ) driver('track');
}
// Per URL
@ -206,7 +207,7 @@ var wappalyzer = wappalyzer || (function() {
delete apps, data;
}
adapter('displayApps');
driver('displayApps');
}
};

@ -1,12 +1,12 @@
#!/bin/sh
ln -is ../../../../share/images/icons adapters/firefox/skin/images/
ln -is ../../../../share/js/lib adapters/firefox/content/js/
ln -is ../../../../share/js/apps.js adapters/firefox/content/js/
ln -is ../../../../share/js/wappalyzer.js adapters/firefox/content/js/
ln -is ../../../../share/images/icons drivers/firefox/skin/images/
ln -is ../../../../share/js/lib drivers/firefox/content/js/
ln -is ../../../../share/js/apps.js drivers/firefox/content/js/
ln -is ../../../../share/js/wappalyzer.js drivers/firefox/content/js/
ln -is ../../../share/images/icons adapters/html/images/
ln -is ../../../share/js/lib adapters/html/js/
ln -is ../../../share/js/apps.js adapters/html/js/
ln -is ../../../share/js/wappalyzer.js adapters/html/js/
ln -is ../../../share/images/icons drivers/html/images/
ln -is ../../../share/js/lib drivers/html/js/
ln -is ../../../share/js/apps.js drivers/html/js/
ln -is ../../../share/js/wappalyzer.js drivers/html/js/