Browse Source

Reorder Expect mixin's send_expect parameters

William Vu 1 month ago
parent
commit
4cd52c5f32

+ 2
- 2
lib/msf/core/exploit/expect.rb View File

@@ -13,10 +13,10 @@ module Msf::Exploit::Expect
13 13
   # @param line [String] Line to send
14 14
   # @param pattern [Regexp] Pattern to expect
15 15
   # @param sock [Socket] Socket to send/expect on
16
-  # @param timeout [Float] Seconds to expect pattern
17 16
   # @param newline [String] Newline character(s)
17
+  # @param timeout [Float] Seconds to expect pattern
18 18
   # @return [void]
19
-  def send_expect(line, pattern, sock:, timeout: 3.5, newline: "\n")
19
+  def send_expect(line, pattern, sock:, newline: "\n", timeout: 3.5)
20 20
     unless sock.respond_to?(:put) && sock.respond_to?(:expect)
21 21
       raise ArgumentError, 'sock does not appear to be a socket'
22 22
     end

+ 2
- 2
modules/exploits/unix/smtp/opensmtpd_mail_from_rce.rb View File

@@ -113,8 +113,8 @@ class MetasploitModule < Msf::Exploit::Remote
113 113
         line,
114 114
         pattern,
115 115
         sock:    sock,
116
-        timeout: datastore['ExpectTimeout'],
117
-        newline: "\r\n"
116
+        newline: "\r\n",
117
+        timeout: datastore['ExpectTimeout']
118 118
       )
119 119
     end
120 120
   rescue Rex::ConnectionError => e

Loading…
Cancel
Save