Skip to content

Commit 8b488c3

Browse files
author
lsanchez-r7
committed
Merge pull request rapid7#1866 from dmaloney-r7/bug/mdm_session_port
Add session_port to the mdm object SEERM rapid7#7281
2 parents 07c99f8 + 849d974 commit 8b488c3

File tree

1 file changed

+12
-11
lines changed

1 file changed

+12
-11
lines changed

lib/msf/core/db.rb

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -736,17 +736,18 @@ def report_session(opts)
736736
h_opts[:workspace] = wspace
737737
host = find_or_create_host(h_opts)
738738
sess_data = {
739-
:host_id => host.id,
740-
:stype => session.type,
741-
:desc => session.info,
742-
:platform => session.platform,
743-
:via_payload => session.via_payload,
744-
:via_exploit => session.via_exploit,
745-
:routes => [],
746-
:datastore => session.exploit_datastore.to_h,
747-
:opened_at => Time.now.utc,
748-
:last_seen => Time.now.utc,
749-
:local_id => session.sid
739+
:host_id => host.id,
740+
:stype => session.type,
741+
:desc => session.info,
742+
:platform => session.platform,
743+
:via_payload => session.via_payload,
744+
:via_exploit => session.via_exploit,
745+
:routes => [],
746+
:datastore => session.exploit_datastore.to_h,
747+
:port => session.session_port,
748+
:opened_at => Time.now.utc,
749+
:last_seen => Time.now.utc,
750+
:local_id => session.sid
750751
}
751752
elsif opts[:host]
752753
raise ArgumentError.new("Invalid :host, expected Host object") unless opts[:host].kind_of? ::Mdm::Host

0 commit comments

Comments
 (0)