Replace PhantomJS with Zombie in NPM driver

main
Elbert Alias 8 years ago
parent 5c721af2ce
commit 2d59ae8a01

@ -4,11 +4,11 @@ cd "$(dirname $0)/../src"
echo "Creating links..."
ln -nsf ../../apps.json drivers/npm
ln -nsf ../../wappalyzer.js drivers/npm
ln -nf apps.json drivers/npm
ln -nf wappalyzer.js drivers/npm
ln -nsf ../../apps.json drivers/webextension
ln -nsf ../../../wappalyzer.js drivers/webextension/js
ln -nsf ../../../icons/ drivers/webextension/images/icons
ln -nf apps.json drivers/webextension
ln -nf wappalyzer.js drivers/webextension/js
ln -nsf ../../../icons/ drivers/webextension/images/icons
echo "Done."

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

@ -1,24 +1,14 @@
FROM ubuntu:latest
FROM alpine
MAINTAINER Elbert Alias <elbert@alias.io>
ENV DEBIAN_FRONTEND noninteractive
ENV WAPPALYZER_ROOT /opt/wappalyzer
ENV WAPPALYZER_ROOT /usr/local/wappalyzer
RUN sed -i 's/archive\.ubuntu\.com/au.archive.ubuntu.com/g' /etc/apt/sources.list
RUN \
apt-get update && apt-get install -y \
libfreetype6 \
libfontconfig \
RUN apk update && apk add --no-cache \
nodejs \
npm \
&& apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
RUN ln -s $(which nodejs) /usr/bin/node
nodejs-npm
RUN mkdir "$WAPPALYZER_ROOT"
RUN mkdir -p "$WAPPALYZER_ROOT"
WORKDIR "$WAPPALYZER_ROOT"

@ -21,7 +21,7 @@ $ npm i wappalyzer
## Run from the command line
```shell
$ node index.js https://wappalyzer.com --quiet
$ node index.js https://wappalyzer.com
```
@ -30,28 +30,11 @@ $ node index.js https://wappalyzer.com --quiet
```javascript
const wappalyzer = require('wappalyzer');
wappalyzer.run(['https://wappalyzer.com', '--quiet'], function(stdout, stderr) {
if ( stdout ) {
process.stdout.write(stdout);
}
if ( stderr ) {
process.stderr.write(stderr);
}
});
wappalyzer('https://wappalyzer.com')
.then(json => {
console.log(JSON.stringify(json, null, 2));
})
.catch(error => {
console.error(error);
});
```
## Arguments
**-v, --verbose**
Display debug output.
**-q, --quiet**
Suppress errors.
**--resource-timeout=ms**
Abort the connection after 'ms' milliseconds.

