Advanced Ads - Version 1.33.2

Version Description

(April 21, 2022) =

  • Fix: disable external XML entity loading only when libxml is less than 2.9.0
  • Fix: correct Composer autoloader for PHP 5.6
Download this release

Release Info

Developer advancedads
Plugin Icon 128x128 Advanced Ads
Version 1.33.2
Comparing to
See all releases

Code changes from version 1.33.1 to 1.33.2

advanced-ads.php CHANGED
@@ -12,7 +12,7 @@
12
  * Plugin Name: Advanced Ads
13
  * Plugin URI: https://wpadvancedads.com
14
  * Description: Manage and optimize your ads in WordPress
15
- * Version: 1.33.1
16
  * Author: Thomas Maier, Advanced Ads GmbH
17
  * Author URI: https://wpadvancedads.com
18
  * Text Domain: advanced-ads
@@ -39,7 +39,7 @@ define( 'ADVADS_BASE_DIR', dirname( ADVADS_BASE ) ); // directory of the plugin
39
  // general and global slug, e.g. to store options in WP.
40
  define( 'ADVADS_SLUG', 'advanced-ads' );
41
  define( 'ADVADS_URL', 'https://wpadvancedads.com/' );
42
- define( 'ADVADS_VERSION', '1.33.1' );
43
 
44
  // Autoloading, modules and functions.
45
 
12
  * Plugin Name: Advanced Ads
13
  * Plugin URI: https://wpadvancedads.com
14
  * Description: Manage and optimize your ads in WordPress
15
+ * Version: 1.33.2
16
  * Author: Thomas Maier, Advanced Ads GmbH
17
  * Author URI: https://wpadvancedads.com
18
  * Text Domain: advanced-ads
39
  // general and global slug, e.g. to store options in WP.
40
  define( 'ADVADS_SLUG', 'advanced-ads' );
41
  define( 'ADVADS_URL', 'https://wpadvancedads.com/' );
42
+ define( 'ADVADS_VERSION', '1.33.2' );
43
 
44
  // Autoloading, modules and functions.
45
 
languages/advanced-ads.pot CHANGED
@@ -1,17 +1,17 @@
1
  # Copyright (C) 2022 Thomas Maier, Advanced Ads GmbH
2
- # This file is distributed under the same license as the Advanced Ads plugin.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Advanced Ads 1.33.1\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/advanced-ads/\n"
7
  "Last-Translator: Thomas Maier <post@webzunft.de>\n"
8
  "Language-Team: webgilde <support@wpadvancedads.com>\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
- "POT-Creation-Date: 2022-04-11T07:14:46-05:00\n"
13
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
14
- "X-Generator: WP-CLI 2.4.0\n"
15
  "X-Domain: advanced-ads\n"
16
 
17
  #. Plugin Name of the plugin
@@ -4143,7 +4143,7 @@ msgctxt "import_export"
4143
  msgid "Invalid XML data, it can not be empty"
4144
  msgstr ""
4145
 
4146
- #: modules/import-export/classes/XmlEncoder.php:242
4147
  msgctxt "import_export"
4148
  msgid "XML error: %s"
4149
  msgstr ""
1
  # Copyright (C) 2022 Thomas Maier, Advanced Ads GmbH
2
+ # This file is distributed under the GPL-2.0+.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Advanced Ads 1.33.2\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/advanced-ads/\n"
7
  "Last-Translator: Thomas Maier <post@webzunft.de>\n"
8
  "Language-Team: webgilde <support@wpadvancedads.com>\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
+ "POT-Creation-Date: 2022-04-21T11:05:08+00:00\n"
13
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
14
+ "X-Generator: WP-CLI 2.6.0\n"
15
  "X-Domain: advanced-ads\n"
16
 
17
  #. Plugin Name of the plugin
4143
  msgid "Invalid XML data, it can not be empty"
4144
  msgstr ""
4145
 
4146
+ #: modules/import-export/classes/XmlEncoder.php:244
4147
  msgctxt "import_export"
4148
  msgid "XML error: %s"
4149
  msgstr ""
lib/autoload.php CHANGED
@@ -2,6 +2,11 @@
2
 
3
  // autoload.php @generated by Composer
4
 
 
 
 
 
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
  return ComposerAutoloaderInit_advanced_ads::getLoader();
2
 
3
  // autoload.php @generated by Composer
4
 
5
+ if (PHP_VERSION_ID < 50600) {
6
+ echo 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
7
+ exit(1);
8
+ }
9
+
10
  require_once __DIR__ . '/composer/autoload_real.php';
