Make WordPress Core

Opened 13 years ago

Closed 13 years ago

Last modified 9 years ago

#1335 closed defect (bug) (wontfix)

path info is disclosed

Reported by: anonymousbugger Owned by:
Milestone: Priority: normal
Severity: minor Version: 1.5.1
Component: Administration Keywords: bg|squashed
Focuses: Cc:


Bringing up http://www.yourblog.com/wp-admin/admin-footer.php results in server path info being disclosed. Specifically, you see: Fatal error: Call to undefined function: bloginfo() in /home/username/public_html/wp-admin/admin-footer.php on line 3

Change History (9)

#1 @anonymousbugger
13 years ago

  • Patch set to No

#2 @anonymousbugger
13 years ago

Re-adding deleted note:

Just turn off display_errors in php.ini!

#3 @twistedraisin
13 years ago

Could this be fixed with something like ini_set('display_errors','Off');

in the initialization sequence, perhaps based on a debug setting?

perhaps adding

define('WP_OUTPUT_ERRORS',false); to the wp-config.php file, and making it conditional on that, or adding a new option on the admin page, and making it conditional on that, with the default being false?

#4 @anonymousbugger
13 years ago

what sort of fix is this for people that do NOT have access to their php.ini? Sure seems like a lazy solution to something that should be trivia for any software application.

#5 @twistedraisin
13 years ago

ini_set() does not require access to the php.ini file, and it affects only the script as it is running, which is why I suggested it be put in the startup sequence.

As for having it based on a defined constant or on a setting, I think that makes good sense for people who are writing or testing, being able to turn on and off errors to see if the code gracefully fails without affecting headers and output that get shunted out when the error occurs.

#6 @anonymousbugger
13 years ago

twisted raisen, yes youre idea is fine -- it was the first solution I was responding to -- totally unacceptable to me. plugging up Path disclosures and php errors should be handled within the application itself -- NOT by having to modify one's php.ini, which not only can not all people do .. but some ppl LIKE having debugging/error output turned on for other reasons.

#7 @MC_incubus
13 years ago

This strikes me as something that is a universal complaint about PHP. But also consider that without errors shown, it will be very hard for regular users to report bugs in WP or in WP plugins. There will have to be a whole "well, turn on errors by editing this file and changint this constant or commenting out this line" ordeal.

#8 @markjaquith
13 years ago

  • Keywords bg|squashed added
  • Resolution set to wontfix
  • Status changed from new to closed

#9 @thenlich
10 years ago

Related to #1038

Note: See TracTickets for help on using tickets.