Skip to content

Commit 98156ec

Browse files
committed
Add user agent to the transport config
Why this was missing I will never know :)
1 parent 5a24dc8 commit 98156ec

File tree

3 files changed

+10
-8
lines changed

3 files changed

+10
-8
lines changed

lib/msf/core/payload/transport_config.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ def transport_config_reverse_http(opts={})
6060
:comm_timeout => datastore['SessionCommunicationTimeout'].to_i,
6161
:retry_total => datastore['SessionRetryTotal'].to_i,
6262
:retry_wait => datastore['SessionRetryWait'].to_i,
63+
:ua => datastore['MeterpreterUserAgent'],
6364
:proxy_host => datastore['PayloadProxyHost'],
6465
:proxy_port => datastore['PayloadProxyPort'],
6566
:proxy_type => datastore['PayloadProxyType'],

lib/msf/core/payload/windows/reverse_http.rb

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -52,14 +52,14 @@ def generate(opts={})
5252

5353
# Add extra options if we have enough space
5454
unless self.available_space.nil? || required_space > self.available_space
55-
conf[:url] = generate_uri
56-
conf[:exitfunk] = datastore['EXITFUNC']
57-
conf[:proxy_host] = datastore['PayloadProxyHost']
58-
conf[:proxy_port] = datastore['PayloadProxyPort']
59-
conf[:proxy_user] = datastore['PayloadProxyUser']
60-
conf[:proxy_pass] = datastore['PayloadProxyPass']
61-
conf[:proxy_type] = datastore['PayloadProxyType']
62-
conf[:retry_count] = datastore['StagerRetryCount']
55+
conf[:url] = generate_uri
56+
conf[:exitfunk] = datastore['EXITFUNC']
57+
conf[:ua] = datastore['MeterpreterUserAgent']
58+
conf[:proxy_host] = datastore['PayloadProxyHost']
59+
conf[:proxy_port] = datastore['PayloadProxyPort']
60+
conf[:proxy_user] = datastore['PayloadProxyUser']
61+
conf[:proxy_pass] = datastore['PayloadProxyPass']
62+
conf[:proxy_type] = datastore['PayloadProxyType']
6363
end
6464

6565
generate_reverse_http(conf)

lib/msf/core/payload/windows/x64/reverse_http.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ def generate(opts={})
5858
unless self.available_space.nil? || required_space > self.available_space
5959
conf[:url] = generate_uri
6060
conf[:exitfunk] = datastore['EXITFUNC']
61+
conf[:ua] = datastore['MeterpreterUserAgent']
6162
conf[:proxy_host] = datastore['PayloadProxyHost']
6263
conf[:proxy_port] = datastore['PayloadProxyPort']
6364
conf[:proxy_user] = datastore['PayloadProxyUser']

0 commit comments

Comments
 (0)