Mink
Mink copied to clipboard
Allow wildcard URIs for blacklist
Per @weiglemc's testing, allow the user to enter *.google.com to cause both www.google.com and drive.google.com from invoking the Mink code beyond the blacklist test.
Something like the following in setActiveBasedOnBlacklistedProperty() in content.js:
var blackListEntryAsRegExp = new RegExp(blacklistEntryHosthame.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&"));
var matchesWildcard = documentHostName.match(blackListEntryAsRegExp);
if(matchesWildcard) {
chrome.runtime.sendMessage({method: 'stopWatchingRequests_blacklisted'});
}