Land #10781, Fix error in rpc_shell_read RPC method.

4.x
Brent Cook 2018-10-10 09:02:47 -05:00 committed by Metasploit
parent b13bc4b460
commit 285a183f27
No known key found for this signature in database
GPG Key ID: CDFB5FA52007B954
1 changed files with 2 additions and 2 deletions

View File

@ -90,8 +90,8 @@ class RPC_Session < RPC_Base
def rpc_shell_read( sid, ptr=nil) def rpc_shell_read( sid, ptr=nil)
s = _valid_session(sid,"shell") s = _valid_session(sid,"shell")
begin begin
res = s.shell_read(data) res = s.shell_read()
{ "write_count" => res.to_s} { "seq" => 0, "data" => res.to_s}
rescue ::Exception => e rescue ::Exception => e
error(500, "Session Disconnected: #{e.class} #{e}") error(500, "Session Disconnected: #{e.class} #{e}")
end end