diff --git a/library/server/wsf/src/wsf_request.e b/library/server/wsf/src/wsf_request.e index 00708aae..10d8dfca 100644 --- a/library/server/wsf/src/wsf_request.e +++ b/library/server/wsf/src/wsf_request.e @@ -288,7 +288,7 @@ feature -- Access: Input end end if raw_input_data_recorded then - set_raw_input_data (buf.substring (buf_initial_size + 1, buf.count)) + set_raw_input_data (buf.substring (buf_initial_size + 1, buf.count)) -- Only the input data! And differente reference. end end @@ -833,6 +833,7 @@ feature -- Access: CGI meta parameters - 1.1 local l_result: like internal_percent_encoded_path_info r: READABLE_STRING_8 + pi: READABLE_STRING_32 i,m,n,spos: INTEGER do l_result := internal_percent_encoded_path_info @@ -844,11 +845,23 @@ feature -- Access: CGI meta parameters - 1.1 else l_result := r.string end - if attached script_name as s then + pi := path_info + i := 0 + if pi.is_valid_as_string_8 then + i := l_result.substring_index (pi.to_string_8, 1) + if i > 0 then + -- Path info is included in REQUEST_URI + -- so let's get the percent encoded path info from request uri. + l_result := l_result.substring (i, l_result.count) + end + end + --| here "i = 0" means request_uri does not start with `path_info', + --| thus let's compute it from `script_name'. + if i = 0 and attached script_name as s then if l_result.starts_with (s) then l_result := l_result.substring (s.count + 1, l_result.count) else - --| Handle Rewrite url engine, to have clean path + --| Handle Rewrite url engine, to have clean path from i := 1 m := l_result.count @@ -2083,7 +2096,7 @@ invariant wgi_request.content_type /= Void implies content_type /= Void note - copyright: "2011-2015, Jocelyn Fiat, Javier Velilla, Olivier Ligot, Colin Adams, Eiffel Software and others" + copyright: "2011-2016, Jocelyn Fiat, Javier Velilla, Olivier Ligot, Colin Adams, Eiffel Software and others" license: "Eiffel Forum License v2 (see http://www.eiffel.com/licensing/forum.txt)" source: "[ Eiffel Software