|
|
@ -291,12 +291,12 @@ class Wappalyzer {
|
|
|
|
let userAgent;
|
|
|
|
let userAgent;
|
|
|
|
|
|
|
|
|
|
|
|
robotsTxt.split('\n').forEach((line) => {
|
|
|
|
robotsTxt.split('\n').forEach((line) => {
|
|
|
|
let matches = /^User-agent:\s*(.+)$/i.exec(line);
|
|
|
|
let matches = /^User-agent:\s*(.+)$/i.exec(line.trim());
|
|
|
|
|
|
|
|
|
|
|
|
if (matches) {
|
|
|
|
if (matches) {
|
|
|
|
userAgent = matches[1].toLowerCase();
|
|
|
|
userAgent = matches[1].toLowerCase();
|
|
|
|
} else if (userAgent === '*' || userAgent === 'wappalyzer') {
|
|
|
|
} else if (userAgent === '*' || userAgent === 'wappalyzer') {
|
|
|
|
matches = /^Disallow:\s*(.+)$/i.exec(line);
|
|
|
|
matches = /^Disallow:\s*(.+)$/i.exec(line.trim());
|
|
|
|
|
|
|
|
|
|
|
|
if (matches) {
|
|
|
|
if (matches) {
|
|
|
|
disallow.push(matches[1]);
|
|
|
|
disallow.push(matches[1]);
|
|
|
@ -394,12 +394,7 @@ class Wappalyzer {
|
|
|
|
resolveImplies(apps, url) {
|
|
|
|
resolveImplies(apps, url) {
|
|
|
|
let checkImplies = true;
|
|
|
|
let checkImplies = true;
|
|
|
|
|
|
|
|
|
|
|
|
// Implied applications
|
|
|
|
const resolve = (appName) => {
|
|
|
|
// Run several passes as implied apps may imply other apps
|
|
|
|
|
|
|
|
while (checkImplies) {
|
|
|
|
|
|
|
|
checkImplies = false;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Object.keys(apps).forEach((appName) => {
|
|
|
|
|
|
|
|
const app = apps[appName];
|
|
|
|
const app = apps[appName];
|
|
|
|
|
|
|
|
|
|
|
|
if (app && app.props.implies) {
|
|
|
|
if (app && app.props.implies) {
|
|
|
@ -426,7 +421,14 @@ class Wappalyzer {
|
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Implied applications
|
|
|
|
|
|
|
|
// Run several passes as implied apps may imply other apps
|
|
|
|
|
|
|
|
while (checkImplies) {
|
|
|
|
|
|
|
|
checkImplies = false;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Object.keys(apps).forEach(resolve);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|