Skip to content
Snippets Groups Projects
Verified Commit cbbde6a1 authored by Thomas Rientjes's avatar Thomas Rientjes
Browse files

Improve candidate validation logic

parent 444aedaa
No related branches found
No related tags found
No related merge requests found
......@@ -73,6 +73,12 @@ exports.isValidCandidate = function (httpChannel) {
var initiatorDomain;
// See if the request uses a supported URI scheme.
if (!httpChannel.URI.schemeIs('http') &&
!httpChannel.URI.schemeIs('https')) {
return false;
}
// See if the request is targeted at a Content Delivery Network.
if (mappings[httpChannel.URI.host] === undefined) {
return false;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment