Land #10945, Ensure `sessions --up` shows only services which are up

GSoC/Meterpreter_Web_Console
Brent Cook 2018-11-10 10:12:44 -07:00
commit 7ee70f5655
No known key found for this signature in database
GPG Key ID: 1FFAA0B24B708F96
1 changed files with 4 additions and 0 deletions

View File

@ -765,6 +765,10 @@ class Db
opts[:port] = ports if ports opts[:port] = ports if ports
framework.db.services(opts).each do |service| framework.db.services(opts).each do |service|
unless service.state == 'open'
next if onlyup
end
host = service.host host = service.host
matched_service_ids << service.id matched_service_ids << service.id