Procházet zdrojové kódy

[Fix] Fix matching patterns with no paths

tags/1.7.6
Vsevolod Stakhov před 6 roky
rodič
revize
b2c78d1b07
1 změnil soubory, kde provedl 9 přidání a 2 odebrání
  1. 9
    2
      src/plugins/lua/phishing.lua

+ 9
- 2
src/plugins/lua/phishing.lua Zobrazit soubor

@@ -75,8 +75,12 @@ local function phishing_cb(task)
for _,d in ipairs(elt) do
if not d['path'] then
found_path = true
end

if query and d['query'] and query == d['query'] then
found_query = true
elseif not d['query'] then
found_query = true
break
end
end
end
@@ -101,7 +105,10 @@ local function phishing_cb(task)
task:insert_result(phish_symbol, 1.0, args)
else
-- Host + path match
task:insert_result(phish_symbol, 0.3, args)
if path then
task:insert_result(phish_symbol, 0.3, args)
end
-- No path, no symbol
end
else
if url:is_phished() then

Načítá se…
Zrušit
Uložit