From e0f885d50c1eca1582686afa046a6959f8ae3fc0 Mon Sep 17 00:00:00 2001 From: kris <> Date: Sun, 4 Oct 2009 20:20:43 +0000 Subject: [PATCH] Let db_autopwn -I/-X work with a single addr git-svn-id: file:///home/svn/framework3/trunk@7126 4d416f70-5f16-0410-b530-b9f4589650da --- lib/msf/ui/console/command_dispatcher/db.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/msf/ui/console/command_dispatcher/db.rb b/lib/msf/ui/console/command_dispatcher/db.rb index 70efff8185..6f4f136856 100644 --- a/lib/msf/ui/console/command_dispatcher/db.rb +++ b/lib/msf/ui/console/command_dispatcher/db.rb @@ -664,7 +664,9 @@ class Db sets.split(',').each do |set| rng = set.split('-').map{ |c| Rex::Socket::addr_atoi(c) } tst = Rex::Socket::addr_atoi(addr) - if (tst >= rng[0] and tst <= rng[1]) + if (not rng[1]) + return tst == rng[0] + elsif (tst >= rng[0] and tst <= rng[1]) return true end end