Skip to content

Commit fff51e2

Browse files
author
Tod Beardsley
committed
Land rapid7#1882, fix for CVE search from @jlee-r7
2 parents f76a50a + 12f0448 commit fff51e2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/msf/core/db_manager.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -666,11 +666,11 @@ def search_modules(search_string)
666666
formatted_values = value_set.collect { |value|
667667
prefix = keyword.upcase
668668

669-
"#{prefix}-#{value}"
669+
"#{prefix}-%#{value}%"
670670
}
671671

672672
query = query.includes(:refs)
673-
union_conditions << Mdm::Module::Ref.arel_table[:name].eq_any(formatted_values)
673+
union_conditions << Mdm::Module::Ref.arel_table[:name].matches_any(formatted_values)
674674
end
675675
end
676676

0 commit comments

Comments
 (0)