Changeset 3424572
- Timestamp:
- 12/21/2025 10:41:48 AM (3 months ago)
- Location:
- grid/trunk
- Files:
-
- 5 edited
-
lib/grid/classes/Editor.php (modified) (3 diffs)
-
lib/grid/classes/StyleEditor.php (modified) (3 diffs)
-
readme.txt (modified) (2 diffs)
-
vendor/composer/installed.php (modified) (2 diffs)
-
wordpress_plugin.php (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
grid/trunk/lib/grid/classes/Editor.php
r3351302 r3424572 13 13 14 14 public Storage $storage; 15 public string $url; 15 public string $url; 16 private iHook $hook; 16 17 17 18 /** … … 21 22 * @param string $urlBasePath url path to library dir 22 23 */ 23 public function __construct( Storage $storage, string $urlBasePath ) {24 public function __construct( Storage $storage, string $urlBasePath, iHook $hook ) { 24 25 $this->storage = $storage; 25 26 $this->url = $urlBasePath; 27 $this->hook=$hook; 26 28 } 27 29 … … 156 158 157 159 public function getStyleEditor() { 158 return new StyleEditor( $this->storage );160 return new StyleEditor( $this->storage,$this->hook ); 159 161 } 160 162 -
grid/trunk/lib/grid/classes/StyleEditor.php
r3351302 r3424572 12 12 13 13 public Storage $storage; 14 15 public function __construct(Storage $storage){ 16 $this->storage = $storage; 14 private iHook $hook; 15 16 public function __construct(Storage $storage, iHook $hook){ 17 $this->storage = $storage; 18 $this->hook = $hook; 17 19 } 18 20 … … 21 23 if(isset($_POST) && !empty($_POST)) 22 24 { 25 $this->hook->fire('styles_editor_post',$_POST); 23 26 foreach($_POST['container_styles'] as $idx=>$data) 24 27 { … … 94 97 </style> 95 98 <div class="grid-style-editor"> 96 <form method="post"> 99 <form method="post"> 100 <?php $this->hook->fire('grid_editor_styles_get',null); ?> 97 101 <p>Container Styles</p> 98 102 <table> -
grid/trunk/readme.txt
r3351302 r3424572 5 5 Requires at least: 4.0 6 6 Tested up to: 5.9.3 7 Stable tag: 2.3. 17 Stable tag: 2.3.2 8 8 License: GPLv3 9 9 License URI: http://www.gnu.org/licenses/gpl … … 89 89 == Changelog == 90 90 91 = 2.3.2 = 92 93 * Fix: prevents XSS attack on styles editor form 94 91 95 = 2.3.1 = 92 96 93 * Fixed a XSS vulnerability 94 * fixed some deprecation warnings 97 * Fix: prevented injection of JavaScript on the styles form into the database 95 98 96 99 = 2.3.0 = -
grid/trunk/vendor/composer/installed.php
r3351302 r3424572 4 4 'pretty_version' => 'dev-master', 5 5 'version' => 'dev-master', 6 'reference' => ' 5f58f47222ffcd2b294d0a018ca7872794142929',6 'reference' => '9bdb1dc2022cba13d5bc75b92ab1502e693b0a33', 7 7 'type' => 'library', 8 8 'install_path' => __DIR__ . '/../../', … … 14 14 'pretty_version' => 'dev-master', 15 15 'version' => 'dev-master', 16 'reference' => ' 5f58f47222ffcd2b294d0a018ca7872794142929',16 'reference' => '9bdb1dc2022cba13d5bc75b92ab1502e693b0a33', 17 17 'type' => 'library', 18 18 'install_path' => __DIR__ . '/../../', -
grid/trunk/wordpress_plugin.php
r3351302 r3424572 4 4 * Plugin URI: https://github.com/palasthotel/grid-wordpress 5 5 * Description: Helps layouting pages with containerist. 6 * Version: 2.3. 16 * Version: 2.3.2 7 7 * Author: Palasthotel <rezeption@palasthotel.de> (in person: Benjamin Birkenhake, Edward Bock, Enno Welbers, Jana Marie Eggebrecht) 8 8 * Author URI: http://www.palasthotel.de … … 125 125 $this->gridEditor = new Editor( 126 126 $this->gridCore->storage, 127 $this->url."/lib/grid/" 127 $this->url."/lib/grid/", 128 $this->gridHook 128 129 ); 129 130 … … 198 199 add_action( 'pre_get_posts', 'grid_enable_front_page_landing_page' ); 199 200 201 add_action( 'grid_grid_editor_styles_get',array($this,'styles_nonce')); 202 add_action( 'grid_styles_editor_post', array($this,'styles_checknonce')); 200 203 // ------------------------------------ 201 204 // uninstall 202 205 // ------------------------------------ 203 206 register_uninstall_hook( __FILE__, array( __CLASS__, 'uninstall' ) ); 207 } 208 209 public function styles_checknonce($data) { 210 if(!isset($data['_wpnonce']) || ! wp_verify_nonce($data['_wpnonce'])) { 211 die("invalid nonce."); 212 } 213 } 214 215 public function styles_nonce() { 216 echo wp_nonce_field(); 204 217 } 205 218
Note: See TracChangeset
for help on using the changeset viewer.