Make WordPress Core

Opened 12 years ago

Closed 11 years ago

#10417 closed enhancement (duplicate)

Provide redirection follow capabilities in HTTP API when safe_mode or open_basedir are set

Reported by: sivel Owned by: dd32
Milestone: Priority: normal
Severity: normal Version: 2.8.1
Component: HTTP API Keywords:
Focuses: Cc:


When safe_mode or open_basedir are set it seems that the only transport that can "follow" the redirects is fsockopen. All others stop after the initial request.

Simplepie seems to have a method of "manually" following by checking to see if the last response was a 30x and checks the number of redirects. If the last response was a 30x and the redirects that happened were less than configured it does a "manual" follow by requesting, grabbing the 'Location' header and then requesting again until it either hits the redirect limit or a non 30x response code.

Change History (5)

#1 @sivel
12 years ago

Just to cross reference 2 other tickets:

#2 @dd32
12 years ago

I believe one of the transports includes a check to see if its running under safemode, and not to use it in that scenario.

Just need some extra constraints added to the ::test(); methods IMO

#3 @sivel
12 years ago

Basically in the end if we add the checks to see if running in safe mode it will limit us to fsockopen. That is fine with me, if everyone else is ok with it.

#4 @ryan
11 years ago

  • Milestone changed from 2.9 to Future Release

#5 @dd32
11 years ago

  • Milestone Future Release deleted
  • Resolution set to duplicate
  • Status changed from new to closed

See: #11305 WP_Http won't follow redirects if open_basedir is in effect

Note: See TracTickets for help on using tickets.