Fixes #526. Correct socket name and call to super in the socket output io
git-svn-id: file:///home/svn/framework3/trunk@7548 4d416f70-5f16-0410-b530-b9f4589650daunstable
parent
9b1935eb2a
commit
a92fbb1ff4
|
@ -13,6 +13,7 @@ class Output::Socket < Rex::Ui::Text::Output
|
|||
|
||||
def initialize(sock)
|
||||
@sock = sock
|
||||
super()
|
||||
end
|
||||
|
||||
def supports_color?
|
||||
|
@ -20,7 +21,7 @@ class Output::Socket < Rex::Ui::Text::Output
|
|||
when true
|
||||
# Allow color if the user forces it on
|
||||
return true
|
||||
else
|
||||
else
|
||||
false
|
||||
end
|
||||
end
|
||||
|
@ -39,3 +40,4 @@ end
|
|||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -110,7 +110,7 @@ class Plugin::Msfd < Msf::Plugin
|
|||
client.close
|
||||
next
|
||||
end
|
||||
msg = "Msfd: New connection from #{cli.peerhost}"
|
||||
msg = "Msfd: New connection from #{client.peerhost}"
|
||||
ilog(msg, 'core')
|
||||
print_status(msg)
|
||||
|
||||
|
@ -121,7 +121,7 @@ class Plugin::Msfd < Msf::Plugin
|
|||
Msf::Ui::Console::Driver::DefaultPrompt,
|
||||
Msf::Ui::Console::Driver::DefaultPromptChar,
|
||||
'Framework' => framework,
|
||||
'LocalInput' => Rex::Ui::Text::Input::Socket.new(cli),
|
||||
'LocalInput' => Rex::Ui::Text::Input::Socket.new(cli),
|
||||
'LocalOutput' => Rex::Ui::Text::Output::Socket.new(cli),
|
||||
'AllowCommandPassthru' => false).run
|
||||
rescue
|
||||
|
@ -130,7 +130,7 @@ class Plugin::Msfd < Msf::Plugin
|
|||
msg = "Msfd: Closing client connection with #{cli.peerhost}"
|
||||
ilog(msg, 'core')
|
||||
print_status(msg)
|
||||
begin
|
||||
begin
|
||||
cli.shutdown
|
||||
cli.close
|
||||
rescue IOError
|
||||
|
@ -158,3 +158,4 @@ protected
|
|||
end
|
||||
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue