Fixed merge

main
Elbert Alias 10 years ago
commit 688be92d47

2
.gitignore vendored

@ -5,3 +5,5 @@ wappalyzer.xpi
!.gitkeep
node_modules/*
drivers/npm/node_modules/

@ -0,0 +1,3 @@
wappalyzer.js
apps.json
node_modules/

@ -0,0 +1,96 @@
# Wappalyzer
This is npm module for wappalyzer
npm install wappalyzer
var wappalyzer = require("wappalyzer");
var options={
url : "http://codelanka.github.io/Presentation-Engines",
hostname:"codelanka.github.io",
debug:false
}
wappalyzer.detectFromUrl(options,function (err,apps,appInfo) {
console.log(err,apps,appInfo);
})
####Output
null [ 'AngularJS',
'Font Awesome',
'Google Font API',
'jQuery',
'Twitter Bootstrap' ] { AngularJS:
{ app: 'AngularJS',
confidence:
{ 'script //([\\d.]+(\\-?rc[.\\d]*)*)/angular(\\.min)?\\.js/i': 100,
'script /angular.*\\.js/i': 100 },
confidenceTotal: 100,
detected: true,
excludes: [],
version: '1.3.5',
versions: [ '1.3.5' ] },
'Font Awesome':
{ app: 'Font Awesome',
confidence: { 'html /<link[^>]* href=[^>]+font-awesome(?:\\.min)?\\.css/i': 100 },
confidenceTotal: 100,
detected: true,
excludes: [],
version: '',
versions: [] },
'Google Font API':
{ app: 'Google Font API',
confidence: { 'html /<link[^>]* href=[^>]+fonts\\.(?:googleapis|google)\\.com/i': 100 },
confidenceTotal: 100,
detected: true,
excludes: [],
version: '',
versions: [] },
jQuery:
{ app: 'jQuery',
confidence: { 'script /jquery.*\\.js/i': 100 },
confidenceTotal: 100,
detected: true,
excludes: [],
version: '',
versions: [] },
'Twitter Bootstrap':
{ app: 'Twitter Bootstrap',
confidence:
{ 'script /(?:twitter\\.github\\.com/bootstrap|bootstrap(?:\\.js|\\.min\\.js))/i': 100,
'html /<link.+?href="[^"]+bootstrap(?:\\.min)?\\.css/i': 100 },
confidenceTotal: 100,
detected: true,
excludes: [],
version: '',
versions: [] } }
Wappalyzer Author - Elbert Alias
[Wappalyzer](https://wappalyzer.com/) is a
[cross-platform](https://github.com/ElbertF/Wappalyzer/wiki/Drivers) utility that uncovers the
technologies used on websites. It detects
[content management systems](https://wappalyzer.com/categories/cms),
[eCommerce platforms](https://wappalyzer.com/categories/ecommerce),
[web servers](https://wappalyzer.com/categories/web-servers),
[JavaScript frameworks](https://wappalyzer.com/categories/javascript-frameworks),
[analytics tools](https://wappalyzer.com/categories/analytics) and
[many more](https://wappalyzer.com/applications).
Refer to the [wiki](https://github.com/ElbertF/Wappalyzer/wiki) for
[screenshots](https://github.com/ElbertF/Wappalyzer/wiki/Screenshots), information on how to
[contribute](https://github.com/ElbertF/Wappalyzer/wiki/Contributing) and
[more](https://github.com/ElbertF/Wappalyzer/wiki/_pages).
*Licensed under the [GPL](https://github.com/ElbertF/Wappalyzer/blob/master/LICENSE).*
Donate Bitcoin: 16gb4uGDAjaeRJwKVmKr2EXa8x2fmvT8EQ - *Thanks!*
![QR Code](https://wappalyzer.com/sites/default/themes/wappalyzer/images/bitcoinqrcode.png)

@ -0,0 +1,11 @@
var wappalyzer = require("./index");
var options={
url : "http://codelanka.github.io/Presentation-Engines",
hostname:"codelanka.github.io",
debug:false
}
wappalyzer.detectFromUrl(options,function (err,apps,appInfo) {
console.log(err,apps,appInfo);
})

@ -0,0 +1,83 @@
var request = require('request');
var fs = require("fs");
var path =require("path");
//TODO
exports.detectFromHTML = function (options) {};
exports.detectFromUrl = function (options,cb) {
var url = options.url;
if (options.debug ) {
console.log("Fetching the page");
};
getHTMLFromUrl(url,function (err,data) {
if (err) {
cb(err,null)
}else{
runWrappalyer(options,data, function (err,detected,appInfo) {
cb(null,detected,appInfo)
});
}
})
}
function getHTMLFromUrl (url,cb) {
request(url, function(error, response, body) {
if (!error && response.statusCode == 200) {
var data = {
html: body,
url: url,
headers: response
};
cb(null,data);
}else{
cb(error,null)
}
});
}
function getAppsJson(cb) {
fs.readFile(path.resolve(__dirname, 'apps.json'), 'utf8', function(err, data) {
if (err) throw err;
return cb(null, JSON.parse(data))
});
}
function runWrappalyer(options,data,cb) {
var debug = options.debug || false;
var wappalyzer = require("./wappalyzer").wappalyzer;
getAppsJson(function(err, apps) {
var w = wappalyzer;
w.driver = {
log: function(args) {
if (debug) {
console.log(args.message);
};
},
init: function() {
w.categories = apps.categories;
w.apps = apps.apps;
},
displayApps: function() {
var app,url = Object.keys(w.detected)[0];
var detectedApps = [];
for (app in w.detected[url]) {
detectedApps.push(app);
if (debug) {
console.log(app);
};
};
cb(null,detectedApps,w.detected[url])
}
}
w.init();
w.analyze(options.hostname,options.url, data)
});
}

@ -0,0 +1,28 @@
{
"name": "wrappalyzer",
"version": "2.0.0",
"description": "NPM Module that uncovers the technologies used on websites",
"main": "index.js",
"scripts": {
"test": "mocha -t 15000"
},
"repository": {
"type": "git",
"url": "https://github.com/ElbertF/Wappalyze"
},
"keywords": [
"wappalyzer"
],
"author": "Pasindu De Silva",
"license": "GPLv3",
"bugs": {
"url": "https://github.com/ElbertF/Wappalyze/issues"
},
"homepage": "https://github.com/ElbertF/Wappalyze",
"directories": {
"test": "test"
},
"dependencies": {
"request": "^2.51.0"
}
}

@ -0,0 +1,27 @@
var assert = require("assert")
describe('wappalyzer', function(){
describe('detectFromUrl', function(){
it('should have the expected apps detected', function(done){
var wappalyzer = require("../index");
var expect = ['AngularJS','Font Awesome','Google Font API','jQuery','Twitter Bootstrap'];
var options={
url : "http://codelanka.github.io/Presentation-Engines",
hostname:"codelanka.github.io",
debug:false
}
wappalyzer.detectFromUrl(options,function (err,apps) {
assert.equal(expect[0], apps[0]);
assert.equal(expect[1], apps[1]);
assert.equal(expect[2], apps[2]);
assert.equal(expect[3], apps[3]);
done();
})
})
})
})

@ -109,3 +109,10 @@ mklink /h drivers\phantomjs\apps.json share\apps.json
if exist drivers\phantomjs\js\wappalyzer.js del drivers\phantomjs\js\wappalyzer.js
mklink /h drivers\phantomjs\js\wappalyzer.js share\js\wappalyzer.js
:: NPM Module
if exist drivers\npm\apps.json del drivers\npm\apps.json
mklink /h drivers\npm\apps.json share\apps.json
if exist drivers\npm\wappalyzer.js del drivers\npm\wappalyzer.npm
mklink /h drivers\npm\wappalyzer.js share\wappalyzer.js

@ -26,3 +26,6 @@ ln -f share/js/wappalyzer.js drivers/phantomjs/js
ln -f share/apps.json drivers/ruby
ln -f share/js/wappalyzer.js drivers/ruby/js
ln -f share/apps.json drivers/npm
ln -f share/js/wappalyzer.js drivers/npm

@ -623,9 +623,9 @@
"Ckan": {
"website": "ckan.org/",
"cats": [ 1 ],
"headers": {
"headers": {
"Access-Control-Allow-Headers": "X-CKAN-API-KEY",
"Link": "<http://ckan.org/>; rel=shortlink"
"Link": "<http://ckan.org/>; rel=shortlink"
},
"implies": [ "Python", "Solr", "Java", "PostgreSQL\\;confidence:80" ]
},
@ -778,6 +778,12 @@
"cats": [ 22 ],
"headers": { "Server": "CouchDB/([\\d.]+)\\;version:\\1" }
},
"Cowboy": {
"website": "ninenines.eu",
"cats": [ 18, 22 ],
"headers": { "Server": "Cowboy" },
"implies": "Erlang"
},
"cPanel": {
"website": "www.cpanel.net",
"cats": [ 9 ],
@ -1064,6 +1070,11 @@
"headers": { "Server": "\\beHTTP(?: v?([\\d\\.]+))?\\;version:\\1" },
"implies": "HP ProCurve"
},
"Elm": {
"website": "elm-lang.org",
"cats": [ 27, 12 ],
"env": "^Elm$"
},
"ELOG": {
"website": "midas.psi.ch/elog",
"cats": [ 19 ],
@ -1442,7 +1453,7 @@
"Google PageSpeed": {
"website": "developers.google.com/speed/pagespeed/mod",
"cats": [ 23, 33 ],
"headers": { "X-Mod-Pagespeed": "([\\d.]+)\\;version:\\1" }
"headers": { "X-Mod-Pagespeed": "([\\d.]+)\\;version:\\1", "X-Page-Speed": "(.+)\\;version:\\1" }
},
"Google Sites": {
"website": "sites.google.com",
@ -3054,6 +3065,11 @@
"cats": [ 22 ],
"headers": { "Server": "RAID HTTPServer(?:/([\\d.]+))?\\;version:\\1" }
},
"Ramda": {
"website": "ramdajs.com",
"cats": [ 12 ],
"script": "ramda.*\\.js"
},
"Raphael": {
"website": "raphaeljs.com",
"cats": [ 25 ],
@ -3159,6 +3175,12 @@
"headers": { "Server": "(?:mod_rails|mod_rack|Phusion(?:\\.|_)Passenger)\\;confidence:50", "X-Powered-By": "(?:mod_rails|mod_rack|Phusion[\\._ ]Passenger)(?: \\(mod_rails/mod_rack\\))?(?: ?/?([\\d\\.]+))?\\;version:\\1\\;confidence:50" },
"implies": "Ruby"
},
"RxJS" : {
"website": "reactive-extensions.github.io/RxJS/",
"cats": [ 12 ],
"script": "rx(?:\\.\\w+)?(?:\\.compat)?(?:\\.min)?\\.js",
"env": "^Rx$\\;confidence:20"
},
"S.Builder": {
"website": "www.sbuilder.ru",
"cats": [ 1 ],
@ -3488,6 +3510,14 @@
"headers": { "X-ServedBy": "squarespace" },
"env": "^Squarespace"
},
"SquirrelMail": {
"website": "squirrelmail.org",
"cats": [ 30 ],
"html": "<small>SquirrelMail version ([.\\d]+)[^<]*<br \\;version:\\1",
"url": "/src/webmail\\.php(?:$|\\?)",
"env": "^squirrelmail_loginpage_onload$",
"implies": "PHP"
},
"Squiz Matrix": {
"website": "squiz.net",
"cats": [ 1 ],

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 582 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 480 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 860 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 369 B