It seems like a developer screwed up and exposed some php code on the Yahoo! fantasy basketball website. I guess you could call it a NIPSLIP of the coding world. Not very secure if you're going to set your header to plain/text and show everyone some of your goods...
<?php
$game = 'top';
$page = $_GET['page'];
require_once( '/home/y/share/pear/Yahoo/Media/YUIUtil/class.YUIList.php' );
ri_guard_require_once( '/home/y/share/pear/Yahoo/Sports/Common/Util.inc' );
ri_guard_require_once( '/home/y/share/pear/Yahoo/Sports/Fantasy/YSFDbflatManager.inc' );
ri_guard_require_once( '/home/y/share/pear/Yahoo/Sports/Fantorial/Top/YSFETopFactory.inc' );
// set the intl
$intl = yintl_get();
yintl_set( 'us' );
$yuid = yahoo_cookie_get_yuid();
$login = yahoo_cookie_get_login();
$ysp_factory = new YSFETopFactory;
// create the controller and set some params
$ysp_controller =& $ysp_factory->get_controller_instance();
$ysp_controller->set_param( 'page', $page );
$ysp_controller->set_param( 'game', $game );
$ysp_controller->set_param( 'yuid', $yuid );
$ysp_controller->set_param( 'login', $login );
$ysp_controller->set_param( 'intl', $intl );
// check if user changed password and force login if so
$ysp_controller->check_password_changed();
$o_display_cfg =& $ysp_factory->get_display_configuration_instance();
$o_display_layout =& $ysp_factory->get_display_layout_instance();
$o_module_include =& $ysp_factory->get_module_include_instance();
// initialize the errors to empty array
$errors = array();
// process the request
$display_page = $ysp_controller->process_request( $page, $errors );
// make sure display_page exists, if not send to 404 page
if ( ! $o_display_layout->get( $display_page, 'template' ) ) {
$display_page = 'notfound';
}
// make the $page be the same as $display_page
$page = $display_page;
$ysp_controller->set_param( 'page', $page );
$ysp_controller->set_param( 'display_page', $display_page );
// get the space id
if ( $o_display_layout->get( $display_page, 'spaceid_path' ) ) {
$spaceid_page = $o_display_layout->get( $display_page, 'spaceid_path' );
}
else {
$spaceid_page = $o_display_cfg->get( 'spaceid_path' ) . "/$display_page";
}
$spaceid = yahoo_sports_get_space_id( $spaceid_page );
// get the ad locations
$ad_locations_hash = $o_display_cfg->get( 'ad_locations' );
$ad_locations = $ad_locations_hash['default'];
if ( isset( $ad_locations_hash["$display_page"] ) ) {
$ad_locations = $ad_locations_hash["$display_page"];
}
$ysp_controller->setup_ads( $ad_locations, $spaceid );
// get the template to use
$template = 'generic';
if ( $o_display_layout->get( $page, 'template' ) ) {
$template = $o_display_layout->get( $page, 'template' );
}
// include the actually template
$o_module_include->include_file( "template_${template}.php" );
// save and close and db files that were left open
$o_dbflat =& YSFDbflatManager::get_instance();
$o_dbflat->close_all( $errors );
$ysp_controller->audit_ads();
?>
Recent Comments