11
 
12
  return ComposerAutoloaderInit_advanced_ads::getLoader();
lib/composer/autoload_real.php CHANGED
@@ -29,7 +29,7 @@ class ComposerAutoloaderInit_advanced_ads
29
  spl_autoload_unregister(array('ComposerAutoloaderInit_advanced_ads', 'loadClassLoader'));
30
 
31
  require __DIR__ . '/autoload_static.php';
32
- \AdvancedAds\Composer\Autoload\ComposerStaticInit_advanced_ads::getInitializer($loader)();
33
 
34
  $loader->setClassMapAuthoritative(true);
35
  $loader->register(true);
29
  spl_autoload_unregister(array('ComposerAutoloaderInit_advanced_ads', 'loadClassLoader'));
30
 
31
  require __DIR__ . '/autoload_static.php';
32
+ call_user_func(\AdvancedAds\Composer\Autoload\ComposerStaticInit_advanced_ads::getInitializer($loader));
33
 
34
  $loader->setClassMapAuthoritative(true);
35
  $loader->register(true);
modules/import-export/classes/XmlEncoder.php CHANGED
@@ -212,9 +212,10 @@ class Advanced_Ads_XmlEncoder
212
 
213
  $internal_errors = libxml_use_internal_errors( true );
214
 
215
- if ( PHP_VERSION_ID < 80000 ) {
216
- // This function has been deprecated in PHP 8.0 because in libxml 2.9.0, external entity loading
217
- // is disabled by default, so this function is no longer needed to protect against XXE attacks.
 
218
  // phpcs:ignore PHPCompatibility.FunctionUse.RemovedFunctions.libxml_disable_entity_loaderDeprecated
219
  $disable_entities = libxml_disable_entity_loader( true );
220
  }
@@ -232,7 +233,8 @@ class Advanced_Ads_XmlEncoder
232
 
233
  libxml_use_internal_errors( $internal_errors );
234
 
235
- if ( PHP_VERSION_ID < 80000 && isset( $disable_entities ) ) {
 
236
  libxml_disable_entity_loader( $disable_entities );
237
  }
238
 
212
 
213
  $internal_errors = libxml_use_internal_errors( true );
214
 
215
+ if ( LIBXML_VERSION < 20900 ) {
216
+ // The `libxml_disable_entity_loading` function has been deprecated in PHP 8.0 because in
217
+ // libxml >= 2.9.0 (that is required by PHP 8), external entity loading is disabled by default,
218
+ // so this function is no longer needed to protect against XXE attacks.
219
  // phpcs:ignore PHPCompatibility.FunctionUse.RemovedFunctions.libxml_disable_entity_loaderDeprecated
220
  $disable_entities = libxml_disable_entity_loader( true );
221
  }
233
 
234
  libxml_use_internal_errors( $internal_errors );
235
 
236
+ if ( LIBXML_VERSION < 20900 ) {
237
+ // phpcs:ignore PHPCompatibility.FunctionUse.RemovedFunctions.libxml_disable_entity_loaderDeprecated -- see L215ff. for an explanation
238
  libxml_disable_entity_loader( $disable_entities );
239
  }
240
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: ads, adsense, amp, ads.txt, ad rotations, ad blocker, amazon, banner, clic
4
  Requires at least: 4.9
5
  Tested up to: 5.9
6
  Requires PHP: 5.6
7
- Stable tag: 1.33.1
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -330,6 +330,11 @@ Yes. You can use plenty of [hooks](https://wpadvancedads.com/codex/) to customiz
330
 
331
  == Changelog ==
332
 
 
 
 
 
 
333
  = 1.33.1 (April 11, 2022) =
334
 
335
  - Fix: rename remaining instances of "Matched Content" AdSense ad type to "Multiplex"
4
  Requires at least: 4.9
5
  Tested up to: 5.9
6
  Requires PHP: 5.6
7
+ Stable tag: 1.33.2
8
  License: GPLv2 or later
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
330
 
331
  == Changelog ==
332
 
333
+ = 1.33.2 (April 21, 2022) =
334
+
335
+ - Fix: disable external XML entity loading only when libxml is less than 2.9.0
336
+ - Fix: correct Composer autoloader for PHP 5.6
337
+
338
  = 1.33.1 (April 11, 2022) =
339
 
340
  - Fix: rename remaining instances of "Matched Content" AdSense ad type to "Multiplex"