Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3509
8847.diff
Public
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Authored By
•
bzimport
Nov 21 2014, 9:31 PM
2014-11-21 21:31:04 (UTC+0)
Size
717 B
Referenced Files
None
Subscribers
None
8847.diff
View Options
Index: includes/WebRequest.php
===================================================================
--- includes/WebRequest.php (revision 20046)
+++ includes/WebRequest.php (working copy)
@@ -331,6 +331,14 @@
"REQUEST_URI or SCRIPT_NAME. Report details of your " .
"web server configuration to http://bugzilla.wikimedia.org/" );
}
+ // User-agents should not send a fragment with the URI, but
+ // if they do, and the web server passes it on to us, we
+ // need to strip it or we get false-positive redirect loops
+ // or weird output URLs
+ $hash = strpos( $base, '#' );
+ if( $hash !== false ) {
+ $base = substr( $base, 0, $hash );
+ }
if( $base{0} == '/' ) {
return $base;
} else {
File Metadata
Details
Attached
Mime Type
text/x-diff
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3076
Default Alt Text
8847.diff (717 B)
Attached To
Mode
T10847: Redirect loop detected on Section Edit
Attached
Detach File
Event Timeline
Log In to Comment