[Alba-desarrollo] SVN Alba r6135 - in
prosistem/alba/trunk/alba/lib/vendor/symfony: . lib/autoload
lib/generator
lib/plugins/sfDoctrinePlugin/data/generator/sfDoctrineModule/admin/parts
lib/plugins/sfPropelPlugin/data/generator/sfPropelModule/admin/parts
commits en pressenter.com.ar
commits en pressenter.com.ar
Lun Abr 27 22:30:13 CEST 2009
Author: ftoledo
Date: 2009-04-27 17:30:13 -0300 (Mon, 27 Apr 2009)
New Revision: 6135
Modified:
prosistem/alba/trunk/alba/lib/vendor/symfony/CHANGELOG
prosistem/alba/trunk/alba/lib/vendor/symfony/lib/autoload/sfCoreAutoload.class.php
prosistem/alba/trunk/alba/lib/vendor/symfony/lib/generator/sfModelGeneratorConfiguration.class.php
prosistem/alba/trunk/alba/lib/vendor/symfony/lib/plugins/sfDoctrinePlugin/data/generator/sfDoctrineModule/admin/parts/configuration.php
prosistem/alba/trunk/alba/lib/vendor/symfony/lib/plugins/sfPropelPlugin/data/generator/sfPropelModule/admin/parts/configuration.php
Log:
symfony 1.2.6 security fix
Modified: prosistem/alba/trunk/alba/lib/vendor/symfony/CHANGELOG
===================================================================
--- prosistem/alba/trunk/alba/lib/vendor/symfony/CHANGELOG 2009-04-27 20:03:19 UTC (rev 6134)
+++ prosistem/alba/trunk/alba/lib/vendor/symfony/CHANGELOG 2009-04-27 20:30:13 UTC (rev 6135)
@@ -1,10 +1,17 @@
-Version 1.2.5
--------------
See the UPGRADE_TO_1_1 for upgrading 1.0 projects first to 1.1.
See the UPGRADE_TO_1_2 file for more information about upgrading your projects from 1.1 to 1.2.
All the new features are documented in the What's new? tutorial (http://www.symfony-project.org/tutorial/1_2/whats-new)
+Version 1.2.6
+-------------
+
+The 1.2.6 release is security release.
+Please read http://www.symfony-project.org/blog/2009/04/27/symfony-1-2-6-security-fix for more information.
+
+Version 1.2.5
+-------------
+
* [16656]: fixed invalid assumption in cache:clear task (closes #6181)
* [16587]: added CA translation for admin generator
* [16555]: Removed extra slash from web debug image root
Modified: prosistem/alba/trunk/alba/lib/vendor/symfony/lib/autoload/sfCoreAutoload.class.php
===================================================================
--- prosistem/alba/trunk/alba/lib/vendor/symfony/lib/autoload/sfCoreAutoload.class.php 2009-04-27 20:03:19 UTC (rev 6134)
+++ prosistem/alba/trunk/alba/lib/vendor/symfony/lib/autoload/sfCoreAutoload.class.php 2009-04-27 20:30:13 UTC (rev 6135)
@@ -11,7 +11,7 @@
/**
* The current symfony version.
*/
-define('SYMFONY_VERSION', '1.2.5');
+define('SYMFONY_VERSION', '1.2.6');
/**
* sfCoreAutoload class.
@@ -22,7 +22,7 @@
* @package symfony
* @subpackage autoload
* @author Fabien Potencier <fabien.potencier en symfony-project.com>
- * @version SVN: $Id: sfCoreAutoload.class.php 16696 2009-03-28 16:46:30Z FabianLange $
+ * @version SVN: $Id: sfCoreAutoload.class.php 17682 2009-04-27 15:24:21Z fabien $
*/
class sfCoreAutoload
{
Modified: prosistem/alba/trunk/alba/lib/vendor/symfony/lib/generator/sfModelGeneratorConfiguration.class.php
===================================================================
--- prosistem/alba/trunk/alba/lib/vendor/symfony/lib/generator/sfModelGeneratorConfiguration.class.php 2009-04-27 20:03:19 UTC (rev 6134)
+++ prosistem/alba/trunk/alba/lib/vendor/symfony/lib/generator/sfModelGeneratorConfiguration.class.php 2009-04-27 20:30:13 UTC (rev 6135)
@@ -6,7 +6,7 @@
* @package symfony
* @subpackage generator
* @author Fabien Potencier <fabien.potencier en symfony-project.com>
- * @version SVN: $Id: sfModelGeneratorConfiguration.class.php 13653 2008-12-03 08:51:34Z fabien $
+ * @version SVN: $Id: sfModelGeneratorConfiguration.class.php 17680 2009-04-27 15:19:58Z fabien $
*/
class sfModelGeneratorConfiguration
{
@@ -383,6 +383,36 @@
return $default;
}
+ /**
+ * Removes visible fields not included for display.
+ *
+ * @param sfForm $form
+ */
+ protected function fixFormFields(sfForm $form)
+ {
+ $method = sprintf('get%sDisplay', $form->isNew() ? 'New' : 'Edit');
+ if (!$display = $this->$method())
+ {
+ $display = $this->getFormDisplay();
+ }
+
+ if ($display)
+ {
+ if (is_array(current($display)))
+ {
+ $display = call_user_func_array('array_merge', array_values($display));
+ }
+
+ foreach ($form as $name => $field)
+ {
+ if (!$field->isHidden() && !in_array($name, $display))
+ {
+ unset($form[$name]);
+ }
+ }
+ }
+ }
+
protected function fixActionParameters($action, $parameters)
{
if (is_null($parameters))
Modified: prosistem/alba/trunk/alba/lib/vendor/symfony/lib/plugins/sfDoctrinePlugin/data/generator/sfDoctrineModule/admin/parts/configuration.php
===================================================================
--- prosistem/alba/trunk/alba/lib/vendor/symfony/lib/plugins/sfDoctrinePlugin/data/generator/sfDoctrineModule/admin/parts/configuration.php 2009-04-27 20:03:19 UTC (rev 6134)
+++ prosistem/alba/trunk/alba/lib/vendor/symfony/lib/plugins/sfDoctrinePlugin/data/generator/sfDoctrineModule/admin/parts/configuration.php 2009-04-27 20:30:13 UTC (rev 6135)
@@ -14,11 +14,22 @@
<?php include dirname(__FILE__).'/fieldsConfiguration.php' ?>
+ /**
+ * Gets a new form object.
+ *
+ * @param mixed $object
+ *
+ * @return sfForm
+ */
public function getForm($object = null)
{
$class = $this->getFormClass();
- return new $class($object, $this->getFormOptions());
+ $form = new $class($object, $this->getFormOptions());
+
+ $this->fixFormFields($form);
+
+ return $form;
}
/**
Modified: prosistem/alba/trunk/alba/lib/vendor/symfony/lib/plugins/sfPropelPlugin/data/generator/sfPropelModule/admin/parts/configuration.php
===================================================================
--- prosistem/alba/trunk/alba/lib/vendor/symfony/lib/plugins/sfPropelPlugin/data/generator/sfPropelModule/admin/parts/configuration.php 2009-04-27 20:03:19 UTC (rev 6134)
+++ prosistem/alba/trunk/alba/lib/vendor/symfony/lib/plugins/sfPropelPlugin/data/generator/sfPropelModule/admin/parts/configuration.php 2009-04-27 20:30:13 UTC (rev 6135)
@@ -6,7 +6,7 @@
* @package ##PROJECT_NAME##
* @subpackage <?php echo $this->getModuleName()."\n" ?>
* @author ##AUTHOR_NAME##
- * @version SVN: $Id: configuration.php 12831 2008-11-09 14:33:38Z fabien $
+ * @version SVN: $Id: configuration.php 17680 2009-04-27 15:19:58Z fabien $
*/
class Base<?php echo ucfirst($this->getModuleName()) ?>GeneratorConfiguration extends sfModelGeneratorConfiguration
{
@@ -14,11 +14,22 @@
<?php include dirname(__FILE__).'/fieldsConfiguration.php' ?>
+ /**
+ * Gets a new form object.
+ *
+ * @param mixed $object
+ *
+ * @return sfForm
+ */
public function getForm($object = null)
{
$class = $this->getFormClass();
- return new $class($object, $this->getFormOptions());
+ $form = new $class($object, $this->getFormOptions());
+
+ $this->fixFormFields($form);
+
+ return $form;
}
/**
Más información sobre la lista de distribución Alba-desarrollo