From facb6d99c64f66b488f2e37719cf281cd5aa8baa Mon Sep 17 00:00:00 2001 From: Ashley Donaldson Date: Wed, 28 Apr 2021 17:54:19 +1000 Subject: [PATCH] Fixed unit test failure --- lib/msf/core/auxiliary/redis.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/msf/core/auxiliary/redis.rb b/lib/msf/core/auxiliary/redis.rb index 12122addb2..fa2435df20 100644 --- a/lib/msf/core/auxiliary/redis.rb +++ b/lib/msf/core/auxiliary/redis.rb @@ -115,7 +115,7 @@ module Msf end def data_at_counter - @raw_data[@counter..] + @raw_data[@counter..-1] end def parse_resp_array @@ -138,7 +138,7 @@ module Msf def parse_simple_string str_end = data_at_counter.index(LINE_BREAK) str_end = str_end.to_i - result = data_at_counter[1..str_end-1] + result = data_at_counter[1..str_end - 1] @counter += str_end @counter += 2 # Skip over next CLRF result @@ -150,7 +150,7 @@ module Msf end str_len = str_len.to_i @counter += data_at_counter.index(LINE_BREAK) + 2 - result = data_at_counter[..str_len-1] + result = data_at_counter[0..str_len - 1] @counter += str_len @counter += 2 # Skip over next CLRF result