Skip to content

Commit c07ff70

Browse files
committed
Add check for UUID payloads
Thankfully those payloads already had a flag that could be reused.
1 parent 1c73c19 commit c07ff70

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

lib/msf/core/payload/stager.rb

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -156,11 +156,13 @@ def handle_connection(conn, opts={})
156156
# If the stage should be sent over the client connection that is
157157
# established (which is the default), then go ahead and transmit it.
158158
if (stage_over_connection?)
159-
uuid_raw = conn.get_once(16, 1)
160-
161159
opts = {}
162-
if uuid_raw
163-
opts[:uuid] = Msf::Payload::UUID.new({raw: uuid_raw})
160+
161+
if include_send_uuid
162+
uuid_raw = conn.get_once(16, 1)
163+
if uuid_raw
164+
opts[:uuid] = Msf::Payload::UUID.new({raw: uuid_raw})
165+
end
164166
end
165167

166168
p = generate_stage(opts)

0 commit comments

Comments
 (0)