Check regexp validity, improved several patterns

main
Elbert Alias 12 years ago
parent 3b2ef5b673
commit 2431a13f56

Binary file not shown.

After

Width:  |  Height:  |  Size: 809 B

@ -89,7 +89,13 @@ var wappalyzer = (function() {
attrs[attr[0]] = attr[1]; attrs[attr[0]] = attr[1];
} }
} else { } else {
try {
attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression
} catch (e) {
attrs.regex = new RegExp();
w.log(e + ': ' + attr, 'warn');
}
} }
}); });

@ -680,6 +680,10 @@
"cats": [ 5 ], "cats": [ 5 ],
"script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3" "script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3"
}, },
"Google PageSpeed": {
"cats": [ 23, 33 ],
"headers": { "X-Mod-Pagespeed": ".*" }
},
"Google Sites": { "Google Sites": {
"cats": [ 1 ], "cats": [ 1 ],
"url": "sites.google.com" "url": "sites.google.com"
@ -1159,7 +1163,7 @@
"New Relic": { "New Relic": {
"cats": [ 10 ], "cats": [ 10 ],
"html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)", "html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)",
"env": "^NREUMQ$" "env": "^NREUM"
}, },
"Nginx": { "Nginx": {
"cats": [ 22 ], "cats": [ 22 ],
@ -1433,7 +1437,7 @@
"reCAPTCHA": { "reCAPTCHA": {
"cats": [ 16 ], "cats": [ 16 ],
"script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)", "script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)",
"html": "<div[^>]+id=\\\"recaptcha_image", "html": "(<div[^>]+id=\\\"recaptcha_image|<link[^>]+recaptcha|document\\.getElementById\\('recaptcha)",
"env": "^Recaptcha$" "env": "^Recaptcha$"
}, },
"Red Hat": { "Red Hat": {
@ -1606,7 +1610,9 @@
}, },
"Squarespace": { "Squarespace": {
"cats": [ 1 ], "cats": [ 1 ],
"html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID" "html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID",
"headers": { "X-ServedBy": "squarespace" },
"env": "^Squarespace"
}, },
"Squiz Matrix": { "Squiz Matrix": {
"cats": [ 1 ], "cats": [ 1 ],
@ -1705,7 +1711,7 @@
}, },
"Twitter Bootstrap": { "Twitter Bootstrap": {
"cats": [ 18 ], "cats": [ 18 ],
"script": "twitter\\.github\\.com/bootstrap", "script": "(twitter\\.github\\.com/bootstrap|bootstrap(\\.js|\\.min\\.js))",
"html": "<link[^>]+bootstrap[^>]+css", "html": "<link[^>]+bootstrap[^>]+css",
"env": "^Twipsy$\\;confidence:50" "env": "^Twipsy$\\;confidence:50"
}, },

@ -680,6 +680,10 @@
"cats": [ 5 ], "cats": [ 5 ],
"script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3" "script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3"
}, },
"Google PageSpeed": {
"cats": [ 23, 33 ],
"headers": { "X-Mod-Pagespeed": ".*" }
},
"Google Sites": { "Google Sites": {
"cats": [ 1 ], "cats": [ 1 ],
"url": "sites.google.com" "url": "sites.google.com"
@ -1159,7 +1163,7 @@
"New Relic": { "New Relic": {
"cats": [ 10 ], "cats": [ 10 ],
"html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)", "html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)",
"env": "^NREUMQ$" "env": "^NREUM"
}, },
"Nginx": { "Nginx": {
"cats": [ 22 ], "cats": [ 22 ],
@ -1433,7 +1437,7 @@
"reCAPTCHA": { "reCAPTCHA": {
"cats": [ 16 ], "cats": [ 16 ],
"script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)", "script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)",
"html": "<div[^>]+id=\\\"recaptcha_image", "html": "(<div[^>]+id=\\\"recaptcha_image|<link[^>]+recaptcha|document\\.getElementById\\('recaptcha)",
"env": "^Recaptcha$" "env": "^Recaptcha$"
}, },
"Red Hat": { "Red Hat": {
@ -1606,7 +1610,9 @@
}, },
"Squarespace": { "Squarespace": {
"cats": [ 1 ], "cats": [ 1 ],
"html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID" "html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID",
"headers": { "X-ServedBy": "squarespace" },
"env": "^Squarespace"
}, },
"Squiz Matrix": { "Squiz Matrix": {
"cats": [ 1 ], "cats": [ 1 ],
@ -1705,7 +1711,7 @@
}, },
"Twitter Bootstrap": { "Twitter Bootstrap": {
"cats": [ 18 ], "cats": [ 18 ],
"script": "twitter\\.github\\.com/bootstrap", "script": "(twitter\\.github\\.com/bootstrap|bootstrap(\\.js|\\.min\\.js))",
"html": "<link[^>]+bootstrap[^>]+css", "html": "<link[^>]+bootstrap[^>]+css",
"env": "^Twipsy$\\;confidence:50" "env": "^Twipsy$\\;confidence:50"
}, },

Binary file not shown.

After

Width:  |  Height:  |  Size: 809 B

@ -89,7 +89,13 @@ var wappalyzer = (function() {
attrs[attr[0]] = attr[1]; attrs[attr[0]] = attr[1];
} }
} else { } else {
try {
attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression
} catch (e) {
attrs.regex = new RegExp();
w.log(e + ': ' + attr, 'warn');
}
} }
}); });

