Skip to content

Commit 671c7f1

Browse files
committed
Merge pull request #12 from wvu-r7/pr/3691
Fix read_ack to read only the ACK
2 parents 0e18d69 + b6e0459 commit 671c7f1

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

lib/msf/core/exploit/gdb.rb

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def send_ack
3939
# Reads an ACK packet from the wire
4040
# @raise [BadAckError] if a bad ACK is received
4141
def read_ack
42-
unless sock.get_once == '+'
42+
unless sock.get_once(1) == '+'
4343
raise BadAckError
4444
end
4545
vprint_status('Received ack...')
@@ -167,7 +167,6 @@ def enable_extended_mode
167167
# @param features [String] the list of supported features to tell the remote
168168
# host that the client supports (defaults to +DEFAULT_GDB_FEATURES+)
169169
def handshake(features=GDB_FEATURES)
170-
send_ack
171170
send_cmd features
172171
read_response # lots of flags, nothing interesting
173172
end

0 commit comments

Comments
 (0)