We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a8e3ee0 commit ad8bbf4Copy full SHA for ad8bbf4
lib/msf/ui/console/command_dispatcher/core.rb
@@ -1705,12 +1705,14 @@ def cmd_sessions(*args)
1705
'Channelized' => true,
1706
'Hidden' => true
1707
})
1708
+ if process && process.channel
1709
+ data = process.channel.read
1710
+ print_line(data) if data
1711
+ end
1712
rescue ::Rex::Post::Meterpreter::RequestError
1713
print_error("Failed: #{$!.class} #{$!}")
- end
- if process && process.channel
- data = process.channel.read
- print_line(data) if data
1714
+ rescue Rex::TimeoutError
1715
+ print_error("Operation timed out")
1716
end
1717
elsif session.type == 'shell'
1718
output = session.shell_command(cmd)
0 commit comments