@ -680,6 +680,10 @@
"cats": [ 5 ], "cats": [ 5 ],
"script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3" "script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3"
}, },
"Google PageSpeed": {
"cats": [ 23, 33 ],
"headers": { "X-Mod-Pagespeed": ".*" }
},
"Google Sites": { "Google Sites": {
"cats": [ 1 ], "cats": [ 1 ],
"url": "sites.google.com" "url": "sites.google.com"
@ -1159,7 +1163,7 @@
"New Relic": { "New Relic": {
"cats": [ 10 ], "cats": [ 10 ],
"html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)", "html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)",
"env": "^NREUMQ$" "env": "^NREUM"
}, },
"Nginx": { "Nginx": {
"cats": [ 22 ], "cats": [ 22 ],
@ -1433,7 +1437,7 @@
"reCAPTCHA": { "reCAPTCHA": {
"cats": [ 16 ], "cats": [ 16 ],
"script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)", "script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)",
"html": "<div[^>]+id=\\\"recaptcha_image", "html": "(<div[^>]+id=\\\"recaptcha_image|<link[^>]+recaptcha|document\\.getElementById\\('recaptcha)",
"env": "^Recaptcha$" "env": "^Recaptcha$"
}, },
"Red Hat": { "Red Hat": {
@ -1606,7 +1610,9 @@
}, },
"Squarespace": { "Squarespace": {
"cats": [ 1 ], "cats": [ 1 ],
"html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID" "html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID",
"headers": { "X-ServedBy": "squarespace" },
"env": "^Squarespace"
}, },
"Squiz Matrix": { "Squiz Matrix": {
"cats": [ 1 ], "cats": [ 1 ],
@ -1705,7 +1711,7 @@
}, },
"Twitter Bootstrap": { "Twitter Bootstrap": {
"cats": [ 18 ], "cats": [ 18 ],
"script": "twitter\\.github\\.com/bootstrap", "script": "(twitter\\.github\\.com/bootstrap|bootstrap(\\.js|\\.min\\.js))",
"html": "<link[^>]+bootstrap[^>]+css", "html": "<link[^>]+bootstrap[^>]+css",
"env": "^Twipsy$\\;confidence:50" "env": "^Twipsy$\\;confidence:50"
}, },

Binary file not shown.

After

Width:  |  Height:  |  Size: 809 B

@ -89,7 +89,13 @@ var wappalyzer = (function() {
attrs[attr[0]] = attr[1]; attrs[attr[0]] = attr[1];
} }
} else { } else {
try {
attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression
} catch (e) {
attrs.regex = new RegExp();
w.log(e + ': ' + attr, 'warn');
}
} }
}); });

@ -680,6 +680,10 @@
"cats": [ 5 ], "cats": [ 5 ],
"script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3" "script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3"
}, },
"Google PageSpeed": {
"cats": [ 23, 33 ],
"headers": { "X-Mod-Pagespeed": ".*" }
},
"Google Sites": { "Google Sites": {
"cats": [ 1 ], "cats": [ 1 ],
"url": "sites.google.com" "url": "sites.google.com"
@ -1159,7 +1163,7 @@
"New Relic": { "New Relic": {
"cats": [ 10 ], "cats": [ 10 ],
"html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)", "html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)",
"env": "^NREUMQ$" "env": "^NREUM"
}, },
"Nginx": { "Nginx": {
"cats": [ 22 ], "cats": [ 22 ],
@ -1433,7 +1437,7 @@
"reCAPTCHA": { "reCAPTCHA": {
"cats": [ 16 ], "cats": [ 16 ],
"script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)", "script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)",
"html": "<div[^>]+id=\\\"recaptcha_image", "html": "(<div[^>]+id=\\\"recaptcha_image|<link[^>]+recaptcha|document\\.getElementById\\('recaptcha)",
"env": "^Recaptcha$" "env": "^Recaptcha$"
}, },
"Red Hat": { "Red Hat": {
@ -1606,7 +1610,9 @@
}, },
"Squarespace": { "Squarespace": {
"cats": [ 1 ], "cats": [ 1 ],
"html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID" "html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID",
"headers": { "X-ServedBy": "squarespace" },
"env": "^Squarespace"
}, },
"Squiz Matrix": { "Squiz Matrix": {
"cats": [ 1 ], "cats": [ 1 ],
@ -1705,7 +1711,7 @@
}, },
"Twitter Bootstrap": { "Twitter Bootstrap": {
"cats": [ 18 ], "cats": [ 18 ],
"script": "twitter\\.github\\.com/bootstrap", "script": "(twitter\\.github\\.com/bootstrap|bootstrap(\\.js|\\.min\\.js))",
"html": "<link[^>]+bootstrap[^>]+css", "html": "<link[^>]+bootstrap[^>]+css",
"env": "^Twipsy$\\;confidence:50" "env": "^Twipsy$\\;confidence:50"
}, },

@ -89,7 +89,13 @@ var wappalyzer = (function() {
attrs[attr[0]] = attr[1]; attrs[attr[0]] = attr[1];
} }
} else { } else {
try {
attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression
} catch (e) {
attrs.regex = new RegExp();
w.log(e + ': ' + attr, 'warn');
}
} }
}); });

Binary file not shown.

After

Width:  |  Height:  |  Size: 809 B

@ -680,6 +680,10 @@
"cats": [ 5 ], "cats": [ 5 ],
"script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3" "script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3"
}, },
"Google PageSpeed": {
"cats": [ 23, 33 ],
"headers": { "X-Mod-Pagespeed": ".*" }
},
"Google Sites": { "Google Sites": {
"cats": [ 1 ], "cats": [ 1 ],
"url": "sites.google.com" "url": "sites.google.com"
@ -1159,7 +1163,7 @@
"New Relic": { "New Relic": {
"cats": [ 10 ], "cats": [ 10 ],
"html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)", "html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)",
"env": "^NREUMQ$" "env": "^NREUM"
}, },
"Nginx": { "Nginx": {
"cats": [ 22 ], "cats": [ 22 ],
@ -1433,7 +1437,7 @@
"reCAPTCHA": { "reCAPTCHA": {
"cats": [ 16 ], "cats": [ 16 ],
"script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)", "script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)",
"html": "<div[^>]+id=\\\"recaptcha_image", "html": "(<div[^>]+id=\\\"recaptcha_image|<link[^>]+recaptcha|document\\.getElementById\\('recaptcha)",
"env": "^Recaptcha$" "env": "^Recaptcha$"
}, },
"Red Hat": { "Red Hat": {
@ -1606,7 +1610,9 @@
}, },
"Squarespace": { "Squarespace": {
"cats": [ 1 ], "cats": [ 1 ],
"html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID" "html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID",
"headers": { "X-ServedBy": "squarespace" },
"env": "^Squarespace"
}, },
"Squiz Matrix": { "Squiz Matrix": {
"cats": [ 1 ], "cats": [ 1 ],
@ -1705,7 +1711,7 @@
}, },
"Twitter Bootstrap": { "Twitter Bootstrap": {
"cats": [ 18 ], "cats": [ 18 ],
"script": "twitter\\.github\\.com/bootstrap", "script": "(twitter\\.github\\.com/bootstrap|bootstrap(\\.js|\\.min\\.js))",
"html": "<link[^>]+bootstrap[^>]+css", "html": "<link[^>]+bootstrap[^>]+css",
"env": "^Twipsy$\\;confidence:50" "env": "^Twipsy$\\;confidence:50"
}, },

Binary file not shown.

After

Width:  |  Height:  |  Size: 809 B

@ -89,7 +89,13 @@ var wappalyzer = (function() {
attrs[attr[0]] = attr[1]; attrs[attr[0]] = attr[1];
} }
} else { } else {
try {
attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression
} catch (e) {
attrs.regex = new RegExp();
w.log(e + ': ' + attr, 'warn');
}
} }
}); });

@ -680,6 +680,10 @@
"cats": [ 5 ], "cats": [ 5 ],
"script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3" "script": "(maps\\.google\\.com/maps\\?file=api(&v=([\\d\\.]+))?|maps\\.google\\.com/maps/api/staticmap)\\;version:API v\\3"
}, },
"Google PageSpeed": {
"cats": [ 23, 33 ],
"headers": { "X-Mod-Pagespeed": ".*" }
},
"Google Sites": { "Google Sites": {
"cats": [ 1 ], "cats": [ 1 ],
"url": "sites.google.com" "url": "sites.google.com"
@ -1159,7 +1163,7 @@
"New Relic": { "New Relic": {
"cats": [ 10 ], "cats": [ 10 ],
"html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)", "html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)",
"env": "^NREUMQ$" "env": "^NREUM"
}, },
"Nginx": { "Nginx": {
"cats": [ 22 ], "cats": [ 22 ],
@ -1433,7 +1437,7 @@
"reCAPTCHA": { "reCAPTCHA": {
"cats": [ 16 ], "cats": [ 16 ],
"script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)", "script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)",
"html": "<div[^>]+id=\\\"recaptcha_image", "html": "(<div[^>]+id=\\\"recaptcha_image|<link[^>]+recaptcha|document\\.getElementById\\('recaptcha)",
"env": "^Recaptcha$" "env": "^Recaptcha$"
}, },
"Red Hat": { "Red Hat": {
@ -1606,7 +1610,9 @@
}, },
"Squarespace": { "Squarespace": {
"cats": [ 1 ], "cats": [ 1 ],
"html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID" "html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID",
"headers": { "X-ServedBy": "squarespace" },
"env": "^Squarespace"
}, },
"Squiz Matrix": { "Squiz Matrix": {
"cats": [ 1 ], "cats": [ 1 ],
@ -1705,7 +1711,7 @@
}, },
"Twitter Bootstrap": { "Twitter Bootstrap": {
"cats": [ 18 ], "cats": [ 18 ],
"script": "twitter\\.github\\.com/bootstrap", "script": "(twitter\\.github\\.com/bootstrap|bootstrap(\\.js|\\.min\\.js))",
"html": "<link[^>]+bootstrap[^>]+css", "html": "<link[^>]+bootstrap[^>]+css",
"env": "^Twipsy$\\;confidence:50" "env": "^Twipsy$\\;confidence:50"
}, },

@ -89,7 +89,13 @@ var wappalyzer = (function() {
attrs[attr[0]] = attr[1]; attrs[attr[0]] = attr[1];
} }
} else { } else {
try {
attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression
} catch (e) {
attrs.regex = new RegExp();
w.log(e + ': ' + attr, 'warn');
}
} }
}); });

@ -1163,7 +1163,7 @@
"New Relic": { "New Relic": {
"cats": [ 10 ], "cats": [ 10 ],
"html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)", "html": "<script[^>]+>(var NREUMQ=NREUMQ|if \\(!NREUMQ\\.f)",
"env": "^NREUMQ$" "env": "^NREUM"
}, },
"Nginx": { "Nginx": {
"cats": [ 22 ], "cats": [ 22 ],
@ -1437,7 +1437,7 @@
"reCAPTCHA": { "reCAPTCHA": {
"cats": [ 16 ], "cats": [ 16 ],
"script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)", "script": "(api-secure\\.recaptcha\\.net|recaptcha_ajax\\.js)",
"html": "<div[^>]+id=\\\"recaptcha_image", "html": "(<div[^>]+id=\\\"recaptcha_image|<link[^>]+recaptcha|document\\.getElementById\\('recaptcha)",
"env": "^Recaptcha$" "env": "^Recaptcha$"
}, },
"Red Hat": { "Red Hat": {
@ -1610,7 +1610,9 @@
}, },
"Squarespace": { "Squarespace": {
"cats": [ 1 ], "cats": [ 1 ],
"html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID" "html": "Squarespace\\.Constants\\.CURRENT_MODULE_ID",
"headers": { "X-ServedBy": "squarespace" },
"env": "^Squarespace"
}, },
"Squiz Matrix": { "Squiz Matrix": {
"cats": [ 1 ], "cats": [ 1 ],
@ -1709,7 +1711,7 @@
}, },
"Twitter Bootstrap": { "Twitter Bootstrap": {
"cats": [ 18 ], "cats": [ 18 ],
"script": "(twitter\\.github\\.com/bootstrap|bootstrap(.js|.min.js))", "script": "(twitter\\.github\\.com/bootstrap|bootstrap(\\.js|\\.min\\.js))",
"html": "<link[^>]+bootstrap[^>]+css", "html": "<link[^>]+bootstrap[^>]+css",
"env": "^Twipsy$\\;confidence:50" "env": "^Twipsy$\\;confidence:50"
}, },

@ -89,7 +89,13 @@ var wappalyzer = (function() {
attrs[attr[0]] = attr[1]; attrs[attr[0]] = attr[1];
} }
} else { } else {
try {
attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression attrs.regex = new RegExp(attr.replace('/', '\\\/'), 'i'); // Escape slashes in regular expression
} catch (e) {
attrs.regex = new RegExp();
w.log(e + ': ' + attr, 'warn');
}
} }
}); });

Loading…
Cancel
Save