Skip to content

Commit 4293af0

Browse files
David MaloneyDavid Maloney
authored andcommitted
make sure we strip leading whitespace
in the aforementiond record_request_and_response method we need to still make sure to strip leading whitespace from the front of our data before saving it MSP-9972
1 parent dacaa9e commit 4293af0

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/rex/parser/appscan_nokogiri.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -193,12 +193,12 @@ def record_request_and_response
193193
return unless(request_headers && response_headers)
194194
req_header = Rex::Proto::Http::Packet::Header.new
195195
res_header = Rex::Proto::Http::Packet::Header.new
196-
req_header.from_s request_headers.dup
197-
res_header.from_s response_headers.dup
196+
req_header.from_s request_headers.lstrip
197+
res_header.from_s response_headers.lstrip
198198
@state[:request_headers] = req_header
199-
@state[:request_body] = request_body
199+
@state[:request_body] = request_body.lstrip
200200
@state[:response_headers] = res_header
201-
@state[:response_body] = response_body
201+
@state[:response_body] = response_body.lstrip
202202
end
203203

204204
# Appscan tab-indents which makes parsing a little difficult. They

0 commit comments

Comments
 (0)