@ -1,228 +1,83 @@
/**
* PhantomJS driver
*/
/** global: phantom */
/** global: wappalyzer */
(function() {
var
url,
originalUrl,
scriptDir,
scriptPath = require('fs').absolute(require('system').args[0]),
resourceTimeout = 9000,
args = [], // TODO: Not used, maybe should be `arg`
debug = false, // Output debug messages
quiet = false; // Don't output errors
try {
// Working directory
scriptDir = scriptPath.split('/'); scriptDir.pop(); scriptDir = scriptDir.join('/');
require('fs').changeWorkingDirectory(scriptDir);
require('system').args.forEach(function(arg) {
var
value,
arr = /^(--[^=]+)=(.+)$/.exec(arg);
if ( arr && arr.length === 3 ) {
arg = arr[1];
value = arr[2];
}
switch ( arg ) {
case '-v':
case '--verbose':
debug = true;
break;
case '-q':
case '--quiet':
quiet = true;
break;
case '--resource-timeout':
if ( value ) {
resourceTimeout = value;
}
break;
default:
url = originalUrl = arg;
}
});
if ( !url ) {
throw new Error('Usage: phantomjs ' + require('system').args[0] + ' <url>');
}
if ( !phantom.injectJs('wappalyzer.js') ) {
throw new Error('Unable to open file js/wappalyzer.js');
}
wappalyzer.driver = {
timeout: 1000,
/**
* Log messages to console
*/
log: function(args) {
if ( args.type === 'error' ) {
if ( !quiet ) {
require('system').stderr.write(args.message + "\n");
}
} else if ( debug || args.type !== 'debug' ) {
require('system').stdout.write(args.message + "\n");
}
},
/**
* Display apps
*/
displayApps: function() {
var
app, cats,
apps = [];
wappalyzer.log('driver.displayApps');
for ( app in wappalyzer.detected[url] ) {
cats = [];
wappalyzer.apps[app].cats.forEach(function(cat) {
cats.push(wappalyzer.categories[cat].name);
});
apps.push({
name: app,
confidence: wappalyzer.detected[url][app].confidenceTotal.toString(),
version: wappalyzer.detected[url][app].version,
icon: wappalyzer.apps[app].icon || 'default.svg',
website: wappalyzer.apps[app].website,
categories: cats
});
}
wappalyzer.driver.sendResponse(apps);
},
/**
* Send response
*/
sendResponse: function(apps) {
apps = apps || [];
require('system').stdout.write(JSON.stringify({ url: url, originalUrl: originalUrl, applications: apps }) + "\n");
},
/**
* Initialize
*/
init: function() {
var
page, hostname,
headers = {},
a = document.createElement('a'),
json = JSON.parse(require('fs').read('apps.json'));
wappalyzer.log('driver.init');
a.href = url.replace(/#.*$/, '');
hostname = a.hostname;
wappalyzer.apps = json.apps;
wappalyzer.categories = json.categories;
page = require('webpage').create();
page.settings.loadImages = false;
page.settings.userAgent = 'Mozilla/5.0 (compatible; Wappalyzer; +https://github.com/AliasIO/Wappalyzer)';
page.settings.resourceTimeout = resourceTimeout;
page.onError = function(message) {
wappalyzer.log(message, 'error');
};
page.onResourceTimeout = function() {
wappalyzer.log('Resource timeout', 'error');
wappalyzer.driver.sendResponse();
phantom.exit(1);
};
page.onResourceReceived = function(response) {
if ( response.url.replace(/\/$/, '') === url.replace(/\/$/, '') ) {
if ( response.redirectURL ) {
url = response.redirectURL;
return;
}
if ( response.stage === 'end' && response.status === 200 && response.contentType.indexOf('text/html') !== -1 ) {
response.headers.forEach(function(header) {
headers[header.name.toLowerCase()] = header.value;
});
}
}
};
page.onResourceError = function(resourceError) {
wappalyzer.log(resourceError.errorString, 'error');
};
'use strict';
page.open(url, function(status) {
var html, environmentVars = '';
const wappalyzer = require('./wappalyzer');
const request = require('request');
const fs = require('fs');
const Browser = require('zombie');
if ( status === 'success' ) {
html = page.content;
const json = JSON.parse(fs.readFileSync(__dirname + '/apps.json'));
if ( html.length > 50000 ) {
html = html.substring(0, 25000) + html.substring(html.length - 25000, html.length);
}
wappalyzer.apps = json.apps;
wappalyzer.categories = json.categories;
// Collect environment variables
environmentVars = page.evaluate(function() {
var i, environmentVars = '';
const driver = {
quiet: true,
for ( i in window ) {
environmentVars += i + ' ';
}
analyze: url => {
return new Promise((resolve, reject) => {
wappalyzer.driver.log = (message, source, type) => {
if ( type === 'error' ) {
return reject(message);
}
return environmentVars;
});
if ( !driver.quiet ) {
console.log('[wappalyzer ' + type + ']', '[' + source + ']', message);
}
};
wappalyzer.log({ message: 'environmentVars: ' + environmentVars });
wappalyzer.driver.displayApps = detected => {
var apps = [];
environmentVars = environmentVars.split(' ').slice(0, 500);
Object.keys(detected).forEach(appName => {
const app = detected[appName];
wappalyzer.analyze(hostname, url, {
html: html,
headers: headers,
env: environmentVars
});
var categories = [];
phantom.exit(0);
} else {
wappalyzer.log('Failed to fetch page', 'error');
app.props.cats.forEach(id => {
var category = {};
wappalyzer.driver.sendResponse();
category[id] = wappalyzer.categories[id].name;
phantom.exit(1);
}
});
}
};
categories.push(category)
});
wappalyzer.init();
} catch ( e ) {
wappalyzer.log(e, 'error');
apps.push({
name: app.name,
confidence: app.confidenceTotal.toString(),
version: app.version,
icon: app.props.icon || 'default.svg',
website: app.props.website,
categories
});
});
wappalyzer.driver.sendResponse();
resolve(apps);
};
phantom.exit(1);
}
})();
const browser = new Browser();
browser.visit(url, error => {
if ( error ) {
return reject(error);
}
wappalyzer.driver.document = browser.document;
const headers = browser.resources['0'].response.headers;
const vars = Object.getOwnPropertyNames(browser.window);
const html = browser.html();
const hostname = wappalyzer.parseUrl(url).hostname;
wappalyzer.analyze(hostname, url, {
headers,
html,
env: vars
});
});
});
}
}
module.exports = driver;

@ -1,32 +1,25 @@
'use strict';
const
path = require('path'),
spawn = require('child_process').spawn,
phantomjs = require('phantomjs-prebuilt');
const wappalyzer = require('./driver');
exports.run = function(args, callback) {
args.unshift.apply(args, [path.join(__dirname, 'driver.js'), '--web-security=false', '--load-images=false', '--ignore-ssl-errors=yes', '--ssl-protocol=any']);
const args = process.argv.slice(2);
var driver = phantomjs.exec.apply(this, args);
const url = args[0] || '';
driver.stdout.on('data', (data) => {
callback(`${data}`, null);
});
if ( !url ) {
process.stderr.write('No URL specified\n');
driver.stderr.on('data', (data) => {
callback(null, `${data}`);
});
process.exit(1);
}
if ( !module.parent ) {
exports.run(process.argv.slice(2), function(stdout, stderr) {
if ( stdout ) {
process.stdout.write(stdout);
}
wappalyzer.analyze(url)
.then(json => {
process.stdout.write(JSON.stringify(json, null, 2) + '\n')
if ( stderr ) {
process.stderr.write(stderr);
}
});
}
process.exit(0);
})
.catch(error => {
process.stderr.write(error + '\n')
process.exit(1);
});

@ -2,20 +2,22 @@
"name": "Wappalyzer",
"description": "Uncovers the technologies used on websites",
"homepage": "https://github.com/AliasIO/Wappalyzer",
"version": "4.1.5",
"version": "5.0.0",
"author": "Elbert Alias",
"license": "GPL-3.0",
"repository": {
"type": "git",
"url": "https://github.com/AliasIO/Wappalyzer"
},
"main": "index.js",
"files": [
"apps.json",
"driver.js",
"wappalyzer.js"
],
"main": "driver.js",
"files": [
"apps.json",
"index.js",
"driver.js",
"wappalyzer.js"
],
"dependencies": {
"phantomjs-prebuilt": "*"
"request": "^2.81.0",
"zombie": "^5.0.7"
}
}

@ -1,501 +0,0 @@
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1
ansi-regex@^2.0.0:
version "2.1.1"
resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-2.1.1.tgz#c3b33ab5ee360d86e0e628f0468ae7ef27d654df"
ansi-styles@^2.2.1:
version "2.2.1"
resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe"
asn1@~0.2.3:
version "0.2.3"
resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.3.tgz#dac8787713c9966849fc8180777ebe9c1ddf3b86"
assert-plus@1.0.0, assert-plus@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525"
assert-plus@^0.2.0:
version "0.2.0"
resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-0.2.0.tgz#d74e1b87e7affc0db8aadb7021f3fe48101ab234"
asynckit@^0.4.0:
version "0.4.0"
resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79"
aws-sign2@~0.6.0:
version "0.6.0"
resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.6.0.tgz#14342dd38dbcc94d0e5b87d763cd63612c0e794f"
aws4@^1.2.1:
version "1.6.0"
resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.6.0.tgz#83ef5ca860b2b32e4a0deedee8c771b9db57471e"
bcrypt-pbkdf@^1.0.0:
version "1.0.1"
resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.1.tgz#63bc5dcb61331b92bc05fd528953c33462a06f8d"
dependencies:
tweetnacl "^0.14.3"
boom@2.x.x:
version "2.10.1"
resolved "https://registry.yarnpkg.com/boom/-/boom-2.10.1.tgz#39c8918ceff5799f83f9492a848f625add0c766f"
dependencies:
hoek "2.x.x"
caseless@~0.11.0:
version "0.11.0"
resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.11.0.tgz#715b96ea9841593cc33067923f5ec60ebda4f7d7"
chalk@^1.1.1:
version "1.1.3"
resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98"
dependencies:
ansi-styles "^2.2.1"
escape-string-regexp "^1.0.2"
has-ansi "^2.0.0"
strip-ansi "^3.0.0"
supports-color "^2.0.0"
combined-stream@^1.0.5, combined-stream@~1.0.5:
version "1.0.5"
resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.5.tgz#938370a57b4a51dea2c77c15d5c5fdf895164009"
dependencies:
delayed-stream "~1.0.0"
commander@^2.9.0:
version "2.11.0"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.11.0.tgz#157152fd1e7a6c8d98a5b715cf376df928004563"
concat-stream@1.5.0:
version "1.5.0"
resolved "https://registry.yarnpkg.com/concat-stream/-/concat-stream-1.5.0.tgz#53f7d43c51c5e43f81c8fdd03321c631be68d611"
dependencies:
inherits "~2.0.1"
readable-stream "~2.0.0"
typedarray "~0.0.5"
core-util-is@~1.0.0:
version "1.0.2"
resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7"
cryptiles@2.x.x:
version "2.0.5"
resolved "https://registry.yarnpkg.com/cryptiles/-/cryptiles-2.0.5.tgz#3bdfecdc608147c1c67202fa291e7dca59eaa3b8"
dependencies:
boom "2.x.x"
dashdash@^1.12.0:
version "1.14.1"
resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0"
dependencies:
assert-plus "^1.0.0"
debug@0.7.4:
version "0.7.4"
resolved "https://registry.yarnpkg.com/debug/-/debug-0.7.4.tgz#06e1ea8082c2cb14e39806e22e2f6f757f92af39"
delayed-stream@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619"
ecc-jsbn@~0.1.1:
version "0.1.1"
resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.1.tgz#0fc73a9ed5f0d53c38193398523ef7e543777505"
dependencies:
jsbn "~0.1.0"
es6-promise@~4.0.3:
version "4.0.5"
resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.0.5.tgz#7882f30adde5b240ccfa7f7d78c548330951ae42"
escape-string-regexp@^1.0.2:
version "1.0.5"
resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4"
extend@~3.0.0:
version "3.0.1"
resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.1.tgz#a755ea7bc1adfcc5a31ce7e762dbaadc5e636444"
extract-zip@~1.5.0:
version "1.5.0"
resolved "https://registry.yarnpkg.com/extract-zip/-/extract-zip-1.5.0.tgz#92ccf6d81ef70a9fa4c1747114ccef6d8688a6c4"
dependencies:
concat-stream "1.5.0"
debug "0.7.4"
mkdirp "0.5.0"
yauzl "2.4.1"
extsprintf@1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.0.2.tgz#e1080e0658e300b06294990cc70e1502235fd550"
fd-slicer@~1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/fd-slicer/-/fd-slicer-1.0.1.tgz#8b5bcbd9ec327c5041bf9ab023fd6750f1177e65"
dependencies:
pend "~1.2.0"
forever-agent@~0.6.1:
version "0.6.1"
resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91"
form-data@~2.1.1:
version "2.1.4"
resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.1.4.tgz#33c183acf193276ecaa98143a69e94bfee1750d1"
dependencies:
asynckit "^0.4.0"
combined-stream "^1.0.5"
mime-types "^2.1.12"
fs-extra@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-1.0.0.tgz#cd3ce5f7e7cb6145883fcae3191e9877f8587950"
dependencies:
graceful-fs "^4.1.2"
jsonfile "^2.1.0"
klaw "^1.0.0"
generate-function@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/generate-function/-/generate-function-2.0.0.tgz#6858fe7c0969b7d4e9093337647ac79f60dfbe74"
generate-object-property@^1.1.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/generate-object-property/-/generate-object-property-1.2.0.tgz#9c0e1c40308ce804f4783618b937fa88f99d50d0"
dependencies:
is-property "^1.0.0"
getpass@^0.1.1:
version "0.1.7"
resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa"
dependencies:
assert-plus "^1.0.0"
graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9:
version "4.1.11"
resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.1.11.tgz#0e8bdfe4d1ddb8854d64e04ea7c00e2a026e5658"
har-validator@~2.0.6:
version "2.0.6"
resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-2.0.6.tgz#cdcbc08188265ad119b6a5a7c8ab70eecfb5d27d"
dependencies:
chalk "^1.1.1"
commander "^2.9.0"
is-my-json-valid "^2.12.4"
pinkie-promise "^2.0.0"
has-ansi@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91"
dependencies:
ansi-regex "^2.0.0"
hasha@~2.2.0:
version "2.2.0"
resolved "https://registry.yarnpkg.com/hasha/-/hasha-2.2.0.tgz#78d7cbfc1e6d66303fe79837365984517b2f6ee1"
dependencies:
is-stream "^1.0.1"
pinkie-promise "^2.0.0"
hawk@~3.1.3:
version "3.1.3"
resolved "https://registry.yarnpkg.com/hawk/-/hawk-3.1.3.tgz#078444bd7c1640b0fe540d2c9b73d59678e8e1c4"
dependencies:
boom "2.x.x"
cryptiles "2.x.x"
hoek "2.x.x"
sntp "1.x.x"
hoek@2.x.x:
version "2.16.3"
resolved "https://registry.yarnpkg.com/hoek/-/hoek-2.16.3.tgz#20bb7403d3cea398e91dc4710a8ff1b8274a25ed"
http-signature@~1.1.0:
version "1.1.1"
resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.1.1.tgz#df72e267066cd0ac67fb76adf8e134a8fbcf91bf"
dependencies:
assert-plus "^0.2.0"
jsprim "^1.2.2"
sshpk "^1.7.0"
inherits@~2.0.1:
version "2.0.3"
resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.3.tgz#633c2c83e3da42a502f52466022480f4208261de"
is-my-json-valid@^2.12.4:
version "2.16.0"
resolved "https://registry.yarnpkg.com/is-my-json-valid/-/is-my-json-valid-2.16.0.tgz#f079dd9bfdae65ee2038aae8acbc86ab109e3693"
dependencies:
generate-function "^2.0.0"
generate-object-property "^1.1.0"
jsonpointer "^4.0.0"
xtend "^4.0.0"
is-property@^1.0.0:
version "1.0.2"
resolved "https://registry.yarnpkg.com/is-property/-/is-property-1.0.2.tgz#57fe1c4e48474edd65b09911f26b1cd4095dda84"
is-stream@^1.0.1:
version "1.1.0"
resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-1.1.0.tgz#12d4a3dd4e68e0b79ceb8dbc84173ae80d91ca44"
is-typedarray@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a"
isarray@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11"
isexe@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10"
isstream@~0.1.2:
version "0.1.2"
resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a"
jsbn@~0.1.0:
version "0.1.1"
resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513"
json-schema@0.2.3:
version "0.2.3"
resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13"
json-stringify-safe@~5.0.1:
version "5.0.1"
resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb"
jsonfile@^2.1.0:
version "2.4.0"
resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-2.4.0.tgz#3736a2b428b87bbda0cc83b53fa3d633a35c2ae8"
optionalDependencies:
graceful-fs "^4.1.6"
jsonpointer@^4.0.0:
version "4.0.1"
resolved "https://registry.yarnpkg.com/jsonpointer/-/jsonpointer-4.0.1.tgz#4fd92cb34e0e9db3c89c8622ecf51f9b978c6cb9"
jsprim@^1.2.2:
version "1.4.0"
resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.0.tgz#a3b87e40298d8c380552d8cc7628a0bb95a22918"
dependencies:
assert-plus "1.0.0"
extsprintf "1.0.2"
json-schema "0.2.3"
verror "1.3.6"
kew@~0.7.0:
version "0.7.0"
resolved "https://registry.yarnpkg.com/kew/-/kew-0.7.0.tgz#79d93d2d33363d6fdd2970b335d9141ad591d79b"
klaw@^1.0.0:
version "1.3.1"
resolved "https://registry.yarnpkg.com/klaw/-/klaw-1.3.1.tgz#4088433b46b3b1ba259d78785d8e96f73ba02439"
optionalDependencies:
graceful-fs "^4.1.9"
mime-db@~1.27.0:
version "1.27.0"
resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.27.0.tgz#820f572296bbd20ec25ed55e5b5de869e5436eb1"
mime-types@^2.1.12, mime-types@~2.1.7:
version "2.1.15"
resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.15.tgz#a4ebf5064094569237b8cf70046776d09fc92aed"
dependencies:
mime-db "~1.27.0"
minimist@0.0.8:
version "0.0.8"
resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d"
mkdirp@0.5.0:
version "0.5.0"
resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.0.tgz#1d73076a6df986cd9344e15e71fcc05a4c9abf12"
dependencies:
minimist "0.0.8"
oauth-sign@~0.8.1:
version "0.8.2"
resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.8.2.tgz#46a6ab7f0aead8deae9ec0565780b7d4efeb9d43"
pend@~1.2.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/pend/-/pend-1.2.0.tgz#7a57eb550a6783f9115331fcf4663d5c8e007a50"
phantomjs-prebuilt@*:
version "2.1.14"
resolved "https://registry.yarnpkg.com/phantomjs-prebuilt/-/phantomjs-prebuilt-2.1.14.tgz#d53d311fcfb7d1d08ddb24014558f1188c516da0"
dependencies:
es6-promise "~4.0.3"
extract-zip "~1.5.0"
fs-extra "~1.0.0"
hasha "~2.2.0"
kew "~0.7.0"
progress "~1.1.8"
request "~2.79.0"
request-progress "~2.0.1"
which "~1.2.10"
pinkie-promise@^2.0.0:
version "2.0.1"
resolved "https://registry.yarnpkg.com/pinkie-promise/-/pinkie-promise-2.0.1.tgz#2135d6dfa7a358c069ac9b178776288228450ffa"
dependencies:
pinkie "^2.0.0"
pinkie@^2.0.0:
version "2.0.4"
resolved "https://registry.yarnpkg.com/pinkie/-/pinkie-2.0.4.tgz#72556b80cfa0d48a974e80e77248e80ed4f7f870"
process-nextick-args@~1.0.6:
version "1.0.7"
resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3"
progress@~1.1.8:
version "1.1.8"
resolved "https://registry.yarnpkg.com/progress/-/progress-1.1.8.tgz#e260c78f6161cdd9b0e56cc3e0a85de17c7a57be"
punycode@^1.4.1:
version "1.4.1"
resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e"
qs@~6.3.0:
version "6.3.2"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.3.2.tgz#e75bd5f6e268122a2a0e0bda630b2550c166502c"
readable-stream@~2.0.0:
version "2.0.6"
resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.0.6.tgz#8f90341e68a53ccc928788dacfcd11b36eb9b78e"
dependencies:
core-util-is "~1.0.0"
inherits "~2.0.1"
isarray "~1.0.0"
process-nextick-args "~1.0.6"
string_decoder "~0.10.x"
util-deprecate "~1.0.1"
request-progress@~2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/request-progress/-/request-progress-2.0.1.tgz#5d36bb57961c673aa5b788dbc8141fdf23b44e08"
dependencies:
throttleit "^1.0.0"
request@~2.79.0:
version "2.79.0"
resolved "https://registry.yarnpkg.com/request/-/request-2.79.0.tgz#4dfe5bf6be8b8cdc37fcf93e04b65577722710de"
dependencies:
aws-sign2 "~0.6.0"
aws4 "^1.2.1"
caseless "~0.11.0"
combined-stream "~1.0.5"
extend "~3.0.0"
forever-agent "~0.6.1"
form-data "~2.1.1"
har-validator "~2.0.6"
hawk "~3.1.3"
http-signature "~1.1.0"
is-typedarray "~1.0.0"
isstream "~0.1.2"
json-stringify-safe "~5.0.1"
mime-types "~2.1.7"
oauth-sign "~0.8.1"
qs "~6.3.0"
stringstream "~0.0.4"
tough-cookie "~2.3.0"
tunnel-agent "~0.4.1"
uuid "^3.0.0"
sntp@1.x.x:
version "1.0.9"
resolved "https://registry.yarnpkg.com/sntp/-/sntp-1.0.9.tgz#6541184cc90aeea6c6e7b35e2659082443c66198"
dependencies:
hoek "2.x.x"
sshpk@^1.7.0:
version "1.13.1"
resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.13.1.tgz#512df6da6287144316dc4c18fe1cf1d940739be3"
dependencies:
asn1 "~0.2.3"
assert-plus "^1.0.0"
dashdash "^1.12.0"
getpass "^0.1.1"
optionalDependencies:
bcrypt-pbkdf "^1.0.0"
ecc-jsbn "~0.1.1"
jsbn "~0.1.0"
tweetnacl "~0.14.0"
string_decoder@~0.10.x:
version "0.10.31"
resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-0.10.31.tgz#62e203bc41766c6c28c9fc84301dab1c5310fa94"
stringstream@~0.0.4:
version "0.0.5"
resolved "https://registry.yarnpkg.com/stringstream/-/stringstream-0.0.5.tgz#4e484cd4de5a0bbbee18e46307710a8a81621878"
strip-ansi@^3.0.0:
version "3.0.1"
resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-3.0.1.tgz#6a385fb8853d952d5ff05d0e8aaf94278dc63dcf"
dependencies:
ansi-regex "^2.0.0"
supports-color@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7"
throttleit@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/throttleit/-/throttleit-1.0.0.tgz#9e785836daf46743145a5984b6268d828528ac6c"
tough-cookie@~2.3.0:
version "2.3.2"
resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.3.2.tgz#f081f76e4c85720e6c37a5faced737150d84072a"
dependencies:
punycode "^1.4.1"
tunnel-agent@~0.4.1:
version "0.4.3"
resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.4.3.tgz#6373db76909fe570e08d73583365ed828a74eeeb"
tweetnacl@^0.14.3, tweetnacl@~0.14.0:
version "0.14.5"
resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64"
typedarray@~0.0.5:
version "0.0.6"
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
util-deprecate@~1.0.1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf"
uuid@^3.0.0:
version "3.1.0"
resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04"
verror@1.3.6:
version "1.3.6"
resolved "https://registry.yarnpkg.com/verror/-/verror-1.3.6.tgz#cff5df12946d297d2baaefaa2689e25be01c005c"
dependencies:
extsprintf "1.0.2"
which@~1.2.10:
version "1.2.14"
resolved "https://registry.yarnpkg.com/which/-/which-1.2.14.tgz#9a87c4378f03e827cecaf1acdf56c736c01c14e5"
dependencies:
isexe "^2.0.0"
xtend@^4.0.0:
version "4.0.1"
resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.1.tgz#a5c6d532be656e23db820efb943a1f04998d63af"
yauzl@2.4.1:
version "2.4.1"
resolved "https://registry.yarnpkg.com/yauzl/-/yauzl-2.4.1.tgz#9528f442dab1b2284e58b4379bb194e22e0c4005"
dependencies:
fd-slicer "~1.0.1"

@ -4,7 +4,7 @@
"author": "Elbert Alias",
"homepage_url": "https://wappalyzer.com/",
"description": "Identify web technologies",
"version": "4.1.5",
"version": "5.0.0",
"default_locale": "en",
"manifest_version": 2,
"icons": {

@ -4,7 +4,7 @@
"author": "Elbert Alias",
"homepage_url": "https://wappalyzer.com/",
"description": "Identify web technologies",
"version": "4.1.5",
"version": "5.0.0",
"default_locale": "en",
"manifest_version": 2,
"icons": {

@ -130,7 +130,7 @@ wappalyzer.robotsTxtAllows = url => {
* Parse a URL
*/
wappalyzer.parseUrl = url => {
var a = document.createElement('a');
var a = wappalyzer.driver.document.createElement('a');
a.href = url;
@ -303,6 +303,10 @@ function cacheDetectedApps(apps, url) {
* Track detected applications
*/
function trackDetectedApps(apps, url, hostname, html) {
if ( !( wappalyzer.driver.ping instanceof Function ) ) {
return;
}
Object.keys(apps).forEach(appName => {
var app = apps[appName];
@ -544,6 +548,6 @@ class Application {
}
}
if ( typeof exports === 'object' ) {
exports.wappalyzer = wappalyzer;
if ( typeof module === 'object' ) {
module.exports = wappalyzer;
}