@duckduckgo/privacy-grade
Advanced tools
Comparing version 1.0.3 to 1.1.0
{ | ||
"name": "@duckduckgo/privacy-grade", | ||
"version": "1.0.3", | ||
"version": "1.1.0", | ||
"description": "DuckDuckGo's privacy grade algorithm", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -91,6 +91,5 @@ (function () { | ||
} | ||
const cnameResolution = this.resolveCname(urlToCheck) | ||
const fromCname = cnameResolution.fromCname | ||
urlToCheck = cnameResolution.finalURL | ||
let fromCname | ||
// single object with all of our requeest and site data split and | ||
@@ -111,6 +110,18 @@ // processed into the correct format for the tracker set/get functions. | ||
// finds a tracker definition by iterating over the whole trackerList and finding the matching tracker. | ||
const tracker = this.findTracker(requestData) | ||
let tracker = this.findTracker(requestData) | ||
if (!tracker) { | ||
return null | ||
// if request doesn't have any rules associated with it, we should check if it's a CNAMEed tracker | ||
const cnameResolution = this.resolveCname(urlToCheck) | ||
fromCname = cnameResolution.fromCname | ||
urlToCheck = cnameResolution.finalURL | ||
requestData.urlToCheck = urlToCheck | ||
requestData.urlToCheckDomain = this.tldjs.parse(urlToCheck).domain | ||
requestData.urlToCheckSplit = this.utils.extractHostFromURL(urlToCheck).split('.') | ||
tracker = this.findTracker(requestData) | ||
if (!tracker) { | ||
return null | ||
} | ||
} | ||
@@ -117,0 +128,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
393536
9173
3