From ee1c9517bc2052d6e57fb60e4a670b744ef4f3a9 Mon Sep 17 00:00:00 2001 From: Paul Wouters Date: Wed, 11 Sep 2013 22:04:06 -0400 Subject: [PATCH 01/20] * Thu Sep 12 2013 Paul Wouters - 3.6.1-1 - update to 3.6.1, various bugs and security fixes: CVE-2013-4338 CVE-2013-4339 CVE-2013-4340 --- sources | 2 +- wordpress.spec | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/sources b/sources index 36c9fae..ab49b3f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -ddbe1549dc27a260d28b47ad32eadd34 wordpress-3.6.tar.gz +3f2c0b6f7f0626b5170a7b5df99d78b8 wordpress-3.6.1.tar.gz diff --git a/wordpress.spec b/wordpress.spec index e3d91c9..4e83f69 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -4,7 +4,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.6 +Version: 3.6.1 Group: Applications/Publishing #Release: 0.5.%{betatag}%{?dist} Release: 1%{?dist} @@ -205,6 +205,10 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Thu Sep 12 2013 Paul Wouters - 3.6.1-1 +- update to 3.6.1, various bugs and security fixes: + CVE-2013-4338 CVE-2013-4339 CVE-2013-4340 + * Thu Aug 22 2013 Adam Williamson - 3.6.0-1 - update to 3.6.0 - drop pre-compiled Flash and Silverlight binaries - #1000267 From 7e8fa7a4a9a790159c8a178e32ce94810f368d01 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 30 Oct 2013 08:08:32 +0100 Subject: [PATCH 02/20] update to 3.7.1 (bugfixes) (cherry picked from commit 64afcf22feb90eaf0c5f3545224e5ca7d5d024e5) --- .gitignore | 1 + sources | 2 +- wordpress.spec | 5 ++++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index eaa76bd..d0e02cd 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ *spec~ clog /wordpress-3.7.tar.gz +/wordpress-3.7.1.tar.gz diff --git a/sources b/sources index a1a980b..9fc516f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -aaad36cd739b825952cf3e09de5e7856 wordpress-3.7.tar.gz +8af9a4885ad134d354eb5f12dcc17fd9 wordpress-3.7.1.tar.gz diff --git a/wordpress.spec b/wordpress.spec index fe73fa8..b60962f 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -9,7 +9,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.7 +Version: 3.7.1 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -220,6 +220,9 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Wed Oct 30 2013 Remi Collet - 3.7.1-1 +- update to 3.7.1 (bugfixes) + * Fri Oct 25 2013 Remi Collet - 3.7-1 - update to 3.7 - requires ca-certificates for ca-bundle.crt From 51b7c138d3875b0846e19257acfe02ff2018253f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 16 Dec 2013 15:36:44 +0100 Subject: [PATCH 03/20] =?UTF-8?q?-=20update=20to=203.8=20=E2=80=9CParker?= =?UTF-8?q?=E2=80=9D=20#1043104=20-=20link=20to=20README.fedora=20in=20pac?= =?UTF-8?q?kage=20description=20-=20add=20note=20about=20optional=20packag?= =?UTF-8?q?es=20#1037516=20-=20add=20php=20dependencies:=20ereg,=20ftp,=20?= =?UTF-8?q?gd,=20xml=20-=20del=20php=20dependencies:=20pdo,=20reflection?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit b99791fd2e08e1beff311032ce16ca7b0d579345) --- .gitignore | 1 + README.fedora.wordpress | 20 ++++++++++++++++++++ sources | 2 +- wordpress.spec | 23 +++++++++++++++++------ 4 files changed, 39 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index d0e02cd..2dc89cd 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ clog /wordpress-3.7.tar.gz /wordpress-3.7.1.tar.gz +/wordpress-3.8.tar.gz diff --git a/README.fedora.wordpress b/README.fedora.wordpress index 20f8739..7fdb058 100644 --- a/README.fedora.wordpress +++ b/README.fedora.wordpress @@ -1,3 +1,5 @@ +------------------------------------------------------------------------------- + Wordpress is a database driven blogging program designed to make it exceedingly easy to publish an online blog, sometimes also called a weblog or journal. @@ -44,6 +46,8 @@ open a web browser to http://localhost/wordpress/wp-admin/install.php and follow the instructions given to you on the pages you see to set up the database tables and begin publishing your blog. +------------------------------------------------------------------------------- + Wordpress ships with Flash and Silverlight plugins for the 'plupload' file uploader and the 'mediaelement' media player embedder. The idea is to try and be able to provide a multi-file uploader and an embedded video player when @@ -64,3 +68,19 @@ b) If you try to embed media into a Wordpress post using the [video] and a browser that has HTML5 support for the media format in question; if not, the 'Download Media' link will be offered. No Flash or Silverlight-based player element will be included. + +------------------------------------------------------------------------------- + +Optional dependencies: + +You may wish to install the following packages: + + php-pecl-imagick: optimize image transformation + php-pecl-ssh2: for file transfert using ssh + +An opcode cache is also recommended: + php 5.5: php-opcache + php 5.4: php-pecl-zendopcache + php 5.3: php-pecl-apc + +------------------------------------------------------------------------------- diff --git a/sources b/sources index 9fc516f..bcc3eca 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -8af9a4885ad134d354eb5f12dcc17fd9 wordpress-3.7.1.tar.gz +0999d444137ecc4a36355403a67096e4 wordpress-3.8.tar.gz diff --git a/wordpress.spec b/wordpress.spec index b60962f..c60d6ef 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -1,3 +1,4 @@ +%{!?_pkgdocdir: %global _pkgdocdir %{_docdir}/%{name}-%{version}} %global wp_content %{_datadir}/wordpress/wp-content %if 0%{?rhel} == 5 @@ -9,7 +10,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.7.1 +Version: 3.8 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -46,15 +47,16 @@ Requires: php53-simplepie >= 1.3.1 Requires: php >= 5.2.4 Requires: php-simplepie >= 1.3.1 %endif -# Required php extension (detected by phpcompatinfo) +# From phpcompatinfo report for version 3.8 Requires: php-curl Requires: php-date Requires: php-dom Requires: php-enchant -# not yet available for RHEL Requires: php-ereg +Requires: php-ereg Requires: php-exif Requires: php-fileinfo -# not yet available for RHEL Requires: php-filter +Requires: php-ftp +Requires: php-gd Requires: php-gettext Requires: php-hash Requires: php-iconv @@ -64,13 +66,12 @@ Requires: php-mbstring Requires: php-mysql Requires: php-openssl Requires: php-pcre -Requires: php-pdo Requires: php-posix -Requires: php-reflection Requires: php-simplexml Requires: php-sockets Requires: php-spl Requires: php-tokenizer +Requires: php-xml Requires: php-zip Requires: php-zlib # Unbundled libraries @@ -86,6 +87,9 @@ Obsoletes: wordpress-mu < 2.9.3 Wordpress is an online publishing / weblog package that makes it very easy, almost trivial, to get information out to people on the web. +Important information in %{_pkgdocdir}/README.fedora + + %prep %setup -q -n wordpress @@ -220,6 +224,13 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Mon Dec 16 2013 Remi Collet - 3.8-1 +- update to 3.8 “Parker” #1043104 +- link to README.fedora in package description +- add note about optional packages #1037516 +- add php dependencies: ereg, ftp, gd, xml +- del php dependencies: pdo, reflection + * Wed Oct 30 2013 Remi Collet - 3.7.1-1 - update to 3.7.1 (bugfixes) From d7cb3f0b0c9568320164eb67a18f7b9e7f21a458 Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Thu, 23 Jan 2014 19:41:32 -0800 Subject: [PATCH 04/20] new release 3.8.1 (bugfix, no security) --- .gitignore | 1 + sources | 2 +- wordpress.spec | 5 ++++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 2dc89cd..fb01b80 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ clog /wordpress-3.7.tar.gz /wordpress-3.7.1.tar.gz /wordpress-3.8.tar.gz +/wordpress-3.8.1.tar.gz diff --git a/sources b/sources index bcc3eca..f55410e 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -0999d444137ecc4a36355403a67096e4 wordpress-3.8.tar.gz +6da5f73a2c7a46457b6ceb20fb6166c2 wordpress-3.8.1.tar.gz diff --git a/wordpress.spec b/wordpress.spec index c60d6ef..eceea7c 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -10,7 +10,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.8 +Version: 3.8.1 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -224,6 +224,9 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Thu Jan 23 2014 Adam Williamson - 3.8.1-1 +- new upstream release 3.8.1 (bugfixes) + * Mon Dec 16 2013 Remi Collet - 3.8-1 - update to 3.8 “Parker” #1043104 - link to README.fedora in package description From e9d1e18d7cbd16b3303ae58f8074c17698de960c Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Sat, 25 Jan 2014 08:10:20 +0100 Subject: [PATCH 05/20] update to 3.8.1 + disable auto-updater --- wordpress-3.8.1-config.patch | 32 +++++++++++++ wordpress-3.8.1-noupdate.patch | 86 ++++++++++++++++++++++++++++++++++ wordpress.spec | 46 +++++++++++++----- 3 files changed, 151 insertions(+), 13 deletions(-) create mode 100644 wordpress-3.8.1-config.patch create mode 100644 wordpress-3.8.1-noupdate.patch diff --git a/wordpress-3.8.1-config.patch b/wordpress-3.8.1-config.patch new file mode 100644 index 0000000..9f50f11 --- /dev/null +++ b/wordpress-3.8.1-config.patch @@ -0,0 +1,32 @@ +diff -up wordpress/wp-config.php.old wordpress/wp-config.php +--- wordpress/wp-config.php.old 2014-01-25 07:47:17.622959116 +0100 ++++ wordpress/wp-config.php 2014-01-25 07:54:06.816454385 +0100 +@@ -72,6 +72,19 @@ $table_prefix = 'wp_'; + define('WPLANG', ''); + + /** ++ * See http://make.wordpress.org/core/2013/10/25/the-definitive-guide-to-disabling-auto-updates-in-wordpress-3-7 ++ */ ++ ++/* Disable all file change, as RPM base installation are read-only */ ++define('DISALLOW_FILE_MODS', true); ++ ++/* Disable automatic updater, in case you want to allow ++ above FILE_MODS for plugins, themes, ... */ ++define('AUTOMATIC_UPDATER_DISABLED', true); ++ ++/* Core update is always disabled, WP_AUTO_UPDATE_CORE value is ignore */ ++ ++/** + * For developers: WordPress debugging mode. + * + * Change this to true to enable the display of notices during development. +@@ -84,7 +97,7 @@ define('WP_DEBUG', false); + + /** Absolute path to the WordPress directory. */ + if ( !defined('ABSPATH') ) +- define('ABSPATH', dirname(__FILE__) . '/'); ++ define('ABSPATH', '/usr/share/wordpress'); + + /** Sets up WordPress vars and included files. */ + require_once(ABSPATH . 'wp-settings.php'); diff --git a/wordpress-3.8.1-noupdate.patch b/wordpress-3.8.1-noupdate.patch new file mode 100644 index 0000000..c2b2f6f --- /dev/null +++ b/wordpress-3.8.1-noupdate.patch @@ -0,0 +1,86 @@ +diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admin/includes/class-wp-upgrader.php +--- wordpress/wp-admin/includes/class-wp-upgrader.php.nop 2013-12-11 20:49:11.000000000 +0100 ++++ wordpress/wp-admin/includes/class-wp-upgrader.php 2014-01-25 07:51:32.794892043 +0100 +@@ -1479,6 +1479,9 @@ class Core_Upgrader extends WP_Upgrader + } + } + ++ // RPM: nether allow core update ++ return false; ++ + // 1: If we're already on that version, not much point in updating? + if ( $offered_ver == $wp_version ) + return false; +@@ -1640,7 +1643,7 @@ class WP_Automatic_Updater { + */ + public function is_disabled() { + // Background updates are disabled if you don't want file changes. +- if ( defined( 'DISALLOW_FILE_MODS' ) && DISALLOW_FILE_MODS ) ++ if ( !defined( 'DISALLOW_FILE_MODS' ) || DISALLOW_FILE_MODS ) + return true; + + if ( defined( 'WP_INSTALLING' ) ) +diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/update.php +--- wordpress/wp-admin/includes/update.php.nop 2013-12-02 22:55:10.000000000 +0100 ++++ wordpress/wp-admin/includes/update.php 2014-01-25 07:48:42.202268342 +0100 +@@ -216,8 +216,6 @@ function update_nag() { + } + echo "
$msg
"; + } +-add_action( 'admin_notices', 'update_nag', 3 ); +-add_action( 'network_admin_notices', 'update_nag', 3 ); + + // Called directly from dashboard + function update_right_now_message() { +@@ -227,7 +225,7 @@ function update_right_now_message() { + $cur = get_preferred_from_update_core(); + + if ( isset( $cur->response ) && $cur->response == 'upgrade' ) +- $msg .= " " . sprintf( __('Update to %s'), $cur->current ? $cur->current : __( 'Latest' ) ) . ''; ++ $msg .= ''; + } + + echo "$msg"; +diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabilities.php +--- wordpress/wp-includes/capabilities.php.nop 2013-11-13 05:39:08.000000000 +0100 ++++ wordpress/wp-includes/capabilities.php 2014-01-25 07:48:42.202268342 +0100 +@@ -1251,7 +1251,7 @@ function map_meta_cap( $cap, $user_id ) + // Disallow the file editors. + if ( defined( 'DISALLOW_FILE_EDIT' ) && DISALLOW_FILE_EDIT ) + $caps[] = 'do_not_allow'; +- elseif ( defined( 'DISALLOW_FILE_MODS' ) && DISALLOW_FILE_MODS ) ++ elseif ( !defined( 'DISALLOW_FILE_MODS' ) || DISALLOW_FILE_MODS ) + $caps[] = 'do_not_allow'; + elseif ( is_multisite() && ! is_super_admin( $user_id ) ) + $caps[] = 'do_not_allow'; +@@ -1267,7 +1267,7 @@ function map_meta_cap( $cap, $user_id ) + case 'update_core': + // Disallow anything that creates, deletes, or updates core, plugin, or theme files. + // Files in uploads are excepted. +- if ( defined( 'DISALLOW_FILE_MODS' ) && DISALLOW_FILE_MODS ) ++ if ( !defined( 'DISALLOW_FILE_MODS' ) || DISALLOW_FILE_MODS ) + $caps[] = 'do_not_allow'; + elseif ( is_multisite() && ! is_super_admin( $user_id ) ) + $caps[] = 'do_not_allow'; +diff -up wordpress/wp-includes/update.php.nop wordpress/wp-includes/update.php +--- wordpress/wp-includes/update.php.nop 2013-11-15 04:04:10.000000000 +0100 ++++ wordpress/wp-includes/update.php 2014-01-25 07:48:42.202268342 +0100 +@@ -574,9 +574,6 @@ function _maybe_update_themes() { + * @since 3.1.0 + */ + function wp_schedule_update_checks() { +- if ( !wp_next_scheduled('wp_version_check') && !defined('WP_INSTALLING') ) +- wp_schedule_event(time(), 'twicedaily', 'wp_version_check'); +- + if ( !wp_next_scheduled('wp_update_plugins') && !defined('WP_INSTALLING') ) + wp_schedule_event(time(), 'twicedaily', 'wp_update_plugins'); + +@@ -602,8 +599,6 @@ if ( ( ! is_main_site() && ! is_network_ + return; + + add_action( 'admin_init', '_maybe_update_core' ); +-add_action( 'wp_version_check', 'wp_version_check' ); +-add_action( 'upgrader_process_complete', 'wp_version_check', 10, 0 ); + + add_action( 'load-plugins.php', 'wp_update_plugins' ); + add_action( 'load-update.php', 'wp_update_plugins' ); diff --git a/wordpress.spec b/wordpress.spec index eceea7c..fe80974 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -12,7 +12,7 @@ URL: http://www.wordpress.org Name: wordpress Version: 3.8.1 Group: Applications/Publishing -Release: 1%{?dist} +Release: 3%{?dist} License: GPLv2 Source0: http://wordpress.org/%{name}-%{version}.tar.gz @@ -36,6 +36,15 @@ Patch3: wordpress-3.6-tinymce_noflash.patch # changes 'plugins:["flash,"silverlight","youtube","vimeo"]' to # 'plugins:["youtube","vimeo"]' Patch4: wordpress-3.6-mediaelement-noflash_silverlight.patch +# RPM configuration: +# Path to installation +# Disable auto-updater +Patch5: wordpress-3.8.1-config.patch +# RPM are readonly +# disable version check and updated +# change DISALLOW_FILE_MODS default value to true +# ignore WP_AUTO_UPDATE_CORE (always false) +Patch6: wordpress-3.8.1-noupdate.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch @@ -118,31 +127,34 @@ rm -f wp-includes/js/plupload/plupload.flash.js rm -rf wp-includes/js/swfupload %patch0 -p1 -b .dolly -#%patch1 -p1 -b .rhbz522897 +#patch1 -p1 -b .rhbz522897 %patch2 -p1 %patch3 -p1 %patch4 -p1 -# disable wp_version_check, updates are always installed via rpm -sed -i -e "s,\(.*\)'wp_version_check'\(.*\),#\1'wp_version_check'\2,g" \ - wp-includes/update.php -# disable update_nag() function -sed -i -e "s,\(.*\)'update_nag'\(.*\),#\1'update_nag'\2,g; \ - s,\(.*\)\$msg .=\(.*\),\1\$msg .= '';,g;" \ - wp-admin/includes/update.php +# Create RPM configuration +cp wp-config-sample.php wp-config.php +%patch5 -p1 +%patch6 -p1 + # fix file encoding sed -i -e 's/\r//' license.txt + %build %install -mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/wordpress -mkdir -p ${RPM_BUILD_ROOT}%{_sysconfdir}/wordpress +# Apache configuration install -m 0644 -D -p %{SOURCE1} ${RPM_BUILD_ROOT}%{_sysconfdir}/httpd/conf.d/wordpress.conf + +# Application +mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/wordpress cp -pr * ${RPM_BUILD_ROOT}%{_datadir}/wordpress -cat wp-config-sample.php | sed -e "s|dirname(__FILE__).'/'|'/usr/share/wordpress/'|g" > \ - ${RPM_BUILD_ROOT}%{_sysconfdir}/wordpress/wp-config.php + +# Configuration +install -m 0644 -D wp-config.php ${RPM_BUILD_ROOT}%{_sysconfdir}/wordpress/wp-config.php /bin/ln -sf ../../../etc/wordpress/wp-config.php ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-config.php + /bin/cp %{SOURCE2} ./README.fedora /bin/cp %{SOURCE3} ./README.fedora-multiuser @@ -224,6 +236,14 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Sat Jan 25 2014 Remi Collet - 3.8.1-3 +- ignore WP_AUTO_UPDATE_CORE (always false) + +* Fri Jan 24 2014 Remi Collet - 3.8.1-2 +- comment provided configuration about auto-updater +- disable auto-updater on default configuration #1057521 +- switch some sed to patch (more robust) + * Thu Jan 23 2014 Adam Williamson - 3.8.1-1 - new upstream release 3.8.1 (bugfixes) From 96bb9b042943f7726b826578a0525d245ea68595 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 9 Apr 2014 16:47:16 +0200 Subject: [PATCH 06/20] update to 3.8.2 Security Release - fix privilege escalation issue CVE-2014-0165 - fix authentication bypass issue CVE-2014-0166 (cherry picked from commit 8bfaea7ed1ea22c4e73ae8fa7c98d36f336adb72) --- .gitignore | 1 + sources | 2 +- wordpress.spec | 9 +++++++-- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index fb01b80..eee2838 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ clog /wordpress-3.7.1.tar.gz /wordpress-3.8.tar.gz /wordpress-3.8.1.tar.gz +/wordpress-3.8.2.tar.gz diff --git a/sources b/sources index f55410e..d265090 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -6da5f73a2c7a46457b6ceb20fb6166c2 wordpress-3.8.1.tar.gz +436fecefe21b1d2df6beb1c201fc6426 wordpress-3.8.2.tar.gz diff --git a/wordpress.spec b/wordpress.spec index fe80974..4f91eb0 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -10,9 +10,9 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.8.1 +Version: 3.8.2 Group: Applications/Publishing -Release: 3%{?dist} +Release: 1%{?dist} License: GPLv2 Source0: http://wordpress.org/%{name}-%{version}.tar.gz @@ -236,6 +236,11 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Wed Apr 9 2014 Remi Collet - 3.8.2-1 +- update to 3.8.2 Security Release +- fix privilege escalation issue CVE-2014-0165 +- fix authentication bypass issue CVE-2014-0166 + * Sat Jan 25 2014 Remi Collet - 3.8.1-3 - ignore WP_AUTO_UPDATE_CORE (always false) From 37efc9598b68d25615946ff4b4802e92a56ffa9f Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 15 Apr 2014 13:26:08 +0200 Subject: [PATCH 07/20] update to 3.8.3 (cherry picked from commit 2f2b541a658bd208655a7479f843057853727e56) --- .gitignore | 1 + sources | 2 +- wordpress.spec | 6 +++++- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index eee2838..8662ae3 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ clog /wordpress-3.8.tar.gz /wordpress-3.8.1.tar.gz /wordpress-3.8.2.tar.gz +/wordpress-3.8.3.tar.gz diff --git a/sources b/sources index d265090..0000d7e 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -436fecefe21b1d2df6beb1c201fc6426 wordpress-3.8.2.tar.gz +90e9ec8a90e59322144737f30ef8799f wordpress-3.8.3.tar.gz diff --git a/wordpress.spec b/wordpress.spec index 4f91eb0..6ceaa69 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -10,7 +10,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.8.2 +Version: 3.8.3 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -236,6 +236,10 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Tue Apr 15 2014 Remi Collet - 3.8.3-1 +- update to 3.8.3 Maintenance Release + http://wordpress.org/news/2014/04/wordpress-3-8-3/ + * Wed Apr 9 2014 Remi Collet - 3.8.2-1 - update to 3.8.2 Security Release - fix privilege escalation issue CVE-2014-0165 From e557a56437d3f8a76aacf1342392555bbdf7d489 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Wed, 7 May 2014 17:45:55 +0200 Subject: [PATCH 08/20] =?UTF-8?q?=20update=20to=203.9=20=E2=80=9CSmith?= =?UTF-8?q?=E2=80=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit 74719500d2087b79b5fcaf0aa88b320643f6cb78) --- .gitignore | 1 + sources | 2 +- wordpress-3.6-tinymce_noflash.patch | 6 --- ...3.9-mediaelement-noflash_silverlight.patch | 12 ++--- ....patch => wordpress-3.9-no_swfupload.patch | 11 ++--- ...date.patch => wordpress-3.9-noupdate.patch | 32 +++++++------- wordpress-3.9-tinymce_noflash.patch | 22 ++++++++++ wordpress.spec | 44 ++++++++++++++----- 8 files changed, 84 insertions(+), 46 deletions(-) delete mode 100644 wordpress-3.6-tinymce_noflash.patch rename wordpress-3.6-mediaelement-noflash_silverlight.patch => wordpress-3.9-mediaelement-noflash_silverlight.patch (67%) rename wordpress-3.6-no_swfupload.patch => wordpress-3.9-no_swfupload.patch (72%) rename wordpress-3.8.1-noupdate.patch => wordpress-3.9-noupdate.patch (72%) create mode 100644 wordpress-3.9-tinymce_noflash.patch diff --git a/.gitignore b/.gitignore index 8662ae3..4b3fcfe 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,4 @@ clog /wordpress-3.8.1.tar.gz /wordpress-3.8.2.tar.gz /wordpress-3.8.3.tar.gz +/wordpress-3.9.tar.gz diff --git a/sources b/sources index 0000d7e..287b682 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -90e9ec8a90e59322144737f30ef8799f wordpress-3.8.3.tar.gz +d0b0396e84942faf87ccde819df0916f wordpress-3.9.tar.gz diff --git a/wordpress-3.6-tinymce_noflash.patch b/wordpress-3.6-tinymce_noflash.patch deleted file mode 100644 index a5d0a7f..0000000 --- a/wordpress-3.6-tinymce_noflash.patch +++ /dev/null @@ -1,6 +0,0 @@ ---- wordpress/wp-includes/js/tinymce/plugins/media/editor_plugin.js 2012-07-07 09:22:53.000000000 -0700 -+++ wordpress/wp-includes/js/tinymce/plugins/media/editor_plugin.js.new 2013-08-23 11:57:22.032012144 -0700 -@@ -1 +1 @@ --(function(){var b=tinymce.explode("id,name,width,height,style,align,class,hspace,vspace,bgcolor,type"),a=tinymce.makeMap(b.join(",")),f=tinymce.html.Node,d,i,h=tinymce.util.JSON,g;d=[["Flash","d27cdb6e-ae6d-11cf-96b8-444553540000","application/x-shockwave-flash","http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"],["ShockWave","166b1bca-3f9c-11cf-8075-444553540000","application/x-director","http://download.macromedia.com/pub/shockwave/cabs/director/sw.cab#version=8,5,1,0"],["WindowsMedia","6bf52a52-394a-11d3-b153-00c04f79faa6,22d6f312-b0f6-11d0-94ab-0080c74c7e95,05589fa1-c356-11ce-bf01-00aa0055595a","application/x-mplayer2","http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701"],["QuickTime","02bf25d5-8c17-4b23-bc80-d3488abddc6b","video/quicktime","http://www.apple.com/qtactivex/qtplugin.cab#version=6,0,2,0"],["RealMedia","cfcdaa03-8be4-11cf-b84b-0020afbbccfa","audio/x-pn-realaudio-plugin","http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"],["Java","8ad9c840-044e-11d1-b3e9-00805f499d93","application/x-java-applet","http://java.sun.com/products/plugin/autodl/jinstall-1_5_0-windows-i586.cab#Version=1,5,0,0"],["Silverlight","dfeaf541-f3e1-4c24-acac-99c30715084a","application/x-silverlight-2"],["Iframe"],["Video"],["EmbeddedAudio"],["Audio"]];function e(j){return typeof(j)=="string"?j.replace(/[^0-9%]/g,""):j}function c(m){var l,j,k;if(m&&!m.splice){j=[];for(k=0;true;k++){if(m[k]){j[k]=m[k]}else{break}}return j}return m}tinymce.create("tinymce.plugins.MediaPlugin",{init:function(n,j){var r=this,l={},m,p,q,k;function o(s){return s&&s.nodeName==="IMG"&&n.dom.hasClass(s,"mceItemMedia")}r.editor=n;r.url=j;i="";for(m=0;m0){O+=(O?"&":"")+P+"="+escape(Q)}});if(O.length){G.params.flashvars=O}L=p.getParam("flash_video_player_params",{allowfullscreen:true,allowscriptaccess:true});tinymce.each(L,function(Q,P){G.params[P]=""+Q})}}G=z.attr("data-mce-json");if(!G){return}G=h.parse(G);q=this.getType(z.attr("class"));B=z.attr("data-mce-style");if(!B){B=z.attr("style");if(B){B=p.dom.serializeStyle(p.dom.parseStyle(B,"img"))}}G.width=z.attr("width")||G.width;G.height=z.attr("height")||G.height;if(q.name==="Iframe"){x=new f("iframe",1);tinymce.each(b,function(n){var J=z.attr(n);if(n=="class"&&J){J=J.replace(/mceItem.+ ?/g,"")}if(J&&J.length>0){x.attr(n,J)}});for(I in G.params){x.attr(I,G.params[I])}x.attr({style:B,src:G.params.src});z.replace(x);return}if(this.editor.settings.media_use_script){x=new f("script",1).attr("type","text/javascript");y=new f("#text",3);y.value="write"+q.name+"("+h.serialize(tinymce.extend(G.params,{width:z.attr("width"),height:z.attr("height")}))+");";x.append(y);z.replace(x);return}if(q.name==="Video"&&G.video.sources[0]){C=new f("video",1).attr(tinymce.extend({id:z.attr("id"),width:e(z.attr("width")),height:e(z.attr("height")),style:B},G.video.attrs));if(G.video.attrs){l=G.video.attrs.poster}k=G.video.sources=c(G.video.sources);for(A=0;A0){O+=(O?"&":"")+P+"="+escape(Q)}});if(O.length){G.params.flashvars=O}L=p.getParam("flash_video_player_params",{allowfullscreen:true,allowscriptaccess:true});tinymce.each(L,function(Q,P){G.params[P]=""+Q})}}G=z.attr("data-mce-json");if(!G){return}G=h.parse(G);q=this.getType(z.attr("class"));B=z.attr("data-mce-style");if(!B){B=z.attr("style");if(B){B=p.dom.serializeStyle(p.dom.parseStyle(B,"img"))}}G.width=z.attr("width")||G.width;G.height=z.attr("height")||G.height;if(q.name==="Iframe"){x=new f("iframe",1);tinymce.each(b,function(n){var J=z.attr(n);if(n=="class"&&J){J=J.replace(/mceItem.+ ?/g,"")}if(J&&J.length>0){x.attr(n,J)}});for(I in G.params){x.attr(I,G.params[I])}x.attr({style:B,src:G.params.src});z.replace(x);return}if(this.editor.settings.media_use_script){x=new f("script",1).attr("type","text/javascript");y=new f("#text",3);y.value="write"+q.name+"("+h.serialize(tinymce.extend(G.params,{width:z.attr("width"),height:z.attr("height")}))+");";x.append(y);z.replace(x);return}if(q.name==="Video"&&G.video.sources[0]){C=new f("video",1).attr(tinymce.extend({id:z.attr("id"),width:e(z.attr("width")),height:e(z.attr("height")),style:B},G.video.attrs));if(G.video.attrs){l=G.video.attrs.poster}k=G.video.sources=c(G.video.sources);for(A=0;Aadd( 'wp-plupload', "/wp-includes/js/plupload/wp-plupload$suffix.js", array('plupload-all', 'jquery', 'json2', 'media-models'), false, 1 ); +diff -up wordpress/wp-includes/script-loader.php.orig wordpress/wp-includes/script-loader.php +--- wordpress/wp-includes/script-loader.php.orig 2014-05-07 15:55:26.485228222 +0200 ++++ wordpress/wp-includes/script-loader.php 2014-05-07 15:55:18.019198073 +0200 +@@ -278,15 +278,6 @@ function wp_default_scripts( &$scripts ) + $scripts->add( 'wp-plupload', "/wp-includes/js/plupload/wp-plupload$suffix.js", array( 'plupload', 'jquery', 'json2', 'media-models' ), false, 1 ); did_action( 'init' ) && $scripts->localize( 'wp-plupload', 'pluploadL10n', $uploader_l10n ); - // keep 'swfupload' for back-compat. @@ -13,6 +14,6 @@ - $scripts->add( 'swfupload-handlers', "/wp-includes/js/swfupload/handlers$suffix.js", array('swfupload-all', 'jquery'), '2201-20110524'); - did_action( 'init' ) && $scripts->localize( 'swfupload-handlers', 'swfuploadL10n', $uploader_l10n ); - - $scripts->add( 'comment-reply', "/wp-includes/js/comment-reply$suffix.js" ); + $scripts->add( 'comment-reply', "/wp-includes/js/comment-reply$suffix.js", array(), false, 1 ); $scripts->add( 'json2', "/wp-includes/js/json2$suffix.js", array(), '2011-02-23'); diff --git a/wordpress-3.8.1-noupdate.patch b/wordpress-3.9-noupdate.patch similarity index 72% rename from wordpress-3.8.1-noupdate.patch rename to wordpress-3.9-noupdate.patch index c2b2f6f..e72d370 100644 --- a/wordpress-3.8.1-noupdate.patch +++ b/wordpress-3.9-noupdate.patch @@ -1,7 +1,7 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admin/includes/class-wp-upgrader.php ---- wordpress/wp-admin/includes/class-wp-upgrader.php.nop 2013-12-11 20:49:11.000000000 +0100 -+++ wordpress/wp-admin/includes/class-wp-upgrader.php 2014-01-25 07:51:32.794892043 +0100 -@@ -1479,6 +1479,9 @@ class Core_Upgrader extends WP_Upgrader +--- wordpress/wp-admin/includes/class-wp-upgrader.php.nop 2014-04-15 12:57:14.000000000 +0200 ++++ wordpress/wp-admin/includes/class-wp-upgrader.php 2014-05-07 17:25:04.434588696 +0200 +@@ -1546,6 +1546,9 @@ class Core_Upgrader extends WP_Upgrader } } @@ -11,7 +11,7 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admi // 1: If we're already on that version, not much point in updating? if ( $offered_ver == $wp_version ) return false; -@@ -1640,7 +1643,7 @@ class WP_Automatic_Updater { +@@ -1734,7 +1737,7 @@ class WP_Automatic_Updater { */ public function is_disabled() { // Background updates are disabled if you don't want file changes. @@ -21,8 +21,8 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admi if ( defined( 'WP_INSTALLING' ) ) diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/update.php ---- wordpress/wp-admin/includes/update.php.nop 2013-12-02 22:55:10.000000000 +0100 -+++ wordpress/wp-admin/includes/update.php 2014-01-25 07:48:42.202268342 +0100 +--- wordpress/wp-admin/includes/update.php.nop 2014-04-16 02:38:14.000000000 +0200 ++++ wordpress/wp-admin/includes/update.php 2014-05-07 17:26:14.139840288 +0200 @@ -216,8 +216,6 @@ function update_nag() { } echo "
$msg
"; @@ -32,7 +32,7 @@ diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/ // Called directly from dashboard function update_right_now_message() { -@@ -227,7 +225,7 @@ function update_right_now_message() { +@@ -232,7 +230,7 @@ function update_right_now_message() { $cur = get_preferred_from_update_core(); if ( isset( $cur->response ) && $cur->response == 'upgrade' ) @@ -40,11 +40,11 @@ diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/ + $msg .= ''; } - echo "$msg"; + echo "

$msg

"; diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabilities.php ---- wordpress/wp-includes/capabilities.php.nop 2013-11-13 05:39:08.000000000 +0100 -+++ wordpress/wp-includes/capabilities.php 2014-01-25 07:48:42.202268342 +0100 -@@ -1251,7 +1251,7 @@ function map_meta_cap( $cap, $user_id ) +--- wordpress/wp-includes/capabilities.php.nop 2014-03-04 04:09:15.000000000 +0100 ++++ wordpress/wp-includes/capabilities.php 2014-05-07 17:25:04.434588696 +0200 +@@ -1238,7 +1238,7 @@ function map_meta_cap( $cap, $user_id ) // Disallow the file editors. if ( defined( 'DISALLOW_FILE_EDIT' ) && DISALLOW_FILE_EDIT ) $caps[] = 'do_not_allow'; @@ -53,7 +53,7 @@ diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabi $caps[] = 'do_not_allow'; elseif ( is_multisite() && ! is_super_admin( $user_id ) ) $caps[] = 'do_not_allow'; -@@ -1267,7 +1267,7 @@ function map_meta_cap( $cap, $user_id ) +@@ -1254,7 +1254,7 @@ function map_meta_cap( $cap, $user_id ) case 'update_core': // Disallow anything that creates, deletes, or updates core, plugin, or theme files. // Files in uploads are excepted. @@ -63,9 +63,9 @@ diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabi elseif ( is_multisite() && ! is_super_admin( $user_id ) ) $caps[] = 'do_not_allow'; diff -up wordpress/wp-includes/update.php.nop wordpress/wp-includes/update.php ---- wordpress/wp-includes/update.php.nop 2013-11-15 04:04:10.000000000 +0100 -+++ wordpress/wp-includes/update.php 2014-01-25 07:48:42.202268342 +0100 -@@ -574,9 +574,6 @@ function _maybe_update_themes() { +--- wordpress/wp-includes/update.php.nop 2014-04-16 02:38:14.000000000 +0200 ++++ wordpress/wp-includes/update.php 2014-05-07 17:25:04.435588699 +0200 +@@ -602,9 +602,6 @@ function _maybe_update_themes() { * @since 3.1.0 */ function wp_schedule_update_checks() { @@ -75,7 +75,7 @@ diff -up wordpress/wp-includes/update.php.nop wordpress/wp-includes/update.php if ( !wp_next_scheduled('wp_update_plugins') && !defined('WP_INSTALLING') ) wp_schedule_event(time(), 'twicedaily', 'wp_update_plugins'); -@@ -602,8 +599,6 @@ if ( ( ! is_main_site() && ! is_network_ +@@ -630,8 +627,6 @@ if ( ( ! is_main_site() && ! is_network_ return; add_action( 'admin_init', '_maybe_update_core' ); diff --git a/wordpress-3.9-tinymce_noflash.patch b/wordpress-3.9-tinymce_noflash.patch new file mode 100644 index 0000000..ab974d0 --- /dev/null +++ b/wordpress-3.9-tinymce_noflash.patch @@ -0,0 +1,22 @@ +--- wordpress/wp-includes/js/tinymce/plugins/media/plugin.js.old 2014-05-07 17:03:41.009962331 +0200 ++++ wordpress/wp-includes/js/tinymce/plugins/media/plugin.js 2014-05-07 17:04:08.549061421 +0200 +@@ -41,10 +41,6 @@ + return 'video/ogg'; + } + +- if (url.indexOf('.swf') != -1) { +- return 'application/x-shockwave-flash'; +- } +- + return ''; + } + +@@ -198,7 +194,7 @@ + data.source1mime = guessMime(data.source1); + data.source2mime = guessMime(data.source2); + data.poster = editor.convertURL(data.poster, "poster"); +- data.flashPlayerUrl = editor.convertURL(url + '/moxieplayer.swf', "movie"); ++ data.flashPlayerUrl = false; + + if (data.embed) { + html = updateHtml(data.embed, data, true); diff --git a/wordpress.spec b/wordpress.spec index 6ceaa69..dfd39a5 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -10,7 +10,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.8.3 +Version: 3.9 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -27,15 +27,15 @@ Patch0: wordpress-debian_patches_hello.patch # This patch doesn’t work well, see bugzilla.redhat.com/522897 Patch1: wordpress-move-wp-content.patch # Drop swfupload: not built from source, not reasonably possible to do -Patch2: wordpress-3.6-no_swfupload.patch +Patch2: wordpress-3.9-no_swfupload.patch # Adjust tinymce's media plugin not to use its SWF plugin. This changes # 'p.getParam("flash_video_player_url",u.convertUrl(u.url+"/moxieplayer.swf"))' # to 'false' -Patch3: wordpress-3.6-tinymce_noflash.patch +Patch3: wordpress-3.9-tinymce_noflash.patch # Adjust mediaelement not to use its SWF and Silverlight plugins. This # changes 'plugins:["flash,"silverlight","youtube","vimeo"]' to # 'plugins:["youtube","vimeo"]' -Patch4: wordpress-3.6-mediaelement-noflash_silverlight.patch +Patch4: wordpress-3.9-mediaelement-noflash_silverlight.patch # RPM configuration: # Path to installation # Disable auto-updater @@ -44,7 +44,7 @@ Patch5: wordpress-3.8.1-config.patch # disable version check and updated # change DISALLOW_FILE_MODS default value to true # ignore WP_AUTO_UPDATE_CORE (always false) -Patch6: wordpress-3.8.1-noupdate.patch +Patch6: wordpress-3.9-noupdate.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch @@ -115,13 +115,11 @@ Important information in %{_pkgdocdir}/README.fedora # and draw a non-functional button. - AdamW, 2013/08 # https://fedoraproject.org/wiki/Packaging:Guidelines#No_inclusion_of_pre-built_binaries_or_libraries -rm -f wp-includes/js/mediaelement/silverlightmediaelement.xap -rm -f wp-includes/js/mediaelement/flashmediaelement.sw -rm -f wp-includes/js/tinymce/plugins/media/moxieplayer.swf -rm -f wp-includes/js/plupload/plupload.silverlight.xap -rm -f wp-includes/js/plupload/plupload.silverlight.js -rm -f wp-includes/js/plupload/plupload.flash.swf -rm -f wp-includes/js/plupload/plupload.flash.js +rm wp-includes/js/mediaelement/silverlightmediaelement.xap +rm wp-includes/js/mediaelement/flashmediaelement.swf +rm wp-includes/js/tinymce/plugins/media/moxieplayer.swf +rm wp-includes/js/plupload/plupload.silverlight.xap +rm wp-includes/js/plupload/plupload.flash.swf # swfupload can just die in its entirety rm -rf wp-includes/js/swfupload @@ -132,6 +130,25 @@ rm -rf wp-includes/js/swfupload %patch3 -p1 %patch4 -p1 +# We patch a .js file, used patched file instead of unpatch minified one +ln -sf plugin.js wp-includes/js/tinymce/plugins/media/plugin.min.js + +# Re-Generated the archive +arc=wp-includes/js/tinymce/wp-tinymce.js +gunzip -dc $arc.gz | \ + grep "^// Source" | \ + while read a b c +do + if [ -f $c ]; then + echo -e "\n$a $b $c" + cat $c + else + exit 1 + fi +done >$arc +gzip --force $arc +ls -l $arc.gz + # Create RPM configuration cp wp-config-sample.php wp-config.php %patch5 -p1 @@ -236,6 +253,9 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Wed May 7 2014 Remi Collet - 3.9-1 +- update to 3.9 “Smith” + * Tue Apr 15 2014 Remi Collet - 3.8.3-1 - update to 3.8.3 Maintenance Release http://wordpress.org/news/2014/04/wordpress-3-8-3/ From 4c0b235aace87ffc3299f304a0c38888ae1b14cd Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 9 May 2014 06:44:41 +0200 Subject: [PATCH 09/20] update to 3.9.1 (cherry picked from commit 1e632fae73ad7c69e0eb463cf34d70fe40a643de) --- .gitignore | 1 + sources | 2 +- wordpress.spec | 5 ++++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 4b3fcfe..76fb94e 100644 --- a/.gitignore +++ b/.gitignore @@ -7,3 +7,4 @@ clog /wordpress-3.8.2.tar.gz /wordpress-3.8.3.tar.gz /wordpress-3.9.tar.gz +/wordpress-3.9.1.tar.gz diff --git a/sources b/sources index 287b682..c975915 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -d0b0396e84942faf87ccde819df0916f wordpress-3.9.tar.gz +46e303b587ba3d1f951b348d2c477c3c wordpress-3.9.1.tar.gz diff --git a/wordpress.spec b/wordpress.spec index dfd39a5..3673112 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -10,7 +10,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.9 +Version: 3.9.1 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -253,6 +253,9 @@ rm -rf ${RPM_BUILD_ROOT} %dir %{_sysconfdir}/wordpress %changelog +* Fri May 9 2014 Remi Collet - 3.9.1-1 +- update to 3.9.1 Maintenance Release + * Wed May 7 2014 Remi Collet - 3.9-1 - update to 3.9 “Smith” From cde8ef064571ecf99e9451eaaa17f723e61ce285 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 7 Aug 2014 16:46:49 +0200 Subject: [PATCH 10/20] - update to 3.9.2 Security Release #1127547 - config file only readable by apache user (httpd or php-fpm) #1124582 --- .gitignore | 1 + sources | 2 +- wordpress.spec | 15 +++++++++++---- 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index 76fb94e..6009756 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ clog /wordpress-3.8.3.tar.gz /wordpress-3.9.tar.gz /wordpress-3.9.1.tar.gz +/wordpress-3.9.2.tar.gz diff --git a/sources b/sources index c975915..448899a 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -46e303b587ba3d1f951b348d2c477c3c wordpress-3.9.1.tar.gz +c942a75d659b801195e53bcbd4770f31 wordpress-3.9.2.tar.gz diff --git a/wordpress.spec b/wordpress.spec index 3673112..15a0bb2 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -10,9 +10,9 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.9.1 +Version: 3.9.2 Group: Applications/Publishing -Release: 1%{?dist} +Release: 2%{?dist} License: GPLv2 Source0: http://wordpress.org/%{name}-%{version}.tar.gz @@ -85,7 +85,7 @@ Requires: php-zip Requires: php-zlib # Unbundled libraries Requires: php-PHPMailer -Requires: webserver +Requires: httpd %if %{with_cacert} Requires: ca-certificates %endif @@ -124,6 +124,9 @@ rm wp-includes/js/plupload/plupload.flash.swf # swfupload can just die in its entirety rm -rf wp-includes/js/swfupload +# remove .htaccess, protected by httpd config file +rm wp-content/plugins/akismet/.htaccess + %patch0 -p1 -b .dolly #patch1 -p1 -b .rhbz522897 %patch2 -p1 @@ -248,11 +251,15 @@ rm -rf ${RPM_BUILD_ROOT} %doc README.fedora %doc README.fedora-multiuser %{_datadir}/wordpress/wp-*.php -%config(noreplace) %{_sysconfdir}/wordpress/wp-config.php +%attr(640,root,apache) %config(noreplace) %{_sysconfdir}/wordpress/wp-config.php %{_datadir}/wordpress/xmlrpc.php %dir %{_sysconfdir}/wordpress %changelog +* Thu Aug 7 2014 Remi Collet - 3.9.2-1 +- update to 3.9.2 Security Release #1127547 +- config file only readable by apache user (httpd or php-fpm) #1124582 + * Fri May 9 2014 Remi Collet - 3.9.1-1 - update to 3.9.1 Maintenance Release From f9a7cbb49e4dd70e58596bd1f31ecd6b360d1d00 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 8 Aug 2014 11:16:12 +0200 Subject: [PATCH 11/20] - config dir only readable by apache group, better fix for #1124582 - fix license handling (cherry picked from commit ebc8928969487eecce29e14d90f0e9ae08d0ec76) --- wordpress.spec | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/wordpress.spec b/wordpress.spec index 15a0bb2..74591bd 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -12,7 +12,7 @@ URL: http://www.wordpress.org Name: wordpress Version: 3.9.2 Group: Applications/Publishing -Release: 2%{?dist} +Release: 3%{?dist} License: GPLv2 Source0: http://wordpress.org/%{name}-%{version}.tar.gz @@ -246,17 +246,22 @@ rm -rf ${RPM_BUILD_ROOT} %dir %attr(0775,apache,ftp) %{wp_content}/uploads %{wp_content}/plugins/* %{wp_content}/themes/* -%doc license.txt +%{!?_licensedir:%global license %%doc} +%license license.txt %doc readme.html %doc README.fedora %doc README.fedora-multiuser %{_datadir}/wordpress/wp-*.php +%attr(750,root,apache) %dir %{_sysconfdir}/wordpress %attr(640,root,apache) %config(noreplace) %{_sysconfdir}/wordpress/wp-config.php %{_datadir}/wordpress/xmlrpc.php -%dir %{_sysconfdir}/wordpress %changelog -* Thu Aug 7 2014 Remi Collet - 3.9.2-1 +* Fri Aug 8 2014 Remi Collet - 3.9.2-3 +- config dir only readable by apache group, better fix for #1124582 +- fix license handling + +* Thu Aug 7 2014 Remi Collet - 3.9.2-2 - update to 3.9.2 Security Release #1127547 - config file only readable by apache user (httpd or php-fpm) #1124582 From 336abb403ce1ce20e9c1495f64efd249e5bd57c4 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 8 Sep 2014 13:34:42 +0200 Subject: [PATCH 12/20] =?UTF-8?q?update=20to=20WordPress=204.0=20=E2=80=9C?= =?UTF-8?q?Benny=E2=80=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit 00237e3af198bcf3c12726299dd7042569e130e1) --- .gitignore | 1 + sources | 2 +- wordpress-3.9-no_swfupload.patch | 2 +- ...config.patch => wordpress-4.0-config.patch | 12 ++++----- ...date.patch => wordpress-4.0-noupdate.patch | 26 +++++++++---------- ...tch => wordpress-4.0-tinymce_noflash.patch | 13 +++++----- wordpress.spec | 13 ++++++---- 7 files changed, 37 insertions(+), 32 deletions(-) rename wordpress-3.8.1-config.patch => wordpress-4.0-config.patch (72%) rename wordpress-3.9-noupdate.patch => wordpress-4.0-noupdate.patch (81%) rename wordpress-3.9-tinymce_noflash.patch => wordpress-4.0-tinymce_noflash.patch (50%) diff --git a/.gitignore b/.gitignore index 6009756..7e5bd23 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,4 @@ clog /wordpress-3.9.tar.gz /wordpress-3.9.1.tar.gz /wordpress-3.9.2.tar.gz +/wordpress-4.0.tar.gz diff --git a/sources b/sources index 448899a..291c56d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -c942a75d659b801195e53bcbd4770f31 wordpress-3.9.2.tar.gz +cf235297b802fe987e444759bf30c1db wordpress-4.0.tar.gz diff --git a/wordpress-3.9-no_swfupload.patch b/wordpress-3.9-no_swfupload.patch index 06f4180..3d1395d 100644 --- a/wordpress-3.9-no_swfupload.patch +++ b/wordpress-3.9-no_swfupload.patch @@ -1,7 +1,7 @@ diff -up wordpress/wp-includes/script-loader.php.orig wordpress/wp-includes/script-loader.php --- wordpress/wp-includes/script-loader.php.orig 2014-05-07 15:55:26.485228222 +0200 +++ wordpress/wp-includes/script-loader.php 2014-05-07 15:55:18.019198073 +0200 -@@ -278,15 +278,6 @@ function wp_default_scripts( &$scripts ) +@@ -273,15 +273,6 @@ function wp_default_scripts( &$scripts ) $scripts->add( 'wp-plupload', "/wp-includes/js/plupload/wp-plupload$suffix.js", array( 'plupload', 'jquery', 'json2', 'media-models' ), false, 1 ); did_action( 'init' ) && $scripts->localize( 'wp-plupload', 'pluploadL10n', $uploader_l10n ); diff --git a/wordpress-3.8.1-config.patch b/wordpress-4.0-config.patch similarity index 72% rename from wordpress-3.8.1-config.patch rename to wordpress-4.0-config.patch index 9f50f11..c2579b2 100644 --- a/wordpress-3.8.1-config.patch +++ b/wordpress-4.0-config.patch @@ -1,8 +1,8 @@ -diff -up wordpress/wp-config.php.old wordpress/wp-config.php ---- wordpress/wp-config.php.old 2014-01-25 07:47:17.622959116 +0100 -+++ wordpress/wp-config.php 2014-01-25 07:54:06.816454385 +0100 -@@ -72,6 +72,19 @@ $table_prefix = 'wp_'; - define('WPLANG', ''); +diff -up wordpress/wp-config.php.orig wordpress/wp-config.php +--- wordpress/wp-config.php.orig 2014-09-08 13:12:36.525908423 +0200 ++++ wordpress/wp-config.php 2014-09-08 13:14:33.583402525 +0200 +@@ -62,6 +62,19 @@ define('NONCE_SALT', 'put your uni + $table_prefix = 'wp_'; /** + * See http://make.wordpress.org/core/2013/10/25/the-definitive-guide-to-disabling-auto-updates-in-wordpress-3-7 @@ -21,7 +21,7 @@ diff -up wordpress/wp-config.php.old wordpress/wp-config.php * For developers: WordPress debugging mode. * * Change this to true to enable the display of notices during development. -@@ -84,7 +97,7 @@ define('WP_DEBUG', false); +@@ -74,7 +87,7 @@ define('WP_DEBUG', false); /** Absolute path to the WordPress directory. */ if ( !defined('ABSPATH') ) diff --git a/wordpress-3.9-noupdate.patch b/wordpress-4.0-noupdate.patch similarity index 81% rename from wordpress-3.9-noupdate.patch rename to wordpress-4.0-noupdate.patch index e72d370..2362efa 100644 --- a/wordpress-3.9-noupdate.patch +++ b/wordpress-4.0-noupdate.patch @@ -1,7 +1,7 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admin/includes/class-wp-upgrader.php --- wordpress/wp-admin/includes/class-wp-upgrader.php.nop 2014-04-15 12:57:14.000000000 +0200 +++ wordpress/wp-admin/includes/class-wp-upgrader.php 2014-05-07 17:25:04.434588696 +0200 -@@ -1546,6 +1546,9 @@ class Core_Upgrader extends WP_Upgrader +@@ -1618,6 +1618,9 @@ class Core_Upgrader extends WP_Upgrader } } @@ -11,7 +11,7 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admi // 1: If we're already on that version, not much point in updating? if ( $offered_ver == $wp_version ) return false; -@@ -1734,7 +1737,7 @@ class WP_Automatic_Updater { +@@ -1806,7 +1806,7 @@ class WP_Automatic_Updater { */ public function is_disabled() { // Background updates are disabled if you don't want file changes. @@ -23,7 +23,7 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admi diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/update.php --- wordpress/wp-admin/includes/update.php.nop 2014-04-16 02:38:14.000000000 +0200 +++ wordpress/wp-admin/includes/update.php 2014-05-07 17:26:14.139840288 +0200 -@@ -216,8 +216,6 @@ function update_nag() { +@@ -211,8 +211,6 @@ function update_nag() { } echo "
$msg
"; } @@ -32,7 +32,7 @@ diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/ // Called directly from dashboard function update_right_now_message() { -@@ -232,7 +230,7 @@ function update_right_now_message() { +@@ -227,7 +225,7 @@ function update_right_now_message() { $cur = get_preferred_from_update_core(); if ( isset( $cur->response ) && $cur->response == 'upgrade' ) @@ -42,9 +42,9 @@ diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/ echo "

$msg

"; diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabilities.php ---- wordpress/wp-includes/capabilities.php.nop 2014-03-04 04:09:15.000000000 +0100 -+++ wordpress/wp-includes/capabilities.php 2014-05-07 17:25:04.434588696 +0200 -@@ -1238,7 +1238,7 @@ function map_meta_cap( $cap, $user_id ) +--- wordpress/wp-includes/capabilities.php.orig 2014-08-27 03:32:18.000000000 +0200 ++++ wordpress/wp-includes/capabilities.php 2014-09-08 13:22:00.463291244 +0200 +@@ -1252,7 +1252,7 @@ // Disallow the file editors. if ( defined( 'DISALLOW_FILE_EDIT' ) && DISALLOW_FILE_EDIT ) $caps[] = 'do_not_allow'; @@ -53,19 +53,19 @@ diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabi $caps[] = 'do_not_allow'; elseif ( is_multisite() && ! is_super_admin( $user_id ) ) $caps[] = 'do_not_allow'; -@@ -1254,7 +1254,7 @@ function map_meta_cap( $cap, $user_id ) +@@ -1270,7 +1270,7 @@ case 'update_core': // Disallow anything that creates, deletes, or updates core, plugin, or theme files. // Files in uploads are excepted. -- if ( defined( 'DISALLOW_FILE_MODS' ) && DISALLOW_FILE_MODS ) -+ if ( !defined( 'DISALLOW_FILE_MODS' ) || DISALLOW_FILE_MODS ) +- if ( defined( 'DISALLOW_FILE_MODS' ) && DISALLOW_FILE_MODS ) { ++ if ( !defined( 'DISALLOW_FILE_MODS' ) || DISALLOW_FILE_MODS ) { $caps[] = 'do_not_allow'; - elseif ( is_multisite() && ! is_super_admin( $user_id ) ) + } elseif ( is_multisite() && ! is_super_admin( $user_id ) ) { $caps[] = 'do_not_allow'; diff -up wordpress/wp-includes/update.php.nop wordpress/wp-includes/update.php --- wordpress/wp-includes/update.php.nop 2014-04-16 02:38:14.000000000 +0200 +++ wordpress/wp-includes/update.php 2014-05-07 17:25:04.435588699 +0200 -@@ -602,9 +602,6 @@ function _maybe_update_themes() { +@@ -624,9 +624,6 @@ function _maybe_update_themes() { * @since 3.1.0 */ function wp_schedule_update_checks() { @@ -75,7 +75,7 @@ diff -up wordpress/wp-includes/update.php.nop wordpress/wp-includes/update.php if ( !wp_next_scheduled('wp_update_plugins') && !defined('WP_INSTALLING') ) wp_schedule_event(time(), 'twicedaily', 'wp_update_plugins'); -@@ -630,8 +627,6 @@ if ( ( ! is_main_site() && ! is_network_ +@@ -652,8 +649,6 @@ if ( ( ! is_main_site() && ! is_network_ return; add_action( 'admin_init', '_maybe_update_core' ); diff --git a/wordpress-3.9-tinymce_noflash.patch b/wordpress-4.0-tinymce_noflash.patch similarity index 50% rename from wordpress-3.9-tinymce_noflash.patch rename to wordpress-4.0-tinymce_noflash.patch index ab974d0..605df1c 100644 --- a/wordpress-3.9-tinymce_noflash.patch +++ b/wordpress-4.0-tinymce_noflash.patch @@ -1,6 +1,7 @@ ---- wordpress/wp-includes/js/tinymce/plugins/media/plugin.js.old 2014-05-07 17:03:41.009962331 +0200 -+++ wordpress/wp-includes/js/tinymce/plugins/media/plugin.js 2014-05-07 17:04:08.549061421 +0200 -@@ -41,10 +41,6 @@ +diff -up wordpress/wp-includes/js/tinymce/plugins/media/plugin.js.rpm wordpress/wp-includes/js/tinymce/plugins/media/plugin.js +--- wordpress/wp-includes/js/tinymce/plugins/media/plugin.js.rpm 2014-08-22 01:53:18.000000000 +0200 ++++ wordpress/wp-includes/js/tinymce/plugins/media/plugin.js 2014-09-08 13:10:15.717314458 +0200 +@@ -44,10 +44,6 @@ tinymce.PluginManager.add('media', funct return 'video/ogg'; } @@ -11,12 +12,12 @@ return ''; } -@@ -198,7 +194,7 @@ +@@ -239,7 +235,7 @@ tinymce.PluginManager.add('media', funct data.source1mime = guessMime(data.source1); data.source2mime = guessMime(data.source2); data.poster = editor.convertURL(data.poster, "poster"); - data.flashPlayerUrl = editor.convertURL(url + '/moxieplayer.swf', "movie"); + data.flashPlayerUrl = false; - if (data.embed) { - html = updateHtml(data.embed, data, true); + tinymce.each(urlPatterns, function(pattern) { + var match, i, url; diff --git a/wordpress.spec b/wordpress.spec index 74591bd..4dcf2a9 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -10,9 +10,9 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 3.9.2 +Version: 4.0 Group: Applications/Publishing -Release: 3%{?dist} +Release: 1%{?dist} License: GPLv2 Source0: http://wordpress.org/%{name}-%{version}.tar.gz @@ -31,7 +31,7 @@ Patch2: wordpress-3.9-no_swfupload.patch # Adjust tinymce's media plugin not to use its SWF plugin. This changes # 'p.getParam("flash_video_player_url",u.convertUrl(u.url+"/moxieplayer.swf"))' # to 'false' -Patch3: wordpress-3.9-tinymce_noflash.patch +Patch3: wordpress-4.0-tinymce_noflash.patch # Adjust mediaelement not to use its SWF and Silverlight plugins. This # changes 'plugins:["flash,"silverlight","youtube","vimeo"]' to # 'plugins:["youtube","vimeo"]' @@ -39,12 +39,12 @@ Patch4: wordpress-3.9-mediaelement-noflash_silverlight.patch # RPM configuration: # Path to installation # Disable auto-updater -Patch5: wordpress-3.8.1-config.patch +Patch5: wordpress-4.0-config.patch # RPM are readonly # disable version check and updated # change DISALLOW_FILE_MODS default value to true # ignore WP_AUTO_UPDATE_CORE (always false) -Patch6: wordpress-3.9-noupdate.patch +Patch6: wordpress-4.0-noupdate.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch @@ -257,6 +257,9 @@ rm -rf ${RPM_BUILD_ROOT} %{_datadir}/wordpress/xmlrpc.php %changelog +* Mon Sep 8 2014 Remi Collet - 4.0-1 +- WordPress 4.0 “Benny” + * Fri Aug 8 2014 Remi Collet - 3.9.2-3 - config dir only readable by apache group, better fix for #1124582 - fix license handling From ede7a540714a103d3bed8eb12a933847c8f82a29 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 21 Nov 2014 08:14:48 +0100 Subject: [PATCH 13/20] WordPress 4.0.1 Security Release --- .gitignore | 1 + sources | 2 +- wordpress-4.0-systemlibs.patch | 21 +++++++++++++++++++ wordpress.spec | 37 +++++++++++++++++++++++++++++----- 4 files changed, 55 insertions(+), 6 deletions(-) create mode 100644 wordpress-4.0-systemlibs.patch diff --git a/.gitignore b/.gitignore index 7e5bd23..525ff56 100644 --- a/.gitignore +++ b/.gitignore @@ -10,3 +10,4 @@ clog /wordpress-3.9.1.tar.gz /wordpress-3.9.2.tar.gz /wordpress-4.0.tar.gz +/wordpress-4.0.1.tar.gz diff --git a/sources b/sources index 291c56d..c7ce5b4 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -cf235297b802fe987e444759bf30c1db wordpress-4.0.tar.gz +531d9a4829fc40d81f5ee4a681f71f94 wordpress-4.0.1.tar.gz diff --git a/wordpress-4.0-systemlibs.patch b/wordpress-4.0-systemlibs.patch new file mode 100644 index 0000000..9d16ee6 --- /dev/null +++ b/wordpress-4.0-systemlibs.patch @@ -0,0 +1,21 @@ +diff -up wordpress/wp-admin/includes/media.php.old wordpress/wp-admin/includes/media.php +--- wordpress/wp-admin/includes/media.php.old 2014-09-30 08:54:21.666519693 +0200 ++++ wordpress/wp-admin/includes/media.php 2014-09-30 08:55:11.247757421 +0200 +@@ -2907,7 +2907,7 @@ function wp_read_video_metadata( $file ) + $metadata = array(); + + if ( ! class_exists( 'getID3' ) ) +- require( ABSPATH . WPINC . '/ID3/getid3.php' ); ++ require( '/usr/share/php/getid3/getid3.php' ); + $id3 = new getID3(); + $data = $id3->analyze( $file ); + +@@ -2962,7 +2962,7 @@ function wp_read_audio_metadata( $file ) + $metadata = array(); + + if ( ! class_exists( 'getID3' ) ) +- require( ABSPATH . WPINC . '/ID3/getid3.php' ); ++ require( '/usr/share/php/getid3/getid3.php' ); + $id3 = new getID3(); + $data = $id3->analyze( $file ); + diff --git a/wordpress.spec b/wordpress.spec index 4dcf2a9..7cef0d7 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -6,11 +6,17 @@ %else %global with_cacert 1 %endif +# https://bugzilla.redhat.com/1147817 php53-getid3 review +%if 0%{?fedora} >= 17 || 0%{?rhel} >= 6 +%global with_getid3 1 +%else +%global with_getid3 0 +%endif Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 4.0 +Version: 4.0.1 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -45,6 +51,8 @@ Patch5: wordpress-4.0-config.patch # change DISALLOW_FILE_MODS default value to true # ignore WP_AUTO_UPDATE_CORE (always false) Patch6: wordpress-4.0-noupdate.patch +# Use system libraries +Patch7: wordpress-4.0-systemlibs.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch @@ -52,9 +60,15 @@ BuildArch: noarch %if 0%{?rhel} == 5 Requires: php53 >= 5.2.4 Requires: php53-simplepie >= 1.3.1 +%if %{with_getid3} +Requires: php53-getid3 +%endif %else Requires: php >= 5.2.4 Requires: php-simplepie >= 1.3.1 +%if %{with_getid3} +Requires: php-getid3 +%endif %endif # From phpcompatinfo report for version 3.8 Requires: php-curl @@ -132,6 +146,9 @@ rm wp-content/plugins/akismet/.htaccess %patch2 -p1 %patch3 -p1 %patch4 -p1 +%if %{with_getid3} +%patch7 -p1 +%endif # We patch a .js file, used patched file instead of unpatch minified one ln -sf plugin.js wp-includes/js/tinymce/plugins/media/plugin.min.js @@ -187,12 +204,12 @@ find ${RPM_BUILD_ROOT} -type f -empty -exec rm -vf {} \; rm -f ${RPM_BUILD_ROOT}%{_datadir}/wordpress/{license.txt,readme.html} # Remove bundled php-simplepie and link to system copy -rm ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/class-simplepie.php -rm -rf ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/SimplePie +rm ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/class-simplepie.php +rm -r ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/SimplePie %if 0%{?rhel} == 5 -ln -sf /usr/share/php/php53-simplepie/autoloader.php \ +ln -s /usr/share/php/php53-simplepie/autoloader.php \ %else -ln -sf /usr/share/php/php-simplepie/autoloader.php \ +ln -s /usr/share/php/php-simplepie/autoloader.php \ %endif ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/class-simplepie.php @@ -204,6 +221,11 @@ for fic in phpmailer smtp; do ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/class-$fic.php done +%if %{with_getid3} +# Remove bundled php-getid3 +rm -r ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/ID3 +%endif + # Remove bundled ca-bundle.crt %if %{with_cacert} rm ${RPM_BUILD_ROOT}%{_datadir}/wordpress/wp-includes/certificates/ca-bundle.crt @@ -228,6 +250,7 @@ find ${RPM_BUILD_ROOT} \( -name \*.dolly -o -name \*.rhbz522897 -o -name \*.orig #/sbin/restorecon -R %{_localstatedir}/www/wordpress/ #fi + %clean rm -rf ${RPM_BUILD_ROOT} @@ -257,6 +280,10 @@ rm -rf ${RPM_BUILD_ROOT} %{_datadir}/wordpress/xmlrpc.php %changelog +* Fri Nov 21 2014 Remi Collet - 4.0.1-1 +- WordPress 4.0.1 Security Release +- use system php-getid3 when available #1145574 + * Mon Sep 8 2014 Remi Collet - 4.0-1 - WordPress 4.0 “Benny” From 729299f123f65c8a554188f0db514b2d1700d656 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Mon, 22 Dec 2014 07:01:01 +0100 Subject: [PATCH 14/20] update to 4.1 (cherry picked from commit cdc67b2be093b1023a7367f3a2a96587cb9b21a4) --- .gitignore | 1 + sources | 2 +- ...3.9-mediaelement-noflash_silverlight.patch | 11 ------ ...4.1-mediaelement-noflash_silverlight.patch | 11 ++++++ ...date.patch => wordpress-4.1-noupdate.patch | 38 +++++++++---------- wordpress.spec | 9 +++-- 6 files changed, 38 insertions(+), 34 deletions(-) delete mode 100644 wordpress-3.9-mediaelement-noflash_silverlight.patch create mode 100644 wordpress-4.1-mediaelement-noflash_silverlight.patch rename wordpress-4.0-noupdate.patch => wordpress-4.1-noupdate.patch (68%) diff --git a/.gitignore b/.gitignore index 525ff56..db9fba7 100644 --- a/.gitignore +++ b/.gitignore @@ -11,3 +11,4 @@ clog /wordpress-3.9.2.tar.gz /wordpress-4.0.tar.gz /wordpress-4.0.1.tar.gz +/wordpress-4.1.tar.gz diff --git a/sources b/sources index c7ce5b4..9f84c78 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -531d9a4829fc40d81f5ee4a681f71f94 wordpress-4.0.1.tar.gz +5adac1bfc61b793a1ca9bcb4d67b4d28 wordpress-4.1.tar.gz diff --git a/wordpress-3.9-mediaelement-noflash_silverlight.patch b/wordpress-3.9-mediaelement-noflash_silverlight.patch deleted file mode 100644 index 0404236..0000000 --- a/wordpress-3.9-mediaelement-noflash_silverlight.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- wordpress/wp-includes/js/mediaelement/mediaelement-and-player.min.js.orig 2014-05-07 17:16:34.465747946 +0200 -+++ wordpress/wp-includes/js/mediaelement/mediaelement-and-player.min.js 2014-05-07 17:21:09.213739591 +0200 -@@ -39,7 +39,7 @@ - mejs.MediaPluginBridge.unregisterPluginElement(this.pluginElement.id)}}; - mejs.MediaPluginBridge={pluginMediaElements:{},htmlMediaElements:{},registerPluginElement:function(a,b,c){this.pluginMediaElements[a]=b;this.htmlMediaElements[a]=c},unregisterPluginElement:function(a){delete this.pluginMediaElements[a];delete this.htmlMediaElements[a]},initPlugin:function(a){var b=this.pluginMediaElements[a],c=this.htmlMediaElements[a];if(b){switch(b.pluginType){case "flash":b.pluginElement=b.pluginApi=document.getElementById(a);break;case "silverlight":b.pluginElement=document.getElementById(b.id); - b.pluginApi=b.pluginElement.Content.MediaElementJS}b.pluginApi!=null&&b.success&&b.success(b,c)}},fireEvent:function(a,b,c){var d,e;if(a=this.pluginMediaElements[a]){b={type:b,target:a};for(d in c){a[d]=c[d];b[d]=c[d]}e=c.bufferedTime||0;b.target.buffered=b.buffered={start:function(){return 0},end:function(){return e},length:1};a.dispatchEvent(b.type,b)}}}; --mejs.MediaElementDefaults={mode:"auto",plugins:["flash","silverlight","youtube","vimeo"],enablePluginDebug:false,httpsBasicAuthSite:false,type:"",pluginPath:mejs.Utility.getScriptPath(["mediaelement.js","mediaelement.min.js","mediaelement-and-player.js","mediaelement-and-player.min.js"]),flashName:"flashmediaelement.swf",flashStreamer:"",enablePluginSmoothing:false,enablePseudoStreaming:false,pseudoStreamingStartQueryParam:"start",silverlightName:"silverlightmediaelement.xap",defaultVideoWidth:480, -+mejs.MediaElementDefaults={mode:"auto",plugins:["youtube","vimeo"],enablePluginDebug:false,httpsBasicAuthSite:false,type:"",pluginPath:mejs.Utility.getScriptPath(["mediaelement.js","mediaelement.min.js","mediaelement-and-player.js","mediaelement-and-player.min.js"]),flashName:"flashmediaelement.swf",flashStreamer:"",enablePluginSmoothing:false,enablePseudoStreaming:false,pseudoStreamingStartQueryParam:"start",silverlightName:"silverlightmediaelement.xap",defaultVideoWidth:480, - defaultVideoHeight:270,pluginWidth:-1,pluginHeight:-1,pluginVars:[],timerRate:250,startVolume:0.8,success:function(){},error:function(){}};mejs.MediaElement=function(a,b){return mejs.HtmlMediaElementShim.create(a,b)}; - mejs.HtmlMediaElementShim={create:function(a,b){var c=mejs.MediaElementDefaults,d=typeof a=="string"?document.getElementById(a):a,e=d.tagName.toLowerCase(),g=e==="audio"||e==="video",f=g?d.getAttribute("src"):d.getAttribute("href");e=d.getAttribute("poster");var i=d.getAttribute("autoplay"),k=d.getAttribute("preload"),h=d.getAttribute("controls"),j;for(j in b)c[j]=b[j];f=typeof f=="undefined"||f===null||f==""?null:f;e=typeof e=="undefined"||e===null?"":e;k=typeof k=="undefined"||k===null||k==="false"? - "none":k;i=!(typeof i=="undefined"||i===null||i==="false");h=!(typeof h=="undefined"||h===null||h==="false");j=this.determinePlayback(d,c,mejs.MediaFeatures.supportsMediaTag,g,f);j.url=j.url!==null?mejs.Utility.absolutizeUrl(j.url):"";if(j.method=="native"){if(mejs.MediaFeatures.isBustedAndroid){d.src=j.url;d.addEventListener("click",function(){d.play()},false)}return this.updateNative(j,c,i,k)}else if(j.method!=="")return this.createPlugin(j,c,e,i,k,h);else{this.createErrorMessage(j,c,e);return this}}, diff --git a/wordpress-4.1-mediaelement-noflash_silverlight.patch b/wordpress-4.1-mediaelement-noflash_silverlight.patch new file mode 100644 index 0000000..125eec4 --- /dev/null +++ b/wordpress-4.1-mediaelement-noflash_silverlight.patch @@ -0,0 +1,11 @@ +--- wordpress/wp-includes/js/mediaelement/mediaelement-and-player.min.js.orig 2014-12-22 06:38:12.716225091 +0100 ++++ wordpress/wp-includes/js/mediaelement/mediaelement-and-player.min.js 2014-12-22 06:39:30.045517161 +0100 +@@ -12,7 +12,7 @@ + * License: MIT + * + */ +-function onYouTubePlayerAPIReady(){mejs.YouTubeApi.iFrameReady()}function onYouTubePlayerReady(a){mejs.YouTubeApi.flashReady(a)}var mejs=mejs||{};mejs.version="2.16.2",mejs.meIndex=0,mejs.plugins={silverlight:[{version:[3,0],types:["video/mp4","video/m4v","video/mov","video/wmv","audio/wma","audio/m4a","audio/mp3","audio/wav","audio/mpeg"]}],flash:[{version:[9,0,124],types:["video/mp4","video/m4v","video/mov","video/flv","video/rtmp","video/x-flv","audio/flv","audio/x-flv","audio/mp3","audio/m4a","audio/mpeg","video/youtube","video/x-youtube","application/x-mpegURL"]}],youtube:[{version:null,types:["video/youtube","video/x-youtube","audio/youtube","audio/x-youtube"]}],vimeo:[{version:null,types:["video/vimeo","video/x-vimeo"]}]},mejs.Utility={encodeUrl:function(a){return encodeURIComponent(a)},escapeHTML:function(a){return a.toString().split("&").join("&").split("<").join("<").split('"').join(""")},absolutizeUrl:function(a){var b=document.createElement("div");return b.innerHTML='x',b.firstChild.href},getScriptPath:function(a){for(var b,c,d,e,f,g,h=0,i="",j="",k=document.getElementsByTagName("script"),l=k.length,m=a.length;l>h;h++){for(e=k[h].src,c=e.lastIndexOf("/"),c>-1?(g=e.substring(c+1),f=e.substring(0,c+1)):(g=e,f=""),b=0;m>b;b++)if(j=a[b],d=g.indexOf(j),d>-1){i=f;break}if(""!==i)break}return i},secondsToTimeCode:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=Math.floor(a/3600)%24,f=Math.floor(a/60)%60,g=Math.floor(a%60),h=Math.floor((a%1*d).toFixed(3)),i=(b||e>0?(10>e?"0"+e:e)+":":"")+(10>f?"0"+f:f)+":"+(10>g?"0"+g:g)+(c?":"+(10>h?"0"+h:h):"");return i},timeCodeToSeconds:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=a.split(":"),f=parseInt(e[0],10),g=parseInt(e[1],10),h=parseInt(e[2],10),i=0,j=0;return c&&(i=parseInt(e[3])/d),j=3600*f+60*g+h+i},convertSMPTEtoSeconds:function(a){if("string"!=typeof a)return!1;a=a.replace(",",".");var b=0,c=-1!=a.indexOf(".")?a.split(".")[1].length:0,d=1;a=a.split(":").reverse();for(var e=0;e0&&(d=Math.pow(60,e)),b+=Number(a[e])*d;return Number(b.toFixed(c))},removeSwf:function(a){var b=document.getElementById(a);b&&/object|embed/i.test(b.nodeName)&&(mejs.MediaFeatures.isIE?(b.style.display="none",function(){4==b.readyState?mejs.Utility.removeObjectInIE(a):setTimeout(arguments.callee,10)}()):b.parentNode.removeChild(b))},removeObjectInIE:function(a){var b=document.getElementById(a);if(b){for(var c in b)"function"==typeof b[c]&&(b[c]=null);b.parentNode.removeChild(b)}}},mejs.PluginDetector={hasPluginVersion:function(a,b){var c=this.plugins[a];return b[1]=b[1]||0,b[2]=b[2]||0,c[0]>b[0]||c[0]==b[0]&&c[1]>b[1]||c[0]==b[0]&&c[1]==b[1]&&c[2]>=b[2]?!0:!1},nav:window.navigator,ua:window.navigator.userAgent.toLowerCase(),plugins:[],addPlugin:function(a,b,c,d,e){this.plugins[a]=this.detectPlugin(b,c,d,e)},detectPlugin:function(a,b,c,d){var e,f,g,h=[0,0,0];if("undefined"!=typeof this.nav.plugins&&"object"==typeof this.nav.plugins[a]){if(e=this.nav.plugins[a].description,e&&("undefined"==typeof this.nav.mimeTypes||!this.nav.mimeTypes[b]||this.nav.mimeTypes[b].enabledPlugin))for(h=e.replace(a,"").replace(/^\s+/,"").replace(/\sr/gi,".").split("."),f=0;f0;)this.removeChild(b[0]);if("string"==typeof a)this.src=a;else{var c,d;for(c=0;c0&&null!==q[0].url&&this.getTypeFromFile(q[0].url).indexOf("audio")>-1&&(r.isVideo=!1),mejs.MediaFeatures.isBustedAndroid&&(a.canPlayType=function(a){return null!==a.match(/video\/(mp4|m4v)/gi)?"maybe":""}),!(!c||"auto"!==b.mode&&"auto_plugin"!==b.mode&&"native"!==b.mode||mejs.MediaFeatures.isBustedNativeHTTPS&&b.httpsBasicAuthSite===!0)){for(d||(o=document.createElement(r.isVideo?"video":"audio"),a.parentNode.insertBefore(o,a),a.style.display="none",r.htmlMediaElement=a=o),f=0;f0&&(r.url=q[0].url),r)},formatType:function(a,b){return a&&!b?this.getTypeFromFile(a):b&&~b.indexOf(";")?b.substr(0,b.indexOf(";")):b},getTypeFromFile:function(a){a=a.split("?")[0];var b=a.substring(a.lastIndexOf(".")+1).toLowerCase();return(/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video":"audio")+"/"+this.getTypeFromExtension(b)},getTypeFromExtension:function(a){switch(a){case"mp4":case"m4v":case"m4a":return"mp4";case"webm":case"webma":case"webmv":return"webm";case"ogg":case"oga":case"ogv":return"ogg";default:return a}},createErrorMessage:function(a,b,c){var d=a.htmlMediaElement,e=document.createElement("div");e.className="me-cannotplay";try{e.style.width=d.width+"px",e.style.height=d.height+"px"}catch(f){}e.innerHTML=b.customError?b.customError:""!==c?'':''+mejs.i18n.t("Download File")+"",d.parentNode.insertBefore(e,d),d.style.display="none",b.error(d)},createPlugin:function(a,b,c,d,e,f){var g,h,i,j=a.htmlMediaElement,k=1,l=1,m="me_"+a.method+"_"+mejs.meIndex++,n=new mejs.PluginMediaElement(m,a.method,a.url),o=document.createElement("div");n.tagName=j.tagName;for(var p=0;p0?b.pluginWidth:b.videoWidth>0?b.videoWidth:null!==j.getAttribute("width")?j.getAttribute("width"):b.defaultVideoWidth,l=b.pluginHeight>0?b.pluginHeight:b.videoHeight>0?b.videoHeight:null!==j.getAttribute("height")?j.getAttribute("height"):b.defaultVideoHeight,k=mejs.Utility.encodeUrl(k),l=mejs.Utility.encodeUrl(l)):b.enablePluginDebug&&(k=320,l=240),n.success=b.success,mejs.MediaPluginBridge.registerPluginElement(m,n,j),o.className="me-plugin",o.id=m+"_container",a.isVideo?j.parentNode.insertBefore(o,j):document.body.insertBefore(o,document.body.childNodes[0]),i=["id="+m,"isvideo="+(a.isVideo?"true":"false"),"autoplay="+(d?"true":"false"),"preload="+e,"width="+k,"startvolume="+b.startVolume,"timerrate="+b.timerRate,"flashstreamer="+b.flashStreamer,"height="+l,"pseudostreamstart="+b.pseudoStreamingStartQueryParam],null!==a.url&&i.push("flash"==a.method?"file="+mejs.Utility.encodeUrl(a.url):"file="+a.url),b.enablePluginDebug&&i.push("debug=true"),b.enablePluginSmoothing&&i.push("smoothing=true"),b.enablePseudoStreaming&&i.push("pseudostreaming=true"),f&&i.push("controls=true"),b.pluginVars&&(i=i.concat(b.pluginVars)),a.method){case"silverlight":o.innerHTML='';break;case"flash":mejs.MediaFeatures.isIE?(g=document.createElement("div"),o.appendChild(g),g.outerHTML=''):o.innerHTML='';break;case"youtube":var r;-1!=a.url.lastIndexOf("youtu.be")?(r=a.url.substr(a.url.lastIndexOf("/")+1),-1!=r.indexOf("?")&&(r=r.substr(0,r.indexOf("?")))):r=a.url.substr(a.url.lastIndexOf("=")+1),youtubeSettings={container:o,containerId:o.id,pluginMediaElement:n,pluginId:m,videoId:r,height:l,width:k},mejs.PluginDetector.hasPluginVersion("flash",[10,0,0])?mejs.YouTubeApi.createFlash(youtubeSettings):mejs.YouTubeApi.enqueueIframe(youtubeSettings);break;case"vimeo":var s=m+"_player";if(n.vimeoid=a.url.substr(a.url.lastIndexOf("/")+1),o.innerHTML='',"function"==typeof $f){var t=$f(o.childNodes[0]);t.addEvent("ready",function(){function a(a,b,c,d){var e={type:c,target:b};"timeupdate"==c&&(b.currentTime=e.currentTime=d.seconds,b.duration=e.duration=d.duration),b.dispatchEvent(e.type,e)}$.extend(t,{playVideo:function(){t.api("play")},stopVideo:function(){t.api("unload")},pauseVideo:function(){t.api("pause")},seekTo:function(a){t.api("seekTo",a)},setVolume:function(a){t.api("setVolume",a)},setMuted:function(a){a?(t.lastVolume=t.api("getVolume"),t.api("setVolume",0)):(t.api("setVolume",t.lastVolume),delete t.lastVolume)}}),t.addEvent("play",function(){a(t,n,"play"),a(t,n,"playing")}),t.addEvent("pause",function(){a(t,n,"pause")}),t.addEvent("finish",function(){a(t,n,"ended")}),t.addEvent("playProgress",function(b){a(t,n,"timeupdate",b)}),n.pluginElement=o,n.pluginApi=t,mejs.MediaPluginBridge.initPlugin(m)})}else console.warn("You need to include froogaloop for vimeo to work")}return j.style.display="none",j.removeAttribute("autoplay"),n},updateNative:function(a,b){var c,d=a.htmlMediaElement;for(c in mejs.HtmlMediaElement)d[c]=mejs.HtmlMediaElement[c];return b.success(d,d),d}},mejs.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(){if(!this.isIframeStarted){var a=document.createElement("script");a.src="//www.youtube.com/player_api";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(),this.iframeQueue.push(a))},createIframe:function(a){var b=a.pluginMediaElement,c=new YT.Player(a.containerId,{height:a.height,width:a.width,videoId:a.videoId,playerVars:{controls:0},events:{onReady:function(){a.pluginMediaElement.pluginApi=c,mejs.MediaPluginBridge.initPlugin(a.pluginId),setInterval(function(){mejs.YouTubeApi.createEvent(c,b,"timeupdate")},250)},onStateChange:function(a){mejs.YouTubeApi.handleStateChange(a.data,c,b)}}})},createEvent:function(a,b,c){var d={type:c,target:b};if(a&&a.getDuration){b.currentTime=d.currentTime=a.getCurrentTime(),b.duration=d.duration=a.getDuration(),d.paused=b.paused,d.ended=b.ended,d.muted=a.isMuted(),d.volume=a.getVolume()/100,d.bytesTotal=a.getVideoBytesTotal(),d.bufferedBytes=a.getVideoBytesLoaded();var e=d.bufferedBytes/d.bytesTotal*d.duration;d.target.buffered=d.buffered={start:function(){return 0},end:function(){return e},length:1}}b.dispatchEvent(d.type,d)},iFrameReady:function(){for(this.isLoaded=!0,this.isIframeLoaded=!0;this.iframeQueue.length>0;){var a=this.iframeQueue.pop();this.createIframe(a)}},flashPlayers:{},createFlash:function(a){this.flashPlayers[a.pluginId]=a;var b,c="//www.youtube.com/apiplayer?enablejsapi=1&playerapiid="+a.pluginId+"&version=3&autoplay=0&controls=0&modestbranding=1&loop=0";mejs.MediaFeatures.isIE?(b=document.createElement("div"),a.container.appendChild(b),b.outerHTML=''):a.container.innerHTML=''},flashReady:function(a){var b=this.flashPlayers[a],c=document.getElementById(a),d=b.pluginMediaElement;d.pluginApi=d.pluginElement=c,mejs.MediaPluginBridge.initPlugin(a),c.cueVideoById(b.videoId);var e=b.containerId+"_callback";window[e]=function(a){mejs.YouTubeApi.handleStateChange(a,c,d)},c.addEventListener("onStateChange",e),setInterval(function(){mejs.YouTubeApi.createEvent(c,d,"timeupdate")},250),mejs.YouTubeApi.createEvent(c,d,"canplay")},handleStateChange:function(a,b,c){switch(a){case-1:c.paused=!0,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"loadedmetadata");break;case 0:c.paused=!1,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"ended");break;case 1:c.paused=!1,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"play"),mejs.YouTubeApi.createEvent(b,c,"playing");break;case 2:c.paused=!0,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"pause");break;case 3:mejs.YouTubeApi.createEvent(b,c,"progress");break;case 5:}}},window.mejs=mejs,window.MediaElement=mejs.MediaElement,function(a,b){"use strict";var c={locale:{language:b.i18n&&b.i18n.locale.language||"",strings:b.i18n&&b.i18n.locale.strings||{}},ietf_lang_regex:/^(x\-)?[a-z]{2,}(\-\w{2,})?(\-\w{2,})?$/,methods:{}};c.getLanguage=function(){var a=c.locale.language||window.navigator.userLanguage||window.navigator.language;return c.ietf_lang_regex.exec(a)?a:null},"undefined"!=typeof mejsL10n&&(c.locale.language=mejsL10n.language),c.methods.checkPlain=function(a){var b,c,d={"&":"&",'"':""","<":"<",">":">"};a=String(a);for(b in d)d.hasOwnProperty(b)&&(c=new RegExp(b,"g"),a=a.replace(c,d[b]));return a},c.methods.t=function(a,b){return c.locale.strings&&c.locale.strings[b.context]&&c.locale.strings[b.context][a]&&(a=c.locale.strings[b.context][a]),c.methods.checkPlain(a)},c.t=function(a,b){if("string"==typeof a&&a.length>0){var d=c.getLanguage();return b=b||{context:d},c.methods.t(a,b)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=c}(document,mejs),function(a){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(mejs.i18n.locale.strings),/*! ++function onYouTubePlayerAPIReady(){mejs.YouTubeApi.iFrameReady()}function onYouTubePlayerReady(a){mejs.YouTubeApi.flashReady(a)}var mejs=mejs||{};mejs.version="2.16.2",mejs.meIndex=0,mejs.plugins={silverlight:[{version:[3,0],types:["video/mp4","video/m4v","video/mov","video/wmv","audio/wma","audio/m4a","audio/mp3","audio/wav","audio/mpeg"]}],flash:[{version:[9,0,124],types:["video/mp4","video/m4v","video/mov","video/flv","video/rtmp","video/x-flv","audio/flv","audio/x-flv","audio/mp3","audio/m4a","audio/mpeg","video/youtube","video/x-youtube","application/x-mpegURL"]}],youtube:[{version:null,types:["video/youtube","video/x-youtube","audio/youtube","audio/x-youtube"]}],vimeo:[{version:null,types:["video/vimeo","video/x-vimeo"]}]},mejs.Utility={encodeUrl:function(a){return encodeURIComponent(a)},escapeHTML:function(a){return a.toString().split("&").join("&").split("<").join("<").split('"').join(""")},absolutizeUrl:function(a){var b=document.createElement("div");return b.innerHTML='x',b.firstChild.href},getScriptPath:function(a){for(var b,c,d,e,f,g,h=0,i="",j="",k=document.getElementsByTagName("script"),l=k.length,m=a.length;l>h;h++){for(e=k[h].src,c=e.lastIndexOf("/"),c>-1?(g=e.substring(c+1),f=e.substring(0,c+1)):(g=e,f=""),b=0;m>b;b++)if(j=a[b],d=g.indexOf(j),d>-1){i=f;break}if(""!==i)break}return i},secondsToTimeCode:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=Math.floor(a/3600)%24,f=Math.floor(a/60)%60,g=Math.floor(a%60),h=Math.floor((a%1*d).toFixed(3)),i=(b||e>0?(10>e?"0"+e:e)+":":"")+(10>f?"0"+f:f)+":"+(10>g?"0"+g:g)+(c?":"+(10>h?"0"+h:h):"");return i},timeCodeToSeconds:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=a.split(":"),f=parseInt(e[0],10),g=parseInt(e[1],10),h=parseInt(e[2],10),i=0,j=0;return c&&(i=parseInt(e[3])/d),j=3600*f+60*g+h+i},convertSMPTEtoSeconds:function(a){if("string"!=typeof a)return!1;a=a.replace(",",".");var b=0,c=-1!=a.indexOf(".")?a.split(".")[1].length:0,d=1;a=a.split(":").reverse();for(var e=0;e0&&(d=Math.pow(60,e)),b+=Number(a[e])*d;return Number(b.toFixed(c))},removeSwf:function(a){var b=document.getElementById(a);b&&/object|embed/i.test(b.nodeName)&&(mejs.MediaFeatures.isIE?(b.style.display="none",function(){4==b.readyState?mejs.Utility.removeObjectInIE(a):setTimeout(arguments.callee,10)}()):b.parentNode.removeChild(b))},removeObjectInIE:function(a){var b=document.getElementById(a);if(b){for(var c in b)"function"==typeof b[c]&&(b[c]=null);b.parentNode.removeChild(b)}}},mejs.PluginDetector={hasPluginVersion:function(a,b){var c=this.plugins[a];return b[1]=b[1]||0,b[2]=b[2]||0,c[0]>b[0]||c[0]==b[0]&&c[1]>b[1]||c[0]==b[0]&&c[1]==b[1]&&c[2]>=b[2]?!0:!1},nav:window.navigator,ua:window.navigator.userAgent.toLowerCase(),plugins:[],addPlugin:function(a,b,c,d,e){this.plugins[a]=this.detectPlugin(b,c,d,e)},detectPlugin:function(a,b,c,d){var e,f,g,h=[0,0,0];if("undefined"!=typeof this.nav.plugins&&"object"==typeof this.nav.plugins[a]){if(e=this.nav.plugins[a].description,e&&("undefined"==typeof this.nav.mimeTypes||!this.nav.mimeTypes[b]||this.nav.mimeTypes[b].enabledPlugin))for(h=e.replace(a,"").replace(/^\s+/,"").replace(/\sr/gi,".").split("."),f=0;f0;)this.removeChild(b[0]);if("string"==typeof a)this.src=a;else{var c,d;for(c=0;c0&&null!==q[0].url&&this.getTypeFromFile(q[0].url).indexOf("audio")>-1&&(r.isVideo=!1),mejs.MediaFeatures.isBustedAndroid&&(a.canPlayType=function(a){return null!==a.match(/video\/(mp4|m4v)/gi)?"maybe":""}),!(!c||"auto"!==b.mode&&"auto_plugin"!==b.mode&&"native"!==b.mode||mejs.MediaFeatures.isBustedNativeHTTPS&&b.httpsBasicAuthSite===!0)){for(d||(o=document.createElement(r.isVideo?"video":"audio"),a.parentNode.insertBefore(o,a),a.style.display="none",r.htmlMediaElement=a=o),f=0;f0&&(r.url=q[0].url),r)},formatType:function(a,b){return a&&!b?this.getTypeFromFile(a):b&&~b.indexOf(";")?b.substr(0,b.indexOf(";")):b},getTypeFromFile:function(a){a=a.split("?")[0];var b=a.substring(a.lastIndexOf(".")+1).toLowerCase();return(/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video":"audio")+"/"+this.getTypeFromExtension(b)},getTypeFromExtension:function(a){switch(a){case"mp4":case"m4v":case"m4a":return"mp4";case"webm":case"webma":case"webmv":return"webm";case"ogg":case"oga":case"ogv":return"ogg";default:return a}},createErrorMessage:function(a,b,c){var d=a.htmlMediaElement,e=document.createElement("div");e.className="me-cannotplay";try{e.style.width=d.width+"px",e.style.height=d.height+"px"}catch(f){}e.innerHTML=b.customError?b.customError:""!==c?'':''+mejs.i18n.t("Download File")+"",d.parentNode.insertBefore(e,d),d.style.display="none",b.error(d)},createPlugin:function(a,b,c,d,e,f){var g,h,i,j=a.htmlMediaElement,k=1,l=1,m="me_"+a.method+"_"+mejs.meIndex++,n=new mejs.PluginMediaElement(m,a.method,a.url),o=document.createElement("div");n.tagName=j.tagName;for(var p=0;p0?b.pluginWidth:b.videoWidth>0?b.videoWidth:null!==j.getAttribute("width")?j.getAttribute("width"):b.defaultVideoWidth,l=b.pluginHeight>0?b.pluginHeight:b.videoHeight>0?b.videoHeight:null!==j.getAttribute("height")?j.getAttribute("height"):b.defaultVideoHeight,k=mejs.Utility.encodeUrl(k),l=mejs.Utility.encodeUrl(l)):b.enablePluginDebug&&(k=320,l=240),n.success=b.success,mejs.MediaPluginBridge.registerPluginElement(m,n,j),o.className="me-plugin",o.id=m+"_container",a.isVideo?j.parentNode.insertBefore(o,j):document.body.insertBefore(o,document.body.childNodes[0]),i=["id="+m,"isvideo="+(a.isVideo?"true":"false"),"autoplay="+(d?"true":"false"),"preload="+e,"width="+k,"startvolume="+b.startVolume,"timerrate="+b.timerRate,"flashstreamer="+b.flashStreamer,"height="+l,"pseudostreamstart="+b.pseudoStreamingStartQueryParam],null!==a.url&&i.push("flash"==a.method?"file="+mejs.Utility.encodeUrl(a.url):"file="+a.url),b.enablePluginDebug&&i.push("debug=true"),b.enablePluginSmoothing&&i.push("smoothing=true"),b.enablePseudoStreaming&&i.push("pseudostreaming=true"),f&&i.push("controls=true"),b.pluginVars&&(i=i.concat(b.pluginVars)),a.method){case"silverlight":o.innerHTML='';break;case"flash":mejs.MediaFeatures.isIE?(g=document.createElement("div"),o.appendChild(g),g.outerHTML=''):o.innerHTML='';break;case"youtube":var r;-1!=a.url.lastIndexOf("youtu.be")?(r=a.url.substr(a.url.lastIndexOf("/")+1),-1!=r.indexOf("?")&&(r=r.substr(0,r.indexOf("?")))):r=a.url.substr(a.url.lastIndexOf("=")+1),youtubeSettings={container:o,containerId:o.id,pluginMediaElement:n,pluginId:m,videoId:r,height:l,width:k},mejs.PluginDetector.hasPluginVersion("flash",[10,0,0])?mejs.YouTubeApi.createFlash(youtubeSettings):mejs.YouTubeApi.enqueueIframe(youtubeSettings);break;case"vimeo":var s=m+"_player";if(n.vimeoid=a.url.substr(a.url.lastIndexOf("/")+1),o.innerHTML='',"function"==typeof $f){var t=$f(o.childNodes[0]);t.addEvent("ready",function(){function a(a,b,c,d){var e={type:c,target:b};"timeupdate"==c&&(b.currentTime=e.currentTime=d.seconds,b.duration=e.duration=d.duration),b.dispatchEvent(e.type,e)}$.extend(t,{playVideo:function(){t.api("play")},stopVideo:function(){t.api("unload")},pauseVideo:function(){t.api("pause")},seekTo:function(a){t.api("seekTo",a)},setVolume:function(a){t.api("setVolume",a)},setMuted:function(a){a?(t.lastVolume=t.api("getVolume"),t.api("setVolume",0)):(t.api("setVolume",t.lastVolume),delete t.lastVolume)}}),t.addEvent("play",function(){a(t,n,"play"),a(t,n,"playing")}),t.addEvent("pause",function(){a(t,n,"pause")}),t.addEvent("finish",function(){a(t,n,"ended")}),t.addEvent("playProgress",function(b){a(t,n,"timeupdate",b)}),n.pluginElement=o,n.pluginApi=t,mejs.MediaPluginBridge.initPlugin(m)})}else console.warn("You need to include froogaloop for vimeo to work")}return j.style.display="none",j.removeAttribute("autoplay"),n},updateNative:function(a,b){var c,d=a.htmlMediaElement;for(c in mejs.HtmlMediaElement)d[c]=mejs.HtmlMediaElement[c];return b.success(d,d),d}},mejs.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(){if(!this.isIframeStarted){var a=document.createElement("script");a.src="//www.youtube.com/player_api";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(),this.iframeQueue.push(a))},createIframe:function(a){var b=a.pluginMediaElement,c=new YT.Player(a.containerId,{height:a.height,width:a.width,videoId:a.videoId,playerVars:{controls:0},events:{onReady:function(){a.pluginMediaElement.pluginApi=c,mejs.MediaPluginBridge.initPlugin(a.pluginId),setInterval(function(){mejs.YouTubeApi.createEvent(c,b,"timeupdate")},250)},onStateChange:function(a){mejs.YouTubeApi.handleStateChange(a.data,c,b)}}})},createEvent:function(a,b,c){var d={type:c,target:b};if(a&&a.getDuration){b.currentTime=d.currentTime=a.getCurrentTime(),b.duration=d.duration=a.getDuration(),d.paused=b.paused,d.ended=b.ended,d.muted=a.isMuted(),d.volume=a.getVolume()/100,d.bytesTotal=a.getVideoBytesTotal(),d.bufferedBytes=a.getVideoBytesLoaded();var e=d.bufferedBytes/d.bytesTotal*d.duration;d.target.buffered=d.buffered={start:function(){return 0},end:function(){return e},length:1}}b.dispatchEvent(d.type,d)},iFrameReady:function(){for(this.isLoaded=!0,this.isIframeLoaded=!0;this.iframeQueue.length>0;){var a=this.iframeQueue.pop();this.createIframe(a)}},flashPlayers:{},createFlash:function(a){this.flashPlayers[a.pluginId]=a;var b,c="//www.youtube.com/apiplayer?enablejsapi=1&playerapiid="+a.pluginId+"&version=3&autoplay=0&controls=0&modestbranding=1&loop=0";mejs.MediaFeatures.isIE?(b=document.createElement("div"),a.container.appendChild(b),b.outerHTML=''):a.container.innerHTML=''},flashReady:function(a){var b=this.flashPlayers[a],c=document.getElementById(a),d=b.pluginMediaElement;d.pluginApi=d.pluginElement=c,mejs.MediaPluginBridge.initPlugin(a),c.cueVideoById(b.videoId);var e=b.containerId+"_callback";window[e]=function(a){mejs.YouTubeApi.handleStateChange(a,c,d)},c.addEventListener("onStateChange",e),setInterval(function(){mejs.YouTubeApi.createEvent(c,d,"timeupdate")},250),mejs.YouTubeApi.createEvent(c,d,"canplay")},handleStateChange:function(a,b,c){switch(a){case-1:c.paused=!0,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"loadedmetadata");break;case 0:c.paused=!1,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"ended");break;case 1:c.paused=!1,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"play"),mejs.YouTubeApi.createEvent(b,c,"playing");break;case 2:c.paused=!0,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"pause");break;case 3:mejs.YouTubeApi.createEvent(b,c,"progress");break;case 5:}}},window.mejs=mejs,window.MediaElement=mejs.MediaElement,function(a,b){"use strict";var c={locale:{language:b.i18n&&b.i18n.locale.language||"",strings:b.i18n&&b.i18n.locale.strings||{}},ietf_lang_regex:/^(x\-)?[a-z]{2,}(\-\w{2,})?(\-\w{2,})?$/,methods:{}};c.getLanguage=function(){var a=c.locale.language||window.navigator.userLanguage||window.navigator.language;return c.ietf_lang_regex.exec(a)?a:null},"undefined"!=typeof mejsL10n&&(c.locale.language=mejsL10n.language),c.methods.checkPlain=function(a){var b,c,d={"&":"&",'"':""","<":"<",">":">"};a=String(a);for(b in d)d.hasOwnProperty(b)&&(c=new RegExp(b,"g"),a=a.replace(c,d[b]));return a},c.methods.t=function(a,b){return c.locale.strings&&c.locale.strings[b.context]&&c.locale.strings[b.context][a]&&(a=c.locale.strings[b.context][a]),c.methods.checkPlain(a)},c.t=function(a,b){if("string"==typeof a&&a.length>0){var d=c.getLanguage();return b=b||{context:d},c.methods.t(a,b)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=c}(document,mejs),function(a){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(mejs.i18n.locale.strings),/*! + * + * MediaElementPlayer + * http://mediaelementjs.com/ diff --git a/wordpress-4.0-noupdate.patch b/wordpress-4.1-noupdate.patch similarity index 68% rename from wordpress-4.0-noupdate.patch rename to wordpress-4.1-noupdate.patch index 2362efa..9578b76 100644 --- a/wordpress-4.0-noupdate.patch +++ b/wordpress-4.1-noupdate.patch @@ -1,7 +1,7 @@ -diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admin/includes/class-wp-upgrader.php ---- wordpress/wp-admin/includes/class-wp-upgrader.php.nop 2014-04-15 12:57:14.000000000 +0200 -+++ wordpress/wp-admin/includes/class-wp-upgrader.php 2014-05-07 17:25:04.434588696 +0200 -@@ -1618,6 +1618,9 @@ class Core_Upgrader extends WP_Upgrader +diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.rpm wordpress/wp-admin/includes/class-wp-upgrader.php +--- wordpress/wp-admin/includes/class-wp-upgrader.php.rpm 2014-12-16 20:54:23.000000000 +0100 ++++ wordpress/wp-admin/includes/class-wp-upgrader.php 2014-12-22 06:46:28.487097611 +0100 +@@ -2141,6 +2141,9 @@ class Core_Upgrader extends WP_Upgrader } } @@ -11,7 +11,7 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admi // 1: If we're already on that version, not much point in updating? if ( $offered_ver == $wp_version ) return false; -@@ -1806,7 +1806,7 @@ class WP_Automatic_Updater { +@@ -2372,7 +2375,7 @@ class WP_Automatic_Updater { */ public function is_disabled() { // Background updates are disabled if you don't want file changes. @@ -20,9 +20,9 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.nop wordpress/wp-admi return true; if ( defined( 'WP_INSTALLING' ) ) -diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/update.php ---- wordpress/wp-admin/includes/update.php.nop 2014-04-16 02:38:14.000000000 +0200 -+++ wordpress/wp-admin/includes/update.php 2014-05-07 17:26:14.139840288 +0200 +diff -up wordpress/wp-admin/includes/update.php.rpm wordpress/wp-admin/includes/update.php +--- wordpress/wp-admin/includes/update.php.rpm 2014-11-30 12:28:24.000000000 +0100 ++++ wordpress/wp-admin/includes/update.php 2014-12-22 06:46:28.487097611 +0100 @@ -211,8 +211,6 @@ function update_nag() { } echo "
$msg
"; @@ -41,10 +41,10 @@ diff -up wordpress/wp-admin/includes/update.php.nop wordpress/wp-admin/includes/ } echo "

$msg

"; -diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabilities.php ---- wordpress/wp-includes/capabilities.php.orig 2014-08-27 03:32:18.000000000 +0200 -+++ wordpress/wp-includes/capabilities.php 2014-09-08 13:22:00.463291244 +0200 -@@ -1252,7 +1252,7 @@ +diff -up wordpress/wp-includes/capabilities.php.rpm wordpress/wp-includes/capabilities.php +--- wordpress/wp-includes/capabilities.php.rpm 2014-12-01 02:34:24.000000000 +0100 ++++ wordpress/wp-includes/capabilities.php 2014-12-22 06:46:28.487097611 +0100 +@@ -1255,7 +1255,7 @@ function map_meta_cap( $cap, $user_id ) // Disallow the file editors. if ( defined( 'DISALLOW_FILE_EDIT' ) && DISALLOW_FILE_EDIT ) $caps[] = 'do_not_allow'; @@ -53,7 +53,7 @@ diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabi $caps[] = 'do_not_allow'; elseif ( is_multisite() && ! is_super_admin( $user_id ) ) $caps[] = 'do_not_allow'; -@@ -1270,7 +1270,7 @@ +@@ -1273,7 +1273,7 @@ function map_meta_cap( $cap, $user_id ) case 'update_core': // Disallow anything that creates, deletes, or updates core, plugin, or theme files. // Files in uploads are excepted. @@ -62,10 +62,10 @@ diff -up wordpress/wp-includes/capabilities.php.nop wordpress/wp-includes/capabi $caps[] = 'do_not_allow'; } elseif ( is_multisite() && ! is_super_admin( $user_id ) ) { $caps[] = 'do_not_allow'; -diff -up wordpress/wp-includes/update.php.nop wordpress/wp-includes/update.php ---- wordpress/wp-includes/update.php.nop 2014-04-16 02:38:14.000000000 +0200 -+++ wordpress/wp-includes/update.php 2014-05-07 17:25:04.435588699 +0200 -@@ -624,9 +624,6 @@ function _maybe_update_themes() { +diff -up wordpress/wp-includes/update.php.rpm wordpress/wp-includes/update.php +--- wordpress/wp-includes/update.php.rpm 2014-12-22 06:48:34.883575009 +0100 ++++ wordpress/wp-includes/update.php 2014-12-22 06:48:44.144609988 +0100 +@@ -626,9 +626,6 @@ function _maybe_update_themes() { * @since 3.1.0 */ function wp_schedule_update_checks() { @@ -75,8 +75,8 @@ diff -up wordpress/wp-includes/update.php.nop wordpress/wp-includes/update.php if ( !wp_next_scheduled('wp_update_plugins') && !defined('WP_INSTALLING') ) wp_schedule_event(time(), 'twicedaily', 'wp_update_plugins'); -@@ -652,8 +649,6 @@ if ( ( ! is_main_site() && ! is_network_ - return; +@@ -671,8 +668,6 @@ if ( ( ! is_main_site() && ! is_network_ + } add_action( 'admin_init', '_maybe_update_core' ); -add_action( 'wp_version_check', 'wp_version_check' ); diff --git a/wordpress.spec b/wordpress.spec index 7cef0d7..2dd32ad 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -16,7 +16,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 4.0.1 +Version: 4.1 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -41,7 +41,7 @@ Patch3: wordpress-4.0-tinymce_noflash.patch # Adjust mediaelement not to use its SWF and Silverlight plugins. This # changes 'plugins:["flash,"silverlight","youtube","vimeo"]' to # 'plugins:["youtube","vimeo"]' -Patch4: wordpress-3.9-mediaelement-noflash_silverlight.patch +Patch4: wordpress-4.1-mediaelement-noflash_silverlight.patch # RPM configuration: # Path to installation # Disable auto-updater @@ -50,7 +50,7 @@ Patch5: wordpress-4.0-config.patch # disable version check and updated # change DISALLOW_FILE_MODS default value to true # ignore WP_AUTO_UPDATE_CORE (always false) -Patch6: wordpress-4.0-noupdate.patch +Patch6: wordpress-4.1-noupdate.patch # Use system libraries Patch7: wordpress-4.0-systemlibs.patch @@ -280,6 +280,9 @@ rm -rf ${RPM_BUILD_ROOT} %{_datadir}/wordpress/xmlrpc.php %changelog +* Mon Dec 22 2014 Remi Collet - 4.1-1 +- WordPress 4.1 “Dinah” + * Fri Nov 21 2014 Remi Collet - 4.0.1-1 - WordPress 4.0.1 Security Release - use system php-getid3 when available #1145574 From 9d813d263a625870ff8ca1061b92f21a9bfd6ad4 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 19 Feb 2015 08:44:09 +0100 Subject: [PATCH 15/20] WordPress 4.1.1 Maintenance Release (cherry picked from commit 0bf276fc2da515b4c256ab3a480272828459bc86) --- wordpress.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/wordpress.spec b/wordpress.spec index 2dd32ad..54ac696 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -16,7 +16,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 4.1 +Version: 4.1.1 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -280,6 +280,9 @@ rm -rf ${RPM_BUILD_ROOT} %{_datadir}/wordpress/xmlrpc.php %changelog +* Thu Feb 19 2015 Remi Collet - 4.1.1-1 +- WordPress 4.1.1 Maintenance Release + * Mon Dec 22 2014 Remi Collet - 4.1-1 - WordPress 4.1 “Dinah” From 905f25f1c4eefe0a908d3b24bc375699d8c02b1e Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 19 Feb 2015 08:52:46 +0100 Subject: [PATCH 16/20] 4.1.1 sources (cherry picked from commit 8deee85d43e9fa16ed786b5954879b5149f758c1) --- .gitignore | 1 + sources | 2 +- wordpress.spec | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index db9fba7..719ea7a 100644 --- a/.gitignore +++ b/.gitignore @@ -12,3 +12,4 @@ clog /wordpress-4.0.tar.gz /wordpress-4.0.1.tar.gz /wordpress-4.1.tar.gz +/wordpress-4.1.1.tar.gz diff --git a/sources b/sources index 9f84c78..80218b0 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -5adac1bfc61b793a1ca9bcb4d67b4d28 wordpress-4.1.tar.gz +bcf6532a859ad86d532259b18d78c5cb wordpress-4.1.1.tar.gz diff --git a/wordpress.spec b/wordpress.spec index 54ac696..619d416 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -279,6 +279,7 @@ rm -rf ${RPM_BUILD_ROOT} %attr(640,root,apache) %config(noreplace) %{_sysconfdir}/wordpress/wp-config.php %{_datadir}/wordpress/xmlrpc.php + %changelog * Thu Feb 19 2015 Remi Collet - 4.1.1-1 - WordPress 4.1.1 Maintenance Release From 880327141cd09193f05d878994e0cd412aa425eb Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 23 Apr 2015 13:18:18 +0200 Subject: [PATCH 17/20] update to 4.1.2 (security) (cherry picked from commit 146dfc159681c93d5760a199cf9e70257cfc7441) --- .gitignore | 1 + sources | 2 +- wordpress-4.1-noupdate.patch | 4 ++-- wordpress.spec | 5 ++++- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 719ea7a..463c1b3 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,4 @@ clog /wordpress-4.0.1.tar.gz /wordpress-4.1.tar.gz /wordpress-4.1.1.tar.gz +/wordpress-4.1.2.tar.gz diff --git a/sources b/sources index 80218b0..013331d 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -bcf6532a859ad86d532259b18d78c5cb wordpress-4.1.1.tar.gz +266abe568f3f1a82aba0b0aac3e11d16 wordpress-4.1.2.tar.gz diff --git a/wordpress-4.1-noupdate.patch b/wordpress-4.1-noupdate.patch index 9578b76..5105c23 100644 --- a/wordpress-4.1-noupdate.patch +++ b/wordpress-4.1-noupdate.patch @@ -65,7 +65,7 @@ diff -up wordpress/wp-includes/capabilities.php.rpm wordpress/wp-includes/capabi diff -up wordpress/wp-includes/update.php.rpm wordpress/wp-includes/update.php --- wordpress/wp-includes/update.php.rpm 2014-12-22 06:48:34.883575009 +0100 +++ wordpress/wp-includes/update.php 2014-12-22 06:48:44.144609988 +0100 -@@ -626,9 +626,6 @@ function _maybe_update_themes() { +@@ -624,9 +624,6 @@ function _maybe_update_themes() { * @since 3.1.0 */ function wp_schedule_update_checks() { @@ -75,7 +75,7 @@ diff -up wordpress/wp-includes/update.php.rpm wordpress/wp-includes/update.php if ( !wp_next_scheduled('wp_update_plugins') && !defined('WP_INSTALLING') ) wp_schedule_event(time(), 'twicedaily', 'wp_update_plugins'); -@@ -671,8 +668,6 @@ if ( ( ! is_main_site() && ! is_network_ +@@ -669,8 +666,6 @@ if ( ( ! is_main_site() && ! is_network_ } add_action( 'admin_init', '_maybe_update_core' ); diff --git a/wordpress.spec b/wordpress.spec index 619d416..2c09797 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -16,7 +16,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 4.1.1 +Version: 4.1.2 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -281,6 +281,9 @@ rm -rf ${RPM_BUILD_ROOT} %changelog +* Thu Apr 23 2015 Remi Collet - 4.1.2-1 +- WordPress 4.1.2 Security Release + * Thu Feb 19 2015 Remi Collet - 4.1.1-1 - WordPress 4.1.1 Maintenance Release From f9fe6e73a432d27b6eedba9f43e8a2e01bbd3a00 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Fri, 24 Apr 2015 11:00:16 +0200 Subject: [PATCH 18/20] WordPress 4.1.3 Maintenance Release (cherry picked from commit 325a6b669700f688cab4419f8d46b7364ddbcb3a) --- .gitignore | 1 + sources | 2 +- wordpress.spec | 5 ++++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 463c1b3..f57617c 100644 --- a/.gitignore +++ b/.gitignore @@ -14,3 +14,4 @@ clog /wordpress-4.1.tar.gz /wordpress-4.1.1.tar.gz /wordpress-4.1.2.tar.gz +/wordpress-4.1.3.tar.gz diff --git a/sources b/sources index 013331d..1c7b794 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -266abe568f3f1a82aba0b0aac3e11d16 wordpress-4.1.2.tar.gz +7cad0a1baee7a6bccc0e0ff860c21594 wordpress-4.1.3.tar.gz diff --git a/wordpress.spec b/wordpress.spec index 2c09797..21cd9a2 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -16,7 +16,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 4.1.2 +Version: 4.1.3 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -281,6 +281,9 @@ rm -rf ${RPM_BUILD_ROOT} %changelog +* Fri Apr 24 2015 Remi Collet - 4.1.3-1 +- WordPress 4.1.3 Maintenance Release + * Thu Apr 23 2015 Remi Collet - 4.1.2-1 - WordPress 4.1.2 Security Release From c599cbc87ad8d33dfd42b1627555afcb9956ecd8 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 28 Apr 2015 08:50:05 +0200 Subject: [PATCH 19/20] WordPress 4.2.1 Security Release (cherry picked from commit 12860fe24e709777b7b6b691aa40d1c267079d61) --- .gitignore | 3 +- sources | 2 +- ...4.1-mediaelement-noflash_silverlight.patch | 11 ------ ...4.2-mediaelement-noflash_silverlight.patch | 18 +++++++++ ....patch => wordpress-4.2-no_swfupload.patch | 4 +- ...date.patch => wordpress-4.2-noupdate.patch | 38 +++++++++---------- wordpress.spec | 12 ++++-- 7 files changed, 50 insertions(+), 38 deletions(-) delete mode 100644 wordpress-4.1-mediaelement-noflash_silverlight.patch create mode 100644 wordpress-4.2-mediaelement-noflash_silverlight.patch rename wordpress-3.9-no_swfupload.patch => wordpress-4.2-no_swfupload.patch (94%) rename wordpress-4.1-noupdate.patch => wordpress-4.2-noupdate.patch (58%) diff --git a/.gitignore b/.gitignore index f57617c..0642600 100644 --- a/.gitignore +++ b/.gitignore @@ -14,4 +14,5 @@ clog /wordpress-4.1.tar.gz /wordpress-4.1.1.tar.gz /wordpress-4.1.2.tar.gz -/wordpress-4.1.3.tar.gz +/wordpress-4.2.tar.gz +/wordpress-4.2.1.tar.gz diff --git a/sources b/sources index 1c7b794..2d0742f 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -7cad0a1baee7a6bccc0e0ff860c21594 wordpress-4.1.3.tar.gz +71eef0d7c8b26fc7b65c41449eefbb2a wordpress-4.2.1.tar.gz diff --git a/wordpress-4.1-mediaelement-noflash_silverlight.patch b/wordpress-4.1-mediaelement-noflash_silverlight.patch deleted file mode 100644 index 125eec4..0000000 --- a/wordpress-4.1-mediaelement-noflash_silverlight.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- wordpress/wp-includes/js/mediaelement/mediaelement-and-player.min.js.orig 2014-12-22 06:38:12.716225091 +0100 -+++ wordpress/wp-includes/js/mediaelement/mediaelement-and-player.min.js 2014-12-22 06:39:30.045517161 +0100 -@@ -12,7 +12,7 @@ - * License: MIT - * - */ --function onYouTubePlayerAPIReady(){mejs.YouTubeApi.iFrameReady()}function onYouTubePlayerReady(a){mejs.YouTubeApi.flashReady(a)}var mejs=mejs||{};mejs.version="2.16.2",mejs.meIndex=0,mejs.plugins={silverlight:[{version:[3,0],types:["video/mp4","video/m4v","video/mov","video/wmv","audio/wma","audio/m4a","audio/mp3","audio/wav","audio/mpeg"]}],flash:[{version:[9,0,124],types:["video/mp4","video/m4v","video/mov","video/flv","video/rtmp","video/x-flv","audio/flv","audio/x-flv","audio/mp3","audio/m4a","audio/mpeg","video/youtube","video/x-youtube","application/x-mpegURL"]}],youtube:[{version:null,types:["video/youtube","video/x-youtube","audio/youtube","audio/x-youtube"]}],vimeo:[{version:null,types:["video/vimeo","video/x-vimeo"]}]},mejs.Utility={encodeUrl:function(a){return encodeURIComponent(a)},escapeHTML:function(a){return a.toString().split("&").join("&").split("<").join("<").split('"').join(""")},absolutizeUrl:function(a){var b=document.createElement("div");return b.innerHTML='x',b.firstChild.href},getScriptPath:function(a){for(var b,c,d,e,f,g,h=0,i="",j="",k=document.getElementsByTagName("script"),l=k.length,m=a.length;l>h;h++){for(e=k[h].src,c=e.lastIndexOf("/"),c>-1?(g=e.substring(c+1),f=e.substring(0,c+1)):(g=e,f=""),b=0;m>b;b++)if(j=a[b],d=g.indexOf(j),d>-1){i=f;break}if(""!==i)break}return i},secondsToTimeCode:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=Math.floor(a/3600)%24,f=Math.floor(a/60)%60,g=Math.floor(a%60),h=Math.floor((a%1*d).toFixed(3)),i=(b||e>0?(10>e?"0"+e:e)+":":"")+(10>f?"0"+f:f)+":"+(10>g?"0"+g:g)+(c?":"+(10>h?"0"+h:h):"");return i},timeCodeToSeconds:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=a.split(":"),f=parseInt(e[0],10),g=parseInt(e[1],10),h=parseInt(e[2],10),i=0,j=0;return c&&(i=parseInt(e[3])/d),j=3600*f+60*g+h+i},convertSMPTEtoSeconds:function(a){if("string"!=typeof a)return!1;a=a.replace(",",".");var b=0,c=-1!=a.indexOf(".")?a.split(".")[1].length:0,d=1;a=a.split(":").reverse();for(var e=0;e0&&(d=Math.pow(60,e)),b+=Number(a[e])*d;return Number(b.toFixed(c))},removeSwf:function(a){var b=document.getElementById(a);b&&/object|embed/i.test(b.nodeName)&&(mejs.MediaFeatures.isIE?(b.style.display="none",function(){4==b.readyState?mejs.Utility.removeObjectInIE(a):setTimeout(arguments.callee,10)}()):b.parentNode.removeChild(b))},removeObjectInIE:function(a){var b=document.getElementById(a);if(b){for(var c in b)"function"==typeof b[c]&&(b[c]=null);b.parentNode.removeChild(b)}}},mejs.PluginDetector={hasPluginVersion:function(a,b){var c=this.plugins[a];return b[1]=b[1]||0,b[2]=b[2]||0,c[0]>b[0]||c[0]==b[0]&&c[1]>b[1]||c[0]==b[0]&&c[1]==b[1]&&c[2]>=b[2]?!0:!1},nav:window.navigator,ua:window.navigator.userAgent.toLowerCase(),plugins:[],addPlugin:function(a,b,c,d,e){this.plugins[a]=this.detectPlugin(b,c,d,e)},detectPlugin:function(a,b,c,d){var e,f,g,h=[0,0,0];if("undefined"!=typeof this.nav.plugins&&"object"==typeof this.nav.plugins[a]){if(e=this.nav.plugins[a].description,e&&("undefined"==typeof this.nav.mimeTypes||!this.nav.mimeTypes[b]||this.nav.mimeTypes[b].enabledPlugin))for(h=e.replace(a,"").replace(/^\s+/,"").replace(/\sr/gi,".").split("."),f=0;f0;)this.removeChild(b[0]);if("string"==typeof a)this.src=a;else{var c,d;for(c=0;c0&&null!==q[0].url&&this.getTypeFromFile(q[0].url).indexOf("audio")>-1&&(r.isVideo=!1),mejs.MediaFeatures.isBustedAndroid&&(a.canPlayType=function(a){return null!==a.match(/video\/(mp4|m4v)/gi)?"maybe":""}),!(!c||"auto"!==b.mode&&"auto_plugin"!==b.mode&&"native"!==b.mode||mejs.MediaFeatures.isBustedNativeHTTPS&&b.httpsBasicAuthSite===!0)){for(d||(o=document.createElement(r.isVideo?"video":"audio"),a.parentNode.insertBefore(o,a),a.style.display="none",r.htmlMediaElement=a=o),f=0;f0&&(r.url=q[0].url),r)},formatType:function(a,b){return a&&!b?this.getTypeFromFile(a):b&&~b.indexOf(";")?b.substr(0,b.indexOf(";")):b},getTypeFromFile:function(a){a=a.split("?")[0];var b=a.substring(a.lastIndexOf(".")+1).toLowerCase();return(/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video":"audio")+"/"+this.getTypeFromExtension(b)},getTypeFromExtension:function(a){switch(a){case"mp4":case"m4v":case"m4a":return"mp4";case"webm":case"webma":case"webmv":return"webm";case"ogg":case"oga":case"ogv":return"ogg";default:return a}},createErrorMessage:function(a,b,c){var d=a.htmlMediaElement,e=document.createElement("div");e.className="me-cannotplay";try{e.style.width=d.width+"px",e.style.height=d.height+"px"}catch(f){}e.innerHTML=b.customError?b.customError:""!==c?'':''+mejs.i18n.t("Download File")+"",d.parentNode.insertBefore(e,d),d.style.display="none",b.error(d)},createPlugin:function(a,b,c,d,e,f){var g,h,i,j=a.htmlMediaElement,k=1,l=1,m="me_"+a.method+"_"+mejs.meIndex++,n=new mejs.PluginMediaElement(m,a.method,a.url),o=document.createElement("div");n.tagName=j.tagName;for(var p=0;p0?b.pluginWidth:b.videoWidth>0?b.videoWidth:null!==j.getAttribute("width")?j.getAttribute("width"):b.defaultVideoWidth,l=b.pluginHeight>0?b.pluginHeight:b.videoHeight>0?b.videoHeight:null!==j.getAttribute("height")?j.getAttribute("height"):b.defaultVideoHeight,k=mejs.Utility.encodeUrl(k),l=mejs.Utility.encodeUrl(l)):b.enablePluginDebug&&(k=320,l=240),n.success=b.success,mejs.MediaPluginBridge.registerPluginElement(m,n,j),o.className="me-plugin",o.id=m+"_container",a.isVideo?j.parentNode.insertBefore(o,j):document.body.insertBefore(o,document.body.childNodes[0]),i=["id="+m,"isvideo="+(a.isVideo?"true":"false"),"autoplay="+(d?"true":"false"),"preload="+e,"width="+k,"startvolume="+b.startVolume,"timerrate="+b.timerRate,"flashstreamer="+b.flashStreamer,"height="+l,"pseudostreamstart="+b.pseudoStreamingStartQueryParam],null!==a.url&&i.push("flash"==a.method?"file="+mejs.Utility.encodeUrl(a.url):"file="+a.url),b.enablePluginDebug&&i.push("debug=true"),b.enablePluginSmoothing&&i.push("smoothing=true"),b.enablePseudoStreaming&&i.push("pseudostreaming=true"),f&&i.push("controls=true"),b.pluginVars&&(i=i.concat(b.pluginVars)),a.method){case"silverlight":o.innerHTML='';break;case"flash":mejs.MediaFeatures.isIE?(g=document.createElement("div"),o.appendChild(g),g.outerHTML=''):o.innerHTML='';break;case"youtube":var r;-1!=a.url.lastIndexOf("youtu.be")?(r=a.url.substr(a.url.lastIndexOf("/")+1),-1!=r.indexOf("?")&&(r=r.substr(0,r.indexOf("?")))):r=a.url.substr(a.url.lastIndexOf("=")+1),youtubeSettings={container:o,containerId:o.id,pluginMediaElement:n,pluginId:m,videoId:r,height:l,width:k},mejs.PluginDetector.hasPluginVersion("flash",[10,0,0])?mejs.YouTubeApi.createFlash(youtubeSettings):mejs.YouTubeApi.enqueueIframe(youtubeSettings);break;case"vimeo":var s=m+"_player";if(n.vimeoid=a.url.substr(a.url.lastIndexOf("/")+1),o.innerHTML='',"function"==typeof $f){var t=$f(o.childNodes[0]);t.addEvent("ready",function(){function a(a,b,c,d){var e={type:c,target:b};"timeupdate"==c&&(b.currentTime=e.currentTime=d.seconds,b.duration=e.duration=d.duration),b.dispatchEvent(e.type,e)}$.extend(t,{playVideo:function(){t.api("play")},stopVideo:function(){t.api("unload")},pauseVideo:function(){t.api("pause")},seekTo:function(a){t.api("seekTo",a)},setVolume:function(a){t.api("setVolume",a)},setMuted:function(a){a?(t.lastVolume=t.api("getVolume"),t.api("setVolume",0)):(t.api("setVolume",t.lastVolume),delete t.lastVolume)}}),t.addEvent("play",function(){a(t,n,"play"),a(t,n,"playing")}),t.addEvent("pause",function(){a(t,n,"pause")}),t.addEvent("finish",function(){a(t,n,"ended")}),t.addEvent("playProgress",function(b){a(t,n,"timeupdate",b)}),n.pluginElement=o,n.pluginApi=t,mejs.MediaPluginBridge.initPlugin(m)})}else console.warn("You need to include froogaloop for vimeo to work")}return j.style.display="none",j.removeAttribute("autoplay"),n},updateNative:function(a,b){var c,d=a.htmlMediaElement;for(c in mejs.HtmlMediaElement)d[c]=mejs.HtmlMediaElement[c];return b.success(d,d),d}},mejs.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(){if(!this.isIframeStarted){var a=document.createElement("script");a.src="//www.youtube.com/player_api";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(),this.iframeQueue.push(a))},createIframe:function(a){var b=a.pluginMediaElement,c=new YT.Player(a.containerId,{height:a.height,width:a.width,videoId:a.videoId,playerVars:{controls:0},events:{onReady:function(){a.pluginMediaElement.pluginApi=c,mejs.MediaPluginBridge.initPlugin(a.pluginId),setInterval(function(){mejs.YouTubeApi.createEvent(c,b,"timeupdate")},250)},onStateChange:function(a){mejs.YouTubeApi.handleStateChange(a.data,c,b)}}})},createEvent:function(a,b,c){var d={type:c,target:b};if(a&&a.getDuration){b.currentTime=d.currentTime=a.getCurrentTime(),b.duration=d.duration=a.getDuration(),d.paused=b.paused,d.ended=b.ended,d.muted=a.isMuted(),d.volume=a.getVolume()/100,d.bytesTotal=a.getVideoBytesTotal(),d.bufferedBytes=a.getVideoBytesLoaded();var e=d.bufferedBytes/d.bytesTotal*d.duration;d.target.buffered=d.buffered={start:function(){return 0},end:function(){return e},length:1}}b.dispatchEvent(d.type,d)},iFrameReady:function(){for(this.isLoaded=!0,this.isIframeLoaded=!0;this.iframeQueue.length>0;){var a=this.iframeQueue.pop();this.createIframe(a)}},flashPlayers:{},createFlash:function(a){this.flashPlayers[a.pluginId]=a;var b,c="//www.youtube.com/apiplayer?enablejsapi=1&playerapiid="+a.pluginId+"&version=3&autoplay=0&controls=0&modestbranding=1&loop=0";mejs.MediaFeatures.isIE?(b=document.createElement("div"),a.container.appendChild(b),b.outerHTML=''):a.container.innerHTML=''},flashReady:function(a){var b=this.flashPlayers[a],c=document.getElementById(a),d=b.pluginMediaElement;d.pluginApi=d.pluginElement=c,mejs.MediaPluginBridge.initPlugin(a),c.cueVideoById(b.videoId);var e=b.containerId+"_callback";window[e]=function(a){mejs.YouTubeApi.handleStateChange(a,c,d)},c.addEventListener("onStateChange",e),setInterval(function(){mejs.YouTubeApi.createEvent(c,d,"timeupdate")},250),mejs.YouTubeApi.createEvent(c,d,"canplay")},handleStateChange:function(a,b,c){switch(a){case-1:c.paused=!0,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"loadedmetadata");break;case 0:c.paused=!1,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"ended");break;case 1:c.paused=!1,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"play"),mejs.YouTubeApi.createEvent(b,c,"playing");break;case 2:c.paused=!0,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"pause");break;case 3:mejs.YouTubeApi.createEvent(b,c,"progress");break;case 5:}}},window.mejs=mejs,window.MediaElement=mejs.MediaElement,function(a,b){"use strict";var c={locale:{language:b.i18n&&b.i18n.locale.language||"",strings:b.i18n&&b.i18n.locale.strings||{}},ietf_lang_regex:/^(x\-)?[a-z]{2,}(\-\w{2,})?(\-\w{2,})?$/,methods:{}};c.getLanguage=function(){var a=c.locale.language||window.navigator.userLanguage||window.navigator.language;return c.ietf_lang_regex.exec(a)?a:null},"undefined"!=typeof mejsL10n&&(c.locale.language=mejsL10n.language),c.methods.checkPlain=function(a){var b,c,d={"&":"&",'"':""","<":"<",">":">"};a=String(a);for(b in d)d.hasOwnProperty(b)&&(c=new RegExp(b,"g"),a=a.replace(c,d[b]));return a},c.methods.t=function(a,b){return c.locale.strings&&c.locale.strings[b.context]&&c.locale.strings[b.context][a]&&(a=c.locale.strings[b.context][a]),c.methods.checkPlain(a)},c.t=function(a,b){if("string"==typeof a&&a.length>0){var d=c.getLanguage();return b=b||{context:d},c.methods.t(a,b)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=c}(document,mejs),function(a){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(mejs.i18n.locale.strings),/*! -+function onYouTubePlayerAPIReady(){mejs.YouTubeApi.iFrameReady()}function onYouTubePlayerReady(a){mejs.YouTubeApi.flashReady(a)}var mejs=mejs||{};mejs.version="2.16.2",mejs.meIndex=0,mejs.plugins={silverlight:[{version:[3,0],types:["video/mp4","video/m4v","video/mov","video/wmv","audio/wma","audio/m4a","audio/mp3","audio/wav","audio/mpeg"]}],flash:[{version:[9,0,124],types:["video/mp4","video/m4v","video/mov","video/flv","video/rtmp","video/x-flv","audio/flv","audio/x-flv","audio/mp3","audio/m4a","audio/mpeg","video/youtube","video/x-youtube","application/x-mpegURL"]}],youtube:[{version:null,types:["video/youtube","video/x-youtube","audio/youtube","audio/x-youtube"]}],vimeo:[{version:null,types:["video/vimeo","video/x-vimeo"]}]},mejs.Utility={encodeUrl:function(a){return encodeURIComponent(a)},escapeHTML:function(a){return a.toString().split("&").join("&").split("<").join("<").split('"').join(""")},absolutizeUrl:function(a){var b=document.createElement("div");return b.innerHTML='x',b.firstChild.href},getScriptPath:function(a){for(var b,c,d,e,f,g,h=0,i="",j="",k=document.getElementsByTagName("script"),l=k.length,m=a.length;l>h;h++){for(e=k[h].src,c=e.lastIndexOf("/"),c>-1?(g=e.substring(c+1),f=e.substring(0,c+1)):(g=e,f=""),b=0;m>b;b++)if(j=a[b],d=g.indexOf(j),d>-1){i=f;break}if(""!==i)break}return i},secondsToTimeCode:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=Math.floor(a/3600)%24,f=Math.floor(a/60)%60,g=Math.floor(a%60),h=Math.floor((a%1*d).toFixed(3)),i=(b||e>0?(10>e?"0"+e:e)+":":"")+(10>f?"0"+f:f)+":"+(10>g?"0"+g:g)+(c?":"+(10>h?"0"+h:h):"");return i},timeCodeToSeconds:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=a.split(":"),f=parseInt(e[0],10),g=parseInt(e[1],10),h=parseInt(e[2],10),i=0,j=0;return c&&(i=parseInt(e[3])/d),j=3600*f+60*g+h+i},convertSMPTEtoSeconds:function(a){if("string"!=typeof a)return!1;a=a.replace(",",".");var b=0,c=-1!=a.indexOf(".")?a.split(".")[1].length:0,d=1;a=a.split(":").reverse();for(var e=0;e0&&(d=Math.pow(60,e)),b+=Number(a[e])*d;return Number(b.toFixed(c))},removeSwf:function(a){var b=document.getElementById(a);b&&/object|embed/i.test(b.nodeName)&&(mejs.MediaFeatures.isIE?(b.style.display="none",function(){4==b.readyState?mejs.Utility.removeObjectInIE(a):setTimeout(arguments.callee,10)}()):b.parentNode.removeChild(b))},removeObjectInIE:function(a){var b=document.getElementById(a);if(b){for(var c in b)"function"==typeof b[c]&&(b[c]=null);b.parentNode.removeChild(b)}}},mejs.PluginDetector={hasPluginVersion:function(a,b){var c=this.plugins[a];return b[1]=b[1]||0,b[2]=b[2]||0,c[0]>b[0]||c[0]==b[0]&&c[1]>b[1]||c[0]==b[0]&&c[1]==b[1]&&c[2]>=b[2]?!0:!1},nav:window.navigator,ua:window.navigator.userAgent.toLowerCase(),plugins:[],addPlugin:function(a,b,c,d,e){this.plugins[a]=this.detectPlugin(b,c,d,e)},detectPlugin:function(a,b,c,d){var e,f,g,h=[0,0,0];if("undefined"!=typeof this.nav.plugins&&"object"==typeof this.nav.plugins[a]){if(e=this.nav.plugins[a].description,e&&("undefined"==typeof this.nav.mimeTypes||!this.nav.mimeTypes[b]||this.nav.mimeTypes[b].enabledPlugin))for(h=e.replace(a,"").replace(/^\s+/,"").replace(/\sr/gi,".").split("."),f=0;f0;)this.removeChild(b[0]);if("string"==typeof a)this.src=a;else{var c,d;for(c=0;c0&&null!==q[0].url&&this.getTypeFromFile(q[0].url).indexOf("audio")>-1&&(r.isVideo=!1),mejs.MediaFeatures.isBustedAndroid&&(a.canPlayType=function(a){return null!==a.match(/video\/(mp4|m4v)/gi)?"maybe":""}),!(!c||"auto"!==b.mode&&"auto_plugin"!==b.mode&&"native"!==b.mode||mejs.MediaFeatures.isBustedNativeHTTPS&&b.httpsBasicAuthSite===!0)){for(d||(o=document.createElement(r.isVideo?"video":"audio"),a.parentNode.insertBefore(o,a),a.style.display="none",r.htmlMediaElement=a=o),f=0;f0&&(r.url=q[0].url),r)},formatType:function(a,b){return a&&!b?this.getTypeFromFile(a):b&&~b.indexOf(";")?b.substr(0,b.indexOf(";")):b},getTypeFromFile:function(a){a=a.split("?")[0];var b=a.substring(a.lastIndexOf(".")+1).toLowerCase();return(/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video":"audio")+"/"+this.getTypeFromExtension(b)},getTypeFromExtension:function(a){switch(a){case"mp4":case"m4v":case"m4a":return"mp4";case"webm":case"webma":case"webmv":return"webm";case"ogg":case"oga":case"ogv":return"ogg";default:return a}},createErrorMessage:function(a,b,c){var d=a.htmlMediaElement,e=document.createElement("div");e.className="me-cannotplay";try{e.style.width=d.width+"px",e.style.height=d.height+"px"}catch(f){}e.innerHTML=b.customError?b.customError:""!==c?'':''+mejs.i18n.t("Download File")+"",d.parentNode.insertBefore(e,d),d.style.display="none",b.error(d)},createPlugin:function(a,b,c,d,e,f){var g,h,i,j=a.htmlMediaElement,k=1,l=1,m="me_"+a.method+"_"+mejs.meIndex++,n=new mejs.PluginMediaElement(m,a.method,a.url),o=document.createElement("div");n.tagName=j.tagName;for(var p=0;p0?b.pluginWidth:b.videoWidth>0?b.videoWidth:null!==j.getAttribute("width")?j.getAttribute("width"):b.defaultVideoWidth,l=b.pluginHeight>0?b.pluginHeight:b.videoHeight>0?b.videoHeight:null!==j.getAttribute("height")?j.getAttribute("height"):b.defaultVideoHeight,k=mejs.Utility.encodeUrl(k),l=mejs.Utility.encodeUrl(l)):b.enablePluginDebug&&(k=320,l=240),n.success=b.success,mejs.MediaPluginBridge.registerPluginElement(m,n,j),o.className="me-plugin",o.id=m+"_container",a.isVideo?j.parentNode.insertBefore(o,j):document.body.insertBefore(o,document.body.childNodes[0]),i=["id="+m,"isvideo="+(a.isVideo?"true":"false"),"autoplay="+(d?"true":"false"),"preload="+e,"width="+k,"startvolume="+b.startVolume,"timerrate="+b.timerRate,"flashstreamer="+b.flashStreamer,"height="+l,"pseudostreamstart="+b.pseudoStreamingStartQueryParam],null!==a.url&&i.push("flash"==a.method?"file="+mejs.Utility.encodeUrl(a.url):"file="+a.url),b.enablePluginDebug&&i.push("debug=true"),b.enablePluginSmoothing&&i.push("smoothing=true"),b.enablePseudoStreaming&&i.push("pseudostreaming=true"),f&&i.push("controls=true"),b.pluginVars&&(i=i.concat(b.pluginVars)),a.method){case"silverlight":o.innerHTML='';break;case"flash":mejs.MediaFeatures.isIE?(g=document.createElement("div"),o.appendChild(g),g.outerHTML=''):o.innerHTML='';break;case"youtube":var r;-1!=a.url.lastIndexOf("youtu.be")?(r=a.url.substr(a.url.lastIndexOf("/")+1),-1!=r.indexOf("?")&&(r=r.substr(0,r.indexOf("?")))):r=a.url.substr(a.url.lastIndexOf("=")+1),youtubeSettings={container:o,containerId:o.id,pluginMediaElement:n,pluginId:m,videoId:r,height:l,width:k},mejs.PluginDetector.hasPluginVersion("flash",[10,0,0])?mejs.YouTubeApi.createFlash(youtubeSettings):mejs.YouTubeApi.enqueueIframe(youtubeSettings);break;case"vimeo":var s=m+"_player";if(n.vimeoid=a.url.substr(a.url.lastIndexOf("/")+1),o.innerHTML='',"function"==typeof $f){var t=$f(o.childNodes[0]);t.addEvent("ready",function(){function a(a,b,c,d){var e={type:c,target:b};"timeupdate"==c&&(b.currentTime=e.currentTime=d.seconds,b.duration=e.duration=d.duration),b.dispatchEvent(e.type,e)}$.extend(t,{playVideo:function(){t.api("play")},stopVideo:function(){t.api("unload")},pauseVideo:function(){t.api("pause")},seekTo:function(a){t.api("seekTo",a)},setVolume:function(a){t.api("setVolume",a)},setMuted:function(a){a?(t.lastVolume=t.api("getVolume"),t.api("setVolume",0)):(t.api("setVolume",t.lastVolume),delete t.lastVolume)}}),t.addEvent("play",function(){a(t,n,"play"),a(t,n,"playing")}),t.addEvent("pause",function(){a(t,n,"pause")}),t.addEvent("finish",function(){a(t,n,"ended")}),t.addEvent("playProgress",function(b){a(t,n,"timeupdate",b)}),n.pluginElement=o,n.pluginApi=t,mejs.MediaPluginBridge.initPlugin(m)})}else console.warn("You need to include froogaloop for vimeo to work")}return j.style.display="none",j.removeAttribute("autoplay"),n},updateNative:function(a,b){var c,d=a.htmlMediaElement;for(c in mejs.HtmlMediaElement)d[c]=mejs.HtmlMediaElement[c];return b.success(d,d),d}},mejs.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(){if(!this.isIframeStarted){var a=document.createElement("script");a.src="//www.youtube.com/player_api";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(),this.iframeQueue.push(a))},createIframe:function(a){var b=a.pluginMediaElement,c=new YT.Player(a.containerId,{height:a.height,width:a.width,videoId:a.videoId,playerVars:{controls:0},events:{onReady:function(){a.pluginMediaElement.pluginApi=c,mejs.MediaPluginBridge.initPlugin(a.pluginId),setInterval(function(){mejs.YouTubeApi.createEvent(c,b,"timeupdate")},250)},onStateChange:function(a){mejs.YouTubeApi.handleStateChange(a.data,c,b)}}})},createEvent:function(a,b,c){var d={type:c,target:b};if(a&&a.getDuration){b.currentTime=d.currentTime=a.getCurrentTime(),b.duration=d.duration=a.getDuration(),d.paused=b.paused,d.ended=b.ended,d.muted=a.isMuted(),d.volume=a.getVolume()/100,d.bytesTotal=a.getVideoBytesTotal(),d.bufferedBytes=a.getVideoBytesLoaded();var e=d.bufferedBytes/d.bytesTotal*d.duration;d.target.buffered=d.buffered={start:function(){return 0},end:function(){return e},length:1}}b.dispatchEvent(d.type,d)},iFrameReady:function(){for(this.isLoaded=!0,this.isIframeLoaded=!0;this.iframeQueue.length>0;){var a=this.iframeQueue.pop();this.createIframe(a)}},flashPlayers:{},createFlash:function(a){this.flashPlayers[a.pluginId]=a;var b,c="//www.youtube.com/apiplayer?enablejsapi=1&playerapiid="+a.pluginId+"&version=3&autoplay=0&controls=0&modestbranding=1&loop=0";mejs.MediaFeatures.isIE?(b=document.createElement("div"),a.container.appendChild(b),b.outerHTML=''):a.container.innerHTML=''},flashReady:function(a){var b=this.flashPlayers[a],c=document.getElementById(a),d=b.pluginMediaElement;d.pluginApi=d.pluginElement=c,mejs.MediaPluginBridge.initPlugin(a),c.cueVideoById(b.videoId);var e=b.containerId+"_callback";window[e]=function(a){mejs.YouTubeApi.handleStateChange(a,c,d)},c.addEventListener("onStateChange",e),setInterval(function(){mejs.YouTubeApi.createEvent(c,d,"timeupdate")},250),mejs.YouTubeApi.createEvent(c,d,"canplay")},handleStateChange:function(a,b,c){switch(a){case-1:c.paused=!0,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"loadedmetadata");break;case 0:c.paused=!1,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"ended");break;case 1:c.paused=!1,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"play"),mejs.YouTubeApi.createEvent(b,c,"playing");break;case 2:c.paused=!0,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"pause");break;case 3:mejs.YouTubeApi.createEvent(b,c,"progress");break;case 5:}}},window.mejs=mejs,window.MediaElement=mejs.MediaElement,function(a,b){"use strict";var c={locale:{language:b.i18n&&b.i18n.locale.language||"",strings:b.i18n&&b.i18n.locale.strings||{}},ietf_lang_regex:/^(x\-)?[a-z]{2,}(\-\w{2,})?(\-\w{2,})?$/,methods:{}};c.getLanguage=function(){var a=c.locale.language||window.navigator.userLanguage||window.navigator.language;return c.ietf_lang_regex.exec(a)?a:null},"undefined"!=typeof mejsL10n&&(c.locale.language=mejsL10n.language),c.methods.checkPlain=function(a){var b,c,d={"&":"&",'"':""","<":"<",">":">"};a=String(a);for(b in d)d.hasOwnProperty(b)&&(c=new RegExp(b,"g"),a=a.replace(c,d[b]));return a},c.methods.t=function(a,b){return c.locale.strings&&c.locale.strings[b.context]&&c.locale.strings[b.context][a]&&(a=c.locale.strings[b.context][a]),c.methods.checkPlain(a)},c.t=function(a,b){if("string"==typeof a&&a.length>0){var d=c.getLanguage();return b=b||{context:d},c.methods.t(a,b)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=c}(document,mejs),function(a){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(mejs.i18n.locale.strings),/*! - * - * MediaElementPlayer - * http://mediaelementjs.com/ diff --git a/wordpress-4.2-mediaelement-noflash_silverlight.patch b/wordpress-4.2-mediaelement-noflash_silverlight.patch new file mode 100644 index 0000000..c0b23ee --- /dev/null +++ b/wordpress-4.2-mediaelement-noflash_silverlight.patch @@ -0,0 +1,18 @@ +--- wordpress/wp-includes/js/mediaelement/mediaelement-and-player.min.js.orig 2014-12-22 06:38:12.716225091 +0100 ++++ wordpress/wp-includes/js/mediaelement/mediaelement-and-player.min.js 2014-12-22 06:39:30.045517161 +0100 +@@ -12,7 +12,7 @@ + * License: MIT + * + */ +-function onYouTubePlayerAPIReady(){mejs.YouTubeApi.iFrameReady()}function onYouTubePlayerReady(a){mejs.YouTubeApi.flashReady(a)}var mejs=mejs||{};mejs.version="2.16.4",mejs.meIndex=0,mejs.plugins={silverlight:[{version:[3,0],types:["video/mp4","video/m4v","video/mov","video/wmv","audio/wma","audio/m4a","audio/mp3","audio/wav","audio/mpeg"]}],flash:[{version:[9,0,124],types:["video/mp4","video/m4v","video/mov","video/flv","video/rtmp","video/x-flv","audio/flv","audio/x-flv","audio/mp3","audio/m4a","audio/mpeg","video/youtube","video/x-youtube","application/x-mpegURL"]}],youtube:[{version:null,types:["video/youtube","video/x-youtube","audio/youtube","audio/x-youtube"]}],vimeo:[{version:null,types:["video/vimeo","video/x-vimeo"]}]},mejs.Utility={encodeUrl:function(a){return encodeURIComponent(a)},escapeHTML:function(a){return a.toString().split("&").join("&").split("<").join("<").split('"').join(""")},absolutizeUrl:function(a){var b=document.createElement("div");return b.innerHTML='x',b.firstChild.href},getScriptPath:function(a){for(var b,c,d,e,f,g,h=0,i="",j="",k=document.getElementsByTagName("script"),l=k.length,m=a.length;l>h;h++){for(e=k[h].src,c=e.lastIndexOf("/"),c>-1?(g=e.substring(c+1),f=e.substring(0,c+1)):(g=e,f=""),b=0;m>b;b++)if(j=a[b],d=g.indexOf(j),d>-1){i=f;break}if(""!==i)break}return i},secondsToTimeCode:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=Math.floor(a/3600)%24,f=Math.floor(a/60)%60,g=Math.floor(a%60),h=Math.floor((a%1*d).toFixed(3)),i=(b||e>0?(10>e?"0"+e:e)+":":"")+(10>f?"0"+f:f)+":"+(10>g?"0"+g:g)+(c?":"+(10>h?"0"+h:h):"");return i},timeCodeToSeconds:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=a.split(":"),f=parseInt(e[0],10),g=parseInt(e[1],10),h=parseInt(e[2],10),i=0,j=0;return c&&(i=parseInt(e[3])/d),j=3600*f+60*g+h+i},convertSMPTEtoSeconds:function(a){if("string"!=typeof a)return!1;a=a.replace(",",".");var b=0,c=-1!=a.indexOf(".")?a.split(".")[1].length:0,d=1;a=a.split(":").reverse();for(var e=0;e0&&(d=Math.pow(60,e)),b+=Number(a[e])*d;return Number(b.toFixed(c))},removeSwf:function(a){var b=document.getElementById(a);b&&/object|embed/i.test(b.nodeName)&&(mejs.MediaFeatures.isIE?(b.style.display="none",function(){4==b.readyState?mejs.Utility.removeObjectInIE(a):setTimeout(arguments.callee,10)}()):b.parentNode.removeChild(b))},removeObjectInIE:function(a){var b=document.getElementById(a);if(b){for(var c in b)"function"==typeof b[c]&&(b[c]=null);b.parentNode.removeChild(b)}}},mejs.PluginDetector={hasPluginVersion:function(a,b){var c=this.plugins[a];return b[1]=b[1]||0,b[2]=b[2]||0,c[0]>b[0]||c[0]==b[0]&&c[1]>b[1]||c[0]==b[0]&&c[1]==b[1]&&c[2]>=b[2]?!0:!1},nav:window.navigator,ua:window.navigator.userAgent.toLowerCase(),plugins:[],addPlugin:function(a,b,c,d,e){this.plugins[a]=this.detectPlugin(b,c,d,e)},detectPlugin:function(a,b,c,d){var e,f,g,h=[0,0,0];if("undefined"!=typeof this.nav.plugins&&"object"==typeof this.nav.plugins[a]){if(e=this.nav.plugins[a].description,e&&("undefined"==typeof this.nav.mimeTypes||!this.nav.mimeTypes[b]||this.nav.mimeTypes[b].enabledPlugin))for(h=e.replace(a,"").replace(/^\s+/,"").replace(/\sr/gi,".").split("."),f=0;f0;)this.removeChild(b[0]);if("string"==typeof a)this.src=a;else{var c,d;for(c=0;c0&&null!==q[0].url&&this.getTypeFromFile(q[0].url).indexOf("audio")>-1&&(r.isVideo=!1),mejs.MediaFeatures.isBustedAndroid&&(a.canPlayType=function(a){return null!==a.match(/video\/(mp4|m4v)/gi)?"maybe":""}),!(!c||"auto"!==b.mode&&"auto_plugin"!==b.mode&&"native"!==b.mode||mejs.MediaFeatures.isBustedNativeHTTPS&&b.httpsBasicAuthSite===!0)){for(d||(o=document.createElement(r.isVideo?"video":"audio"),a.parentNode.insertBefore(o,a),a.style.display="none",r.htmlMediaElement=a=o),f=0;f0&&(r.url=q[0].url),r)},formatType:function(a,b){return a&&!b?this.getTypeFromFile(a):b&&~b.indexOf(";")?b.substr(0,b.indexOf(";")):b},getTypeFromFile:function(a){a=a.split("?")[0];var b=a.substring(a.lastIndexOf(".")+1).toLowerCase();return(/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video":"audio")+"/"+this.getTypeFromExtension(b)},getTypeFromExtension:function(a){switch(a){case"mp4":case"m4v":case"m4a":return"mp4";case"webm":case"webma":case"webmv":return"webm";case"ogg":case"oga":case"ogv":return"ogg";default:return a}},createErrorMessage:function(a,b,c){var d=a.htmlMediaElement,e=document.createElement("div");e.className="me-cannotplay";try{e.style.width=d.width+"px",e.style.height=d.height+"px"}catch(f){}e.innerHTML=b.customError?b.customError:""!==c?'':''+mejs.i18n.t("Download File")+"",d.parentNode.insertBefore(e,d),d.style.display="none",b.error(d)},createPlugin:function(a,b,c,d,e,f){var g,h,i,j=a.htmlMediaElement,k=1,l=1,m="me_"+a.method+"_"+mejs.meIndex++,n=new mejs.PluginMediaElement(m,a.method,a.url),o=document.createElement("div");n.tagName=j.tagName;for(var p=0;p0?b.pluginWidth:b.videoWidth>0?b.videoWidth:null!==j.getAttribute("width")?j.getAttribute("width"):b.defaultVideoWidth,l=b.pluginHeight>0?b.pluginHeight:b.videoHeight>0?b.videoHeight:null!==j.getAttribute("height")?j.getAttribute("height"):b.defaultVideoHeight,k=mejs.Utility.encodeUrl(k),l=mejs.Utility.encodeUrl(l)):b.enablePluginDebug&&(k=320,l=240),n.success=b.success,mejs.MediaPluginBridge.registerPluginElement(m,n,j),o.className="me-plugin",o.id=m+"_container",a.isVideo?j.parentNode.insertBefore(o,j):document.body.insertBefore(o,document.body.childNodes[0]),i=["id="+m,"jsinitfunction=mejs.MediaPluginBridge.initPlugin","jscallbackfunction=mejs.MediaPluginBridge.fireEvent","isvideo="+(a.isVideo?"true":"false"),"autoplay="+(d?"true":"false"),"preload="+e,"width="+k,"startvolume="+b.startVolume,"timerrate="+b.timerRate,"flashstreamer="+b.flashStreamer,"height="+l,"pseudostreamstart="+b.pseudoStreamingStartQueryParam],null!==a.url&&i.push("flash"==a.method?"file="+mejs.Utility.encodeUrl(a.url):"file="+a.url),b.enablePluginDebug&&i.push("debug=true"),b.enablePluginSmoothing&&i.push("smoothing=true"),b.enablePseudoStreaming&&i.push("pseudostreaming=true"),f&&i.push("controls=true"),b.pluginVars&&(i=i.concat(b.pluginVars)),a.method){case"silverlight":o.innerHTML='';break;case"flash":mejs.MediaFeatures.isIE?(g=document.createElement("div"),o.appendChild(g),g.outerHTML=''):o.innerHTML='';break;case"youtube":var r;-1!=a.url.lastIndexOf("youtu.be")?(r=a.url.substr(a.url.lastIndexOf("/")+1),-1!=r.indexOf("?")&&(r=r.substr(0,r.indexOf("?")))):r=a.url.substr(a.url.lastIndexOf("=")+1),youtubeSettings={container:o,containerId:o.id,pluginMediaElement:n,pluginId:m,videoId:r,height:l,width:k},mejs.PluginDetector.hasPluginVersion("flash",[10,0,0])?mejs.YouTubeApi.createFlash(youtubeSettings):mejs.YouTubeApi.enqueueIframe(youtubeSettings);break;case"vimeo":var s=m+"_player";if(n.vimeoid=a.url.substr(a.url.lastIndexOf("/")+1),o.innerHTML='',"function"==typeof $f){var t=$f(o.childNodes[0]);t.addEvent("ready",function(){function a(a,b,c,d){var e={type:c,target:b};"timeupdate"==c&&(b.currentTime=e.currentTime=d.seconds,b.duration=e.duration=d.duration),b.dispatchEvent(e.type,e)}t.playVideo=function(){t.api("play")},t.stopVideo=function(){t.api("unload")},t.pauseVideo=function(){t.api("pause")},t.seekTo=function(a){t.api("seekTo",a)},t.setVolume=function(a){t.api("setVolume",a)},t.setMuted=function(a){a?(t.lastVolume=t.api("getVolume"),t.api("setVolume",0)):(t.api("setVolume",t.lastVolume),delete t.lastVolume)},t.addEvent("play",function(){a(t,n,"play"),a(t,n,"playing")}),t.addEvent("pause",function(){a(t,n,"pause")}),t.addEvent("finish",function(){a(t,n,"ended")}),t.addEvent("playProgress",function(b){a(t,n,"timeupdate",b)}),n.pluginElement=o,n.pluginApi=t,mejs.MediaPluginBridge.initPlugin(m)})}else console.warn("You need to include froogaloop for vimeo to work")}return j.style.display="none",j.removeAttribute("autoplay"),n},updateNative:function(a,b){var c,d=a.htmlMediaElement;for(c in mejs.HtmlMediaElement)d[c]=mejs.HtmlMediaElement[c];return b.success(d,d),d}},mejs.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(){if(!this.isIframeStarted){var a=document.createElement("script");a.src="//www.youtube.com/player_api";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(),this.iframeQueue.push(a))},createIframe:function(a){var b=a.pluginMediaElement,c=new YT.Player(a.containerId,{height:a.height,width:a.width,videoId:a.videoId,playerVars:{controls:0},events:{onReady:function(){a.pluginMediaElement.pluginApi=c,mejs.MediaPluginBridge.initPlugin(a.pluginId),setInterval(function(){mejs.YouTubeApi.createEvent(c,b,"timeupdate")},250)},onStateChange:function(a){mejs.YouTubeApi.handleStateChange(a.data,c,b)}}})},createEvent:function(a,b,c){var d={type:c,target:b};if(a&&a.getDuration){b.currentTime=d.currentTime=a.getCurrentTime(),b.duration=d.duration=a.getDuration(),d.paused=b.paused,d.ended=b.ended,d.muted=a.isMuted(),d.volume=a.getVolume()/100,d.bytesTotal=a.getVideoBytesTotal(),d.bufferedBytes=a.getVideoBytesLoaded();var e=d.bufferedBytes/d.bytesTotal*d.duration;d.target.buffered=d.buffered={start:function(){return 0},end:function(){return e},length:1}}b.dispatchEvent(d.type,d)},iFrameReady:function(){for(this.isLoaded=!0,this.isIframeLoaded=!0;this.iframeQueue.length>0;){var a=this.iframeQueue.pop();this.createIframe(a)}},flashPlayers:{},createFlash:function(a){this.flashPlayers[a.pluginId]=a;var b,c="//www.youtube.com/apiplayer?enablejsapi=1&playerapiid="+a.pluginId+"&version=3&autoplay=0&controls=0&modestbranding=1&loop=0";mejs.MediaFeatures.isIE?(b=document.createElement("div"),a.container.appendChild(b),b.outerHTML=''):a.container.innerHTML=''},flashReady:function(a){var b=this.flashPlayers[a],c=document.getElementById(a),d=b.pluginMediaElement;d.pluginApi=d.pluginElement=c,mejs.MediaPluginBridge.initPlugin(a),c.cueVideoById(b.videoId);var e=b.containerId+"_callback";window[e]=function(a){mejs.YouTubeApi.handleStateChange(a,c,d)},c.addEventListener("onStateChange",e),setInterval(function(){mejs.YouTubeApi.createEvent(c,d,"timeupdate")},250),mejs.YouTubeApi.createEvent(c,d,"canplay")},handleStateChange:function(a,b,c){switch(a){case-1:c.paused=!0,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"loadedmetadata");break;case 0:c.paused=!1,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"ended");break;case 1:c.paused=!1,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"play"),mejs.YouTubeApi.createEvent(b,c,"playing");break;case 2:c.paused=!0,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"pause");break;case 3:mejs.YouTubeApi.createEvent(b,c,"progress");break;case 5:}}},window.mejs=mejs,window.MediaElement=mejs.MediaElement,function(a,b){"use strict";var c={locale:{language:b.i18n&&b.i18n.locale.language||"",strings:b.i18n&&b.i18n.locale.strings||{}},ietf_lang_regex:/^(x\-)?[a-z]{2,}(\-\w{2,})?(\-\w{2,})?$/,methods:{}};c.getLanguage=function(){var a=c.locale.language||window.navigator.userLanguage||window.navigator.language;return c.ietf_lang_regex.exec(a)?a:null},"undefined"!=typeof mejsL10n&&(c.locale.language=mejsL10n.language),c.methods.checkPlain=function(a){var b,c,d={"&":"&",'"':""","<":"<",">":">"};a=String(a);for(b in d)d.hasOwnProperty(b)&&(c=new RegExp(b,"g"),a=a.replace(c,d[b]));return a},c.methods.t=function(a,b){return c.locale.strings&&c.locale.strings[b.context]&&c.locale.strings[b.context][a]&&(a=c.locale.strings[b.context][a]),c.methods.checkPlain(a)},c.t=function(a,b){if("string"==typeof a&&a.length>0){var d=c.getLanguage();return b=b||{context:d},c.methods.t(a,b)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=c}(document,mejs),function(a){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(mejs.i18n.locale.strings),/*! ++function onYouTubePlayerAPIReady(){mejs.YouTubeApi.iFrameReady()}function onYouTubePlayerReady(a){mejs.YouTubeApi.flashReady(a)}var mejs=mejs||{};mejs.version="2.16.4",mejs.meIndex=0,mejs.plugins={silverlight:[{version:[3,0],types:["video/mp4","video/m4v","video/mov","video/wmv","audio/wma","audio/m4a","audio/mp3","audio/wav","audio/mpeg"]}],flash:[{version:[9,0,124],types:["video/mp4","video/m4v","video/mov","video/flv","video/rtmp","video/x-flv","audio/flv","audio/x-flv","audio/mp3","audio/m4a","audio/mpeg","video/youtube","video/x-youtube","application/x-mpegURL"]}],youtube:[{version:null,types:["video/youtube","video/x-youtube","audio/youtube","audio/x-youtube"]}],vimeo:[{version:null,types:["video/vimeo","video/x-vimeo"]}]},mejs.Utility={encodeUrl:function(a){return encodeURIComponent(a)},escapeHTML:function(a){return a.toString().split("&").join("&").split("<").join("<").split('"').join(""")},absolutizeUrl:function(a){var b=document.createElement("div");return b.innerHTML='x',b.firstChild.href},getScriptPath:function(a){for(var b,c,d,e,f,g,h=0,i="",j="",k=document.getElementsByTagName("script"),l=k.length,m=a.length;l>h;h++){for(e=k[h].src,c=e.lastIndexOf("/"),c>-1?(g=e.substring(c+1),f=e.substring(0,c+1)):(g=e,f=""),b=0;m>b;b++)if(j=a[b],d=g.indexOf(j),d>-1){i=f;break}if(""!==i)break}return i},secondsToTimeCode:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=Math.floor(a/3600)%24,f=Math.floor(a/60)%60,g=Math.floor(a%60),h=Math.floor((a%1*d).toFixed(3)),i=(b||e>0?(10>e?"0"+e:e)+":":"")+(10>f?"0"+f:f)+":"+(10>g?"0"+g:g)+(c?":"+(10>h?"0"+h:h):"");return i},timeCodeToSeconds:function(a,b,c,d){"undefined"==typeof c?c=!1:"undefined"==typeof d&&(d=25);var e=a.split(":"),f=parseInt(e[0],10),g=parseInt(e[1],10),h=parseInt(e[2],10),i=0,j=0;return c&&(i=parseInt(e[3])/d),j=3600*f+60*g+h+i},convertSMPTEtoSeconds:function(a){if("string"!=typeof a)return!1;a=a.replace(",",".");var b=0,c=-1!=a.indexOf(".")?a.split(".")[1].length:0,d=1;a=a.split(":").reverse();for(var e=0;e0&&(d=Math.pow(60,e)),b+=Number(a[e])*d;return Number(b.toFixed(c))},removeSwf:function(a){var b=document.getElementById(a);b&&/object|embed/i.test(b.nodeName)&&(mejs.MediaFeatures.isIE?(b.style.display="none",function(){4==b.readyState?mejs.Utility.removeObjectInIE(a):setTimeout(arguments.callee,10)}()):b.parentNode.removeChild(b))},removeObjectInIE:function(a){var b=document.getElementById(a);if(b){for(var c in b)"function"==typeof b[c]&&(b[c]=null);b.parentNode.removeChild(b)}}},mejs.PluginDetector={hasPluginVersion:function(a,b){var c=this.plugins[a];return b[1]=b[1]||0,b[2]=b[2]||0,c[0]>b[0]||c[0]==b[0]&&c[1]>b[1]||c[0]==b[0]&&c[1]==b[1]&&c[2]>=b[2]?!0:!1},nav:window.navigator,ua:window.navigator.userAgent.toLowerCase(),plugins:[],addPlugin:function(a,b,c,d,e){this.plugins[a]=this.detectPlugin(b,c,d,e)},detectPlugin:function(a,b,c,d){var e,f,g,h=[0,0,0];if("undefined"!=typeof this.nav.plugins&&"object"==typeof this.nav.plugins[a]){if(e=this.nav.plugins[a].description,e&&("undefined"==typeof this.nav.mimeTypes||!this.nav.mimeTypes[b]||this.nav.mimeTypes[b].enabledPlugin))for(h=e.replace(a,"").replace(/^\s+/,"").replace(/\sr/gi,".").split("."),f=0;f0;)this.removeChild(b[0]);if("string"==typeof a)this.src=a;else{var c,d;for(c=0;c0&&null!==q[0].url&&this.getTypeFromFile(q[0].url).indexOf("audio")>-1&&(r.isVideo=!1),mejs.MediaFeatures.isBustedAndroid&&(a.canPlayType=function(a){return null!==a.match(/video\/(mp4|m4v)/gi)?"maybe":""}),!(!c||"auto"!==b.mode&&"auto_plugin"!==b.mode&&"native"!==b.mode||mejs.MediaFeatures.isBustedNativeHTTPS&&b.httpsBasicAuthSite===!0)){for(d||(o=document.createElement(r.isVideo?"video":"audio"),a.parentNode.insertBefore(o,a),a.style.display="none",r.htmlMediaElement=a=o),f=0;f0&&(r.url=q[0].url),r)},formatType:function(a,b){return a&&!b?this.getTypeFromFile(a):b&&~b.indexOf(";")?b.substr(0,b.indexOf(";")):b},getTypeFromFile:function(a){a=a.split("?")[0];var b=a.substring(a.lastIndexOf(".")+1).toLowerCase();return(/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video":"audio")+"/"+this.getTypeFromExtension(b)},getTypeFromExtension:function(a){switch(a){case"mp4":case"m4v":case"m4a":return"mp4";case"webm":case"webma":case"webmv":return"webm";case"ogg":case"oga":case"ogv":return"ogg";default:return a}},createErrorMessage:function(a,b,c){var d=a.htmlMediaElement,e=document.createElement("div");e.className="me-cannotplay";try{e.style.width=d.width+"px",e.style.height=d.height+"px"}catch(f){}e.innerHTML=b.customError?b.customError:""!==c?'':''+mejs.i18n.t("Download File")+"",d.parentNode.insertBefore(e,d),d.style.display="none",b.error(d)},createPlugin:function(a,b,c,d,e,f){var g,h,i,j=a.htmlMediaElement,k=1,l=1,m="me_"+a.method+"_"+mejs.meIndex++,n=new mejs.PluginMediaElement(m,a.method,a.url),o=document.createElement("div");n.tagName=j.tagName;for(var p=0;p0?b.pluginWidth:b.videoWidth>0?b.videoWidth:null!==j.getAttribute("width")?j.getAttribute("width"):b.defaultVideoWidth,l=b.pluginHeight>0?b.pluginHeight:b.videoHeight>0?b.videoHeight:null!==j.getAttribute("height")?j.getAttribute("height"):b.defaultVideoHeight,k=mejs.Utility.encodeUrl(k),l=mejs.Utility.encodeUrl(l)):b.enablePluginDebug&&(k=320,l=240),n.success=b.success,mejs.MediaPluginBridge.registerPluginElement(m,n,j),o.className="me-plugin",o.id=m+"_container",a.isVideo?j.parentNode.insertBefore(o,j):document.body.insertBefore(o,document.body.childNodes[0]),i=["id="+m,"jsinitfunction=mejs.MediaPluginBridge.initPlugin","jscallbackfunction=mejs.MediaPluginBridge.fireEvent","isvideo="+(a.isVideo?"true":"false"),"autoplay="+(d?"true":"false"),"preload="+e,"width="+k,"startvolume="+b.startVolume,"timerrate="+b.timerRate,"flashstreamer="+b.flashStreamer,"height="+l,"pseudostreamstart="+b.pseudoStreamingStartQueryParam],null!==a.url&&i.push("flash"==a.method?"file="+mejs.Utility.encodeUrl(a.url):"file="+a.url),b.enablePluginDebug&&i.push("debug=true"),b.enablePluginSmoothing&&i.push("smoothing=true"),b.enablePseudoStreaming&&i.push("pseudostreaming=true"),f&&i.push("controls=true"),b.pluginVars&&(i=i.concat(b.pluginVars)),a.method){case"silverlight":o.innerHTML='';break;case"flash":mejs.MediaFeatures.isIE?(g=document.createElement("div"),o.appendChild(g),g.outerHTML=''):o.innerHTML='';break;case"youtube":var r;-1!=a.url.lastIndexOf("youtu.be")?(r=a.url.substr(a.url.lastIndexOf("/")+1),-1!=r.indexOf("?")&&(r=r.substr(0,r.indexOf("?")))):r=a.url.substr(a.url.lastIndexOf("=")+1),youtubeSettings={container:o,containerId:o.id,pluginMediaElement:n,pluginId:m,videoId:r,height:l,width:k},mejs.PluginDetector.hasPluginVersion("flash",[10,0,0])?mejs.YouTubeApi.createFlash(youtubeSettings):mejs.YouTubeApi.enqueueIframe(youtubeSettings);break;case"vimeo":var s=m+"_player";if(n.vimeoid=a.url.substr(a.url.lastIndexOf("/")+1),o.innerHTML='',"function"==typeof $f){var t=$f(o.childNodes[0]);t.addEvent("ready",function(){function a(a,b,c,d){var e={type:c,target:b};"timeupdate"==c&&(b.currentTime=e.currentTime=d.seconds,b.duration=e.duration=d.duration),b.dispatchEvent(e.type,e)}t.playVideo=function(){t.api("play")},t.stopVideo=function(){t.api("unload")},t.pauseVideo=function(){t.api("pause")},t.seekTo=function(a){t.api("seekTo",a)},t.setVolume=function(a){t.api("setVolume",a)},t.setMuted=function(a){a?(t.lastVolume=t.api("getVolume"),t.api("setVolume",0)):(t.api("setVolume",t.lastVolume),delete t.lastVolume)},t.addEvent("play",function(){a(t,n,"play"),a(t,n,"playing")}),t.addEvent("pause",function(){a(t,n,"pause")}),t.addEvent("finish",function(){a(t,n,"ended")}),t.addEvent("playProgress",function(b){a(t,n,"timeupdate",b)}),n.pluginElement=o,n.pluginApi=t,mejs.MediaPluginBridge.initPlugin(m)})}else console.warn("You need to include froogaloop for vimeo to work")}return j.style.display="none",j.removeAttribute("autoplay"),n},updateNative:function(a,b){var c,d=a.htmlMediaElement;for(c in mejs.HtmlMediaElement)d[c]=mejs.HtmlMediaElement[c];return b.success(d,d),d}},mejs.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(){if(!this.isIframeStarted){var a=document.createElement("script");a.src="//www.youtube.com/player_api";var b=document.getElementsByTagName("script")[0];b.parentNode.insertBefore(a,b),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(),this.iframeQueue.push(a))},createIframe:function(a){var b=a.pluginMediaElement,c=new YT.Player(a.containerId,{height:a.height,width:a.width,videoId:a.videoId,playerVars:{controls:0},events:{onReady:function(){a.pluginMediaElement.pluginApi=c,mejs.MediaPluginBridge.initPlugin(a.pluginId),setInterval(function(){mejs.YouTubeApi.createEvent(c,b,"timeupdate")},250)},onStateChange:function(a){mejs.YouTubeApi.handleStateChange(a.data,c,b)}}})},createEvent:function(a,b,c){var d={type:c,target:b};if(a&&a.getDuration){b.currentTime=d.currentTime=a.getCurrentTime(),b.duration=d.duration=a.getDuration(),d.paused=b.paused,d.ended=b.ended,d.muted=a.isMuted(),d.volume=a.getVolume()/100,d.bytesTotal=a.getVideoBytesTotal(),d.bufferedBytes=a.getVideoBytesLoaded();var e=d.bufferedBytes/d.bytesTotal*d.duration;d.target.buffered=d.buffered={start:function(){return 0},end:function(){return e},length:1}}b.dispatchEvent(d.type,d)},iFrameReady:function(){for(this.isLoaded=!0,this.isIframeLoaded=!0;this.iframeQueue.length>0;){var a=this.iframeQueue.pop();this.createIframe(a)}},flashPlayers:{},createFlash:function(a){this.flashPlayers[a.pluginId]=a;var b,c="//www.youtube.com/apiplayer?enablejsapi=1&playerapiid="+a.pluginId+"&version=3&autoplay=0&controls=0&modestbranding=1&loop=0";mejs.MediaFeatures.isIE?(b=document.createElement("div"),a.container.appendChild(b),b.outerHTML=''):a.container.innerHTML=''},flashReady:function(a){var b=this.flashPlayers[a],c=document.getElementById(a),d=b.pluginMediaElement;d.pluginApi=d.pluginElement=c,mejs.MediaPluginBridge.initPlugin(a),c.cueVideoById(b.videoId);var e=b.containerId+"_callback";window[e]=function(a){mejs.YouTubeApi.handleStateChange(a,c,d)},c.addEventListener("onStateChange",e),setInterval(function(){mejs.YouTubeApi.createEvent(c,d,"timeupdate")},250),mejs.YouTubeApi.createEvent(c,d,"canplay")},handleStateChange:function(a,b,c){switch(a){case-1:c.paused=!0,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"loadedmetadata");break;case 0:c.paused=!1,c.ended=!0,mejs.YouTubeApi.createEvent(b,c,"ended");break;case 1:c.paused=!1,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"play"),mejs.YouTubeApi.createEvent(b,c,"playing");break;case 2:c.paused=!0,c.ended=!1,mejs.YouTubeApi.createEvent(b,c,"pause");break;case 3:mejs.YouTubeApi.createEvent(b,c,"progress");break;case 5:}}},window.mejs=mejs,window.MediaElement=mejs.MediaElement,function(a,b){"use strict";var c={locale:{language:b.i18n&&b.i18n.locale.language||"",strings:b.i18n&&b.i18n.locale.strings||{}},ietf_lang_regex:/^(x\-)?[a-z]{2,}(\-\w{2,})?(\-\w{2,})?$/,methods:{}};c.getLanguage=function(){var a=c.locale.language||window.navigator.userLanguage||window.navigator.language;return c.ietf_lang_regex.exec(a)?a:null},"undefined"!=typeof mejsL10n&&(c.locale.language=mejsL10n.language),c.methods.checkPlain=function(a){var b,c,d={"&":"&",'"':""","<":"<",">":">"};a=String(a);for(b in d)d.hasOwnProperty(b)&&(c=new RegExp(b,"g"),a=a.replace(c,d[b]));return a},c.methods.t=function(a,b){return c.locale.strings&&c.locale.strings[b.context]&&c.locale.strings[b.context][a]&&(a=c.locale.strings[b.context][a]),c.methods.checkPlain(a)},c.t=function(a,b){if("string"==typeof a&&a.length>0){var d=c.getLanguage();return b=b||{context:d},c.methods.t(a,b)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=c}(document,mejs),function(a){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(mejs.i18n.locale.strings),/*! + * + * MediaElementPlayer + * http://mediaelementjs.com/ +@@ -25,4 +25,4 @@ + * + */ + "undefined"!=typeof jQuery?mejs.$=jQuery:"undefined"!=typeof ender&&(mejs.$=ender),function(a){mejs.MepDefaults={poster:"",showPosterWhenEnded:!1,defaultVideoWidth:480,defaultVideoHeight:270,videoWidth:-1,videoHeight:-1,defaultAudioWidth:400,defaultAudioHeight:30,defaultSeekBackwardInterval:function(a){return.05*a.duration},defaultSeekForwardInterval:function(a){return.05*a.duration},setDimensions:!0,audioWidth:-1,audioHeight:-1,startVolume:.8,loop:!1,autoRewind:!0,enableAutosize:!0,alwaysShowHours:!1,showTimecodeFrameCount:!1,framesPerSecond:25,autosizeProgress:!0,alwaysShowControls:!1,hideVideoControlsOnLoad:!1,clickToPlayPause:!0,iPadUseNativeControls:!1,iPhoneUseNativeControls:!1,AndroidUseNativeControls:!1,features:["playpause","current","progress","duration","tracks","volume","fullscreen"],isVideo:!0,enableKeyboard:!0,pauseOtherPlayers:!0,keyActions:[{keys:[32,179],action:function(a,b){b.paused||b.ended?a.play():a.pause()}},{keys:[38],action:function(a,b){a.container.find(".mejs-volume-slider").css("display","block"),a.isVideo&&(a.showControls(),a.startControlsTimer());var c=Math.min(b.volume+.1,1);b.setVolume(c)}},{keys:[40],action:function(a,b){a.container.find(".mejs-volume-slider").css("display","block"),a.isVideo&&(a.showControls(),a.startControlsTimer());var c=Math.max(b.volume-.1,0);b.setVolume(c)}},{keys:[37,227],action:function(a,b){if(!isNaN(b.duration)&&b.duration>0){a.isVideo&&(a.showControls(),a.startControlsTimer());var c=Math.max(b.currentTime-a.options.defaultSeekBackwardInterval(b),0);b.setCurrentTime(c)}}},{keys:[39,228],action:function(a,b){if(!isNaN(b.duration)&&b.duration>0){a.isVideo&&(a.showControls(),a.startControlsTimer());var c=Math.min(b.currentTime+a.options.defaultSeekForwardInterval(b),b.duration);b.setCurrentTime(c)}}},{keys:[70],action:function(a){"undefined"!=typeof a.enterFullScreen&&(a.isFullScreen?a.exitFullScreen():a.enterFullScreen())}},{keys:[77],action:function(a){a.container.find(".mejs-volume-slider").css("display","block"),a.isVideo&&(a.showControls(),a.startControlsTimer()),a.setMuted(a.media.muted?!1:!0)}}]},mejs.mepIndex=0,mejs.players={},mejs.MediaElementPlayer=function(b,c){if(!(this instanceof mejs.MediaElementPlayer))return new mejs.MediaElementPlayer(b,c);var d=this;return d.$media=d.$node=a(b),d.node=d.media=d.$media[0],"undefined"!=typeof d.node.player?d.node.player:(d.node.player=d,"undefined"==typeof c&&(c=d.$node.data("mejsoptions")),d.options=a.extend({},mejs.MepDefaults,c),d.id="mep_"+mejs.mepIndex++,mejs.players[d.id]=d,d.init(),d)},mejs.MediaElementPlayer.prototype={hasFocus:!1,controlsAreVisible:!0,init:function(){var b=this,c=mejs.MediaFeatures,d=a.extend(!0,{},b.options,{success:function(a,c){b.meReady(a,c)},error:function(a){b.handleError(a)}}),e=b.media.tagName.toLowerCase();if(b.isDynamic="audio"!==e&&"video"!==e,b.isVideo=b.isDynamic?b.options.isVideo:"audio"!==e&&b.options.isVideo,c.isiPad&&b.options.iPadUseNativeControls||c.isiPhone&&b.options.iPhoneUseNativeControls)b.$media.attr("controls","controls"),c.isiPad&&null!==b.media.getAttribute("autoplay")&&b.play();else if(c.isAndroid&&b.options.AndroidUseNativeControls);else{b.$media.removeAttr("controls");var f=mejs.i18n.t(b.isVideo?"Video Player":"Audio Player");if(a(''+f+"").insertBefore(b.$media),b.container=a('
').addClass(b.$media[0].className).insertBefore(b.$media).focus(function(){if(!b.controlsAreVisible){b.showControls(!0);var a=b.container.find(".mejs-playpause-button > button");a.focus()}}),b.container.addClass((c.isAndroid?"mejs-android ":"")+(c.isiOS?"mejs-ios ":"")+(c.isiPad?"mejs-ipad ":"")+(c.isiPhone?"mejs-iphone ":"")+(b.isVideo?"mejs-video ":"mejs-audio ")),c.isiOS){var g=b.$media.clone();b.container.find(".mejs-mediaelement").append(g),b.$media.remove(),b.$node=b.$media=g,b.node=b.media=g[0]}else b.container.find(".mejs-mediaelement").append(b.$media);b.controls=b.container.find(".mejs-controls"),b.layers=b.container.find(".mejs-layers");var h=b.isVideo?"video":"audio",i=h.substring(0,1).toUpperCase()+h.substring(1);b.width=b.options[h+"Width"]>0||b.options[h+"Width"].toString().indexOf("%")>-1?b.options[h+"Width"]:""!==b.media.style.width&&null!==b.media.style.width?b.media.style.width:null!==b.media.getAttribute("width")?b.$media.attr("width"):b.options["default"+i+"Width"],b.height=b.options[h+"Height"]>0||b.options[h+"Height"].toString().indexOf("%")>-1?b.options[h+"Height"]:""!==b.media.style.height&&null!==b.media.style.height?b.media.style.height:null!==b.$media[0].getAttribute("height")?b.$media.attr("height"):b.options["default"+i+"Height"],b.setPlayerSize(b.width,b.height),d.pluginWidth=b.width,d.pluginHeight=b.height}mejs.MediaElement(b.$media[0],d),"undefined"!=typeof b.container&&b.controlsAreVisible&&b.container.trigger("controlsshown")},showControls:function(a){var b=this;a="undefined"==typeof a||a,b.controlsAreVisible||(a?(b.controls.css("visibility","visible").stop(!0,!0).fadeIn(200,function(){b.controlsAreVisible=!0,b.container.trigger("controlsshown")}),b.container.find(".mejs-control").css("visibility","visible").stop(!0,!0).fadeIn(200,function(){b.controlsAreVisible=!0})):(b.controls.css("visibility","visible").css("display","block"),b.container.find(".mejs-control").css("visibility","visible").css("display","block"),b.controlsAreVisible=!0,b.container.trigger("controlsshown")),b.setControlsSize())},hideControls:function(b){var c=this;b="undefined"==typeof b||b,!c.controlsAreVisible||c.options.alwaysShowControls||c.keyboardAction||(b?(c.controls.stop(!0,!0).fadeOut(200,function(){a(this).css("visibility","hidden").css("display","block"),c.controlsAreVisible=!1,c.container.trigger("controlshidden")}),c.container.find(".mejs-control").stop(!0,!0).fadeOut(200,function(){a(this).css("visibility","hidden").css("display","block")})):(c.controls.css("visibility","hidden").css("display","block"),c.container.find(".mejs-control").css("visibility","hidden").css("display","block"),c.controlsAreVisible=!1,c.container.trigger("controlshidden")))},controlsTimer:null,startControlsTimer:function(a){var b=this;a="undefined"!=typeof a?a:1500,b.killControlsTimer("start"),b.controlsTimer=setTimeout(function(){b.hideControls(),b.killControlsTimer("hide")},a)},killControlsTimer:function(){var a=this;null!==a.controlsTimer&&(clearTimeout(a.controlsTimer),delete a.controlsTimer,a.controlsTimer=null)},controlsEnabled:!0,disableControls:function(){var a=this;a.killControlsTimer(),a.hideControls(!1),this.controlsEnabled=!1},enableControls:function(){var a=this;a.showControls(!1),a.controlsEnabled=!0},meReady:function(b,c){var d,e,f=this,g=mejs.MediaFeatures,h=c.getAttribute("autoplay"),i=!("undefined"==typeof h||null===h||"false"===h);if(!f.created){if(f.created=!0,f.media=b,f.domNode=c,!(g.isAndroid&&f.options.AndroidUseNativeControls||g.isiPad&&f.options.iPadUseNativeControls||g.isiPhone&&f.options.iPhoneUseNativeControls)){f.buildposter(f,f.controls,f.layers,f.media),f.buildkeyboard(f,f.controls,f.layers,f.media),f.buildoverlays(f,f.controls,f.layers,f.media),f.findTracks();for(d in f.options.features)if(e=f.options.features[d],f["build"+e])try{f["build"+e](f,f.controls,f.layers,f.media)}catch(j){}f.container.trigger("controlsready"),f.setPlayerSize(f.width,f.height),f.setControlsSize(),f.isVideo&&(mejs.MediaFeatures.hasTouch?f.$media.bind("touchstart",function(){f.controlsAreVisible?f.hideControls(!1):f.controlsEnabled&&f.showControls(!1)}):(f.clickToPlayPauseCallback=function(){f.options.clickToPlayPause&&(f.media.paused?f.play():f.pause())},f.media.addEventListener("click",f.clickToPlayPauseCallback,!1),f.container.bind("mouseenter mouseover",function(){f.controlsEnabled&&(f.options.alwaysShowControls||(f.killControlsTimer("enter"),f.showControls(),f.startControlsTimer(2500)))}).bind("mousemove",function(){f.controlsEnabled&&(f.controlsAreVisible||f.showControls(),f.options.alwaysShowControls||f.startControlsTimer(2500))}).bind("mouseleave",function(){f.controlsEnabled&&(f.media.paused||f.options.alwaysShowControls||f.startControlsTimer(1e3))})),f.options.hideVideoControlsOnLoad&&f.hideControls(!1),i&&!f.options.alwaysShowControls&&f.hideControls(),f.options.enableAutosize&&f.media.addEventListener("loadedmetadata",function(a){f.options.videoHeight<=0&&null===f.domNode.getAttribute("height")&&!isNaN(a.target.videoHeight)&&(f.setPlayerSize(a.target.videoWidth,a.target.videoHeight),f.setControlsSize(),f.media.setVideoSize(a.target.videoWidth,a.target.videoHeight))},!1)),b.addEventListener("play",function(){var a;for(a in mejs.players){var b=mejs.players[a];b.id==f.id||!f.options.pauseOtherPlayers||b.paused||b.ended||b.pause(),b.hasFocus=!1}f.hasFocus=!0},!1),f.media.addEventListener("ended",function(){if(f.options.autoRewind)try{f.media.setCurrentTime(0),window.setTimeout(function(){a(f.container).find(".mejs-overlay-loading").parent().hide()},20)}catch(b){}f.media.pause(),f.setProgressRail&&f.setProgressRail(),f.setCurrentRail&&f.setCurrentRail(),f.options.loop?f.play():!f.options.alwaysShowControls&&f.controlsEnabled&&f.showControls()},!1),f.media.addEventListener("loadedmetadata",function(){f.updateDuration&&f.updateDuration(),f.updateCurrent&&f.updateCurrent(),f.isFullScreen||(f.setPlayerSize(f.width,f.height),f.setControlsSize())},!1),f.container.focusout(function(b){if(b.relatedTarget){var c=a(b.relatedTarget);f.keyboardAction&&0===c.parents(".mejs-container").length&&(f.keyboardAction=!1,f.hideControls(!0))}}),setTimeout(function(){f.setPlayerSize(f.width,f.height),f.setControlsSize()},50),f.globalBind("resize",function(){f.isFullScreen||mejs.MediaFeatures.hasTrueNativeFullScreen&&document.webkitIsFullScreen||f.setPlayerSize(f.width,f.height),f.setControlsSize()}),"youtube"==f.media.pluginType&&(g.isiOS||g.isAndroid)&&f.container.find(".mejs-overlay-play").hide()}i&&"native"==b.pluginType&&f.play(),f.options.success&&("string"==typeof f.options.success?window[f.options.success](f.media,f.domNode,f):f.options.success(f.media,f.domNode,f))}},handleError:function(a){var b=this;b.controls.hide(),b.options.error&&b.options.error(a)},setPlayerSize:function(b,c){var d=this;if(!d.options.setDimensions)return!1;if("undefined"!=typeof b&&(d.width=b),"undefined"!=typeof c&&(d.height=c),d.height.toString().indexOf("%")>0||"100%"===d.$node.css("max-width")||d.$node[0].currentStyle&&"100%"===d.$node[0].currentStyle.maxWidth){var e=function(){return d.isVideo?d.media.videoWidth&&d.media.videoWidth>0?d.media.videoWidth:null!==d.media.getAttribute("width")?d.media.getAttribute("width"):d.options.defaultVideoWidth:d.options.defaultAudioWidth}(),f=function(){return d.isVideo?d.media.videoHeight&&d.media.videoHeight>0?d.media.videoHeight:null!==d.media.getAttribute("height")?d.media.getAttribute("height"):d.options.defaultVideoHeight:d.options.defaultAudioHeight}(),g=d.container.parent().closest(":visible").width(),h=d.container.parent().closest(":visible").height(),i=d.isVideo||!d.options.autosizeProgress?parseInt(g*f/e,10):f;isNaN(i)&&(i=h),"body"===d.container.parent()[0].tagName.toLowerCase()&&(g=a(window).width(),i=a(window).height()),i&&g&&(d.container.width(g).height(i),d.$media.add(d.container.find(".mejs-shim")).width("100%").height("100%"),d.isVideo&&d.media.setVideoSize&&d.media.setVideoSize(g,i),d.layers.children(".mejs-layer").width("100%").height("100%"))}else d.container.width(d.width).height(d.height),d.layers.children(".mejs-layer").width(d.width).height(d.height);var j=d.layers.find(".mejs-overlay-play"),k=j.find(".mejs-overlay-button");j.height(d.container.height()-d.controls.height()),k.css("margin-top","-"+(k.height()/2-d.controls.height()/2).toString()+"px")},setControlsSize:function(){var b=this,c=0,d=0,e=b.controls.find(".mejs-time-rail"),f=b.controls.find(".mejs-time-total"),g=(b.controls.find(".mejs-time-current"),b.controls.find(".mejs-time-loaded"),e.siblings()),h=g.last(),i=null;if(b.container.is(":visible")&&e.length&&e.is(":visible")){b.options&&!b.options.autosizeProgress&&(d=parseInt(e.css("width"),10)),0!==d&&d||(g.each(function(){var b=a(this);"absolute"!=b.css("position")&&b.is(":visible")&&(c+=a(this).outerWidth(!0))}),d=b.controls.width()-c-(e.outerWidth(!0)-e.width()));do e.width(d),f.width(d-(f.outerWidth(!0)-f.width())),"absolute"!=h.css("position")&&(i=h.position(),d--);while(null!==i&&i.top>0&&d>0);b.setProgressRail&&b.setProgressRail(),b.setCurrentRail&&b.setCurrentRail()}},buildposter:function(b,c,d,e){var f=this,g=a('
').appendTo(d),h=b.$media.attr("poster");""!==b.options.poster&&(h=b.options.poster),h?f.setPoster(h):g.hide(),e.addEventListener("play",function(){g.hide()},!1),b.options.showPosterWhenEnded&&b.options.autoRewind&&e.addEventListener("ended",function(){g.show()},!1)},setPoster:function(b){var c=this,d=c.container.find(".mejs-poster"),e=d.find("img");0===e.length&&(e=a('').appendTo(d)),e.attr("src",b),d.css({"background-image":"url("+b+")"})},buildoverlays:function(b,c,d,e){var f=this;if(b.isVideo){var g=a('
').hide().appendTo(d),h=a('
').hide().appendTo(d),i=a('
').appendTo(d).bind("click",function(){f.options.clickToPlayPause&&e.paused&&e.play()});e.addEventListener("play",function(){i.hide(),g.hide(),c.find(".mejs-time-buffering").hide(),h.hide()},!1),e.addEventListener("playing",function(){i.hide(),g.hide(),c.find(".mejs-time-buffering").hide(),h.hide()},!1),e.addEventListener("seeking",function(){g.show(),c.find(".mejs-time-buffering").show()},!1),e.addEventListener("seeked",function(){g.hide(),c.find(".mejs-time-buffering").hide()},!1),e.addEventListener("pause",function(){mejs.MediaFeatures.isiPhone||i.show()},!1),e.addEventListener("waiting",function(){g.show(),c.find(".mejs-time-buffering").show()},!1),e.addEventListener("loadeddata",function(){g.show(),c.find(".mejs-time-buffering").show(),mejs.MediaFeatures.isAndroid&&(e.canplayTimeout=window.setTimeout(function(){if(document.createEvent){var a=document.createEvent("HTMLEvents");return a.initEvent("canplay",!0,!0),e.dispatchEvent(a)}},300))},!1),e.addEventListener("canplay",function(){g.hide(),c.find(".mejs-time-buffering").hide(),clearTimeout(e.canplayTimeout)},!1),e.addEventListener("error",function(){g.hide(),c.find(".mejs-time-buffering").hide(),h.show(),h.find("mejs-overlay-error").html("Error loading this resource")},!1),e.addEventListener("keydown",function(a){f.onkeydown(b,e,a)},!1)}},buildkeyboard:function(b,c,d,e){var f=this;f.container.keydown(function(){f.keyboardAction=!0}),f.globalBind("keydown",function(a){return f.onkeydown(b,e,a)}),f.globalBind("click",function(c){b.hasFocus=0!==a(c.target).closest(".mejs-container").length})},onkeydown:function(a,b,c){if(a.hasFocus&&a.options.enableKeyboard)for(var d=0,e=a.options.keyActions.length;e>d;d++)for(var f=a.options.keyActions[d],g=0,h=f.keys.length;h>g;g++)if(c.keyCode==f.keys[g])return"function"==typeof c.preventDefault&&c.preventDefault(),f.action(a,b,c.keyCode),!1;return!0},findTracks:function(){var b=this,c=b.$media.find("track");b.tracks=[],c.each(function(c,d){d=a(d),b.tracks.push({srclang:d.attr("srclang")?d.attr("srclang").toLowerCase():"",src:d.attr("src"),kind:d.attr("kind"),label:d.attr("label")||"",entries:[],isLoaded:!1})})},changeSkin:function(a){this.container[0].className="mejs-container "+a,this.setPlayerSize(this.width,this.height),this.setControlsSize()},play:function(){this.load(),this.media.play()},pause:function(){try{this.media.pause()}catch(a){}},load:function(){this.isLoaded||this.media.load(),this.isLoaded=!0},setMuted:function(a){this.media.setMuted(a)},setCurrentTime:function(a){this.media.setCurrentTime(a)},getCurrentTime:function(){return this.media.currentTime},setVolume:function(a){this.media.setVolume(a)},getVolume:function(){return this.media.volume},setSrc:function(a){this.media.setSrc(a)},remove:function(){var a,b,c=this;for(a in c.options.features)if(b=c.options.features[a],c["clean"+b])try{c["clean"+b](c)}catch(d){}c.isDynamic?c.$node.insertBefore(c.container):(c.$media.prop("controls",!0),c.$node.clone().insertBefore(c.container).show(),c.$node.remove()),"native"!==c.media.pluginType&&c.media.remove(),delete mejs.players[c.id],"object"==typeof c.container&&c.container.remove(),c.globalUnbind(),delete c.node.player},rebuildtracks:function(){var a=this;a.findTracks(),a.buildtracks(a,a.controls,a.layers,a.media)}},function(){function b(b,d){var e={d:[],w:[]};return a.each((b||"").split(" "),function(a,b){var f=b+"."+d;0===f.indexOf(".")?(e.d.push(f),e.w.push(f)):e[c.test(b)?"w":"d"].push(f)}),e.d=e.d.join(" "),e.w=e.w.join(" "),e}var c=/^((after|before)print|(before)?unload|hashchange|message|o(ff|n)line|page(hide|show)|popstate|resize|storage)\b/;mejs.MediaElementPlayer.prototype.globalBind=function(c,d,e){var f=this;c=b(c,f.id),c.d&&a(document).bind(c.d,d,e),c.w&&a(window).bind(c.w,d,e)},mejs.MediaElementPlayer.prototype.globalUnbind=function(c,d){var e=this;c=b(c,e.id),c.d&&a(document).unbind(c.d,d),c.w&&a(window).unbind(c.w,d)}}(),"undefined"!=typeof a&&(a.fn.mediaelementplayer=function(b){return this.each(b===!1?function(){var b=a(this).data("mediaelementplayer");b&&b.remove(),a(this).removeData("mediaelementplayer")}:function(){a(this).data("mediaelementplayer",new mejs.MediaElementPlayer(this,b))}),this},a(document).ready(function(){a(".mejs-player").mediaelementplayer()})),window.MediaElementPlayer=mejs.MediaElementPlayer}(mejs.$),function(a){a.extend(mejs.MepDefaults,{playText:mejs.i18n.t("Play"),pauseText:mejs.i18n.t("Pause")}),a.extend(MediaElementPlayer.prototype,{buildplaypause:function(b,c,d,e){function f(a){"play"===a?(i.removeClass("mejs-play").addClass("mejs-pause"),j.attr({title:h.pauseText,"aria-label":h.pauseText})):(i.removeClass("mejs-pause").addClass("mejs-play"),j.attr({title:h.playText,"aria-label":h.playText}))}var g=this,h=g.options,i=a('
').appendTo(c).click(function(a){return a.preventDefault(),e.paused?e.play():e.pause(),!1}),j=i.find("button");f("pse"),e.addEventListener("play",function(){f("play")},!1),e.addEventListener("playing",function(){f("play")},!1),e.addEventListener("pause",function(){f("pse")},!1),e.addEventListener("paused",function(){f("pse")},!1)}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{stopText:"Stop"}),a.extend(MediaElementPlayer.prototype,{buildstop:function(b,c,d,e){{var f=this;a('
').appendTo(c).click(function(){e.paused||e.pause(),e.currentTime>0&&(e.setCurrentTime(0),e.pause(),c.find(".mejs-time-current").width("0px"),c.find(".mejs-time-handle").css("left","0px"),c.find(".mejs-time-float-current").html(mejs.Utility.secondsToTimeCode(0)),c.find(".mejs-currenttime").html(mejs.Utility.secondsToTimeCode(0)),d.find(".mejs-poster").show())})}}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{progessHelpText:mejs.i18n.t("Use Left/Right Arrow keys to advance one second, Up/Down arrows to advance ten seconds.")}),a.extend(MediaElementPlayer.prototype,{buildprogress:function(b,c,d,e){a('
00:00
').appendTo(c),c.find(".mejs-time-buffering").hide();var f=this,g=c.find(".mejs-time-total"),h=c.find(".mejs-time-loaded"),i=c.find(".mejs-time-current"),j=c.find(".mejs-time-handle"),k=c.find(".mejs-time-float"),l=c.find(".mejs-time-float-current"),m=c.find(".mejs-time-slider"),n=function(a){var b,c=g.offset(),d=g.outerWidth(!0),f=0,h=0,i=0;b=a.originalEvent.changedTouches?a.originalEvent.changedTouches[0].pageX:a.pageX,e.duration&&(bd+c.left&&(b=d+c.left),i=b-c.left,f=i/d,h=.02>=f?0:f*e.duration,o&&h!==e.currentTime&&e.setCurrentTime(h),mejs.MediaFeatures.hasTouch||(k.css("left",i),l.html(mejs.Utility.secondsToTimeCode(h)),k.show()))},o=!1,p=!1,q=0,r=!1,s=b.options.autoRewind,t=function(){var a=e.currentTime,b=mejs.i18n.t("Time Slider"),c=mejs.Utility.secondsToTimeCode(a),d=e.duration;m.attr({"aria-label":b,"aria-valuemin":0,"aria-valuemax":d,"aria-valuenow":a,"aria-valuetext":c,role:"slider",tabindex:0})},u=function(){var a=new Date;a-q>=1e3&&e.play()};m.bind("focus",function(){b.options.autoRewind=!1}),m.bind("blur",function(){b.options.autoRewind=s}),m.bind("keydown",function(a){new Date-q>=1e3&&(r=e.paused);var b=a.keyCode,c=e.duration,d=e.currentTime;switch(b){case 37:d-=1;break;case 39:d+=1;break;case 38:d+=Math.floor(.1*c);break;case 40:d-=Math.floor(.1*c);break;case 36:d=0;break;case 35:d=c;break;case 10:return void(e.paused?e.play():e.pause());case 13:return void(e.paused?e.play():e.pause());default:return}return d=0>d?0:d>=c?c:Math.floor(d),q=new Date,r||e.pause(),d0&&c.buffered.end&&c.duration?d=c.buffered.end(0)/c.duration:c&&void 0!==c.bytesTotal&&c.bytesTotal>0&&void 0!==c.bufferedBytes?d=c.bufferedBytes/c.bytesTotal:a&&a.lengthComputable&&0!==a.total&&(d=a.loaded/a.total),null!==d&&(d=Math.min(1,Math.max(0,d)),b.loaded&&b.total&&b.loaded.width(b.total.width()*d))},setCurrentRail:function(){var a=this;if(void 0!==a.media.currentTime&&a.media.duration&&a.total&&a.handle){var b=Math.round(a.total.width()*a.media.currentTime/a.media.duration),c=b-Math.round(a.handle.outerWidth(!0)/2);a.current.width(b),a.handle.css("left",c)}}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{duration:-1,timeAndDurationSeparator:" | "}),a.extend(MediaElementPlayer.prototype,{buildcurrent:function(b,c,d,e){var f=this;a('
'+(b.options.alwaysShowHours?"00:":"")+(b.options.showTimecodeFrameCount?"00:00:00":"00:00")+"
").appendTo(c),f.currenttime=f.controls.find(".mejs-currenttime"),e.addEventListener("timeupdate",function(){b.updateCurrent()},!1)},buildduration:function(b,c,d,e){var f=this;c.children().last().find(".mejs-currenttime").length>0?a(f.options.timeAndDurationSeparator+''+(f.options.duration>0?mejs.Utility.secondsToTimeCode(f.options.duration,f.options.alwaysShowHours||f.media.duration>3600,f.options.showTimecodeFrameCount,f.options.framesPerSecond||25):(b.options.alwaysShowHours?"00:":"")+(b.options.showTimecodeFrameCount?"00:00:00":"00:00"))+"").appendTo(c.find(".mejs-time")):(c.find(".mejs-currenttime").parent().addClass("mejs-currenttime-container"),a('
'+(f.options.duration>0?mejs.Utility.secondsToTimeCode(f.options.duration,f.options.alwaysShowHours||f.media.duration>3600,f.options.showTimecodeFrameCount,f.options.framesPerSecond||25):(b.options.alwaysShowHours?"00:":"")+(b.options.showTimecodeFrameCount?"00:00:00":"00:00"))+"
").appendTo(c)),f.durationD=f.controls.find(".mejs-duration"),e.addEventListener("timeupdate",function(){b.updateDuration()},!1)},updateCurrent:function(){var a=this;a.currenttime&&a.currenttime.html(mejs.Utility.secondsToTimeCode(a.media.currentTime,a.options.alwaysShowHours||a.media.duration>3600,a.options.showTimecodeFrameCount,a.options.framesPerSecond||25))},updateDuration:function(){var a=this;a.container.toggleClass("mejs-long-video",a.media.duration>3600),a.durationD&&(a.options.duration>0||a.media.duration)&&a.durationD.html(mejs.Utility.secondsToTimeCode(a.options.duration>0?a.options.duration:a.media.duration,a.options.alwaysShowHours,a.options.showTimecodeFrameCount,a.options.framesPerSecond||25))}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{muteText:mejs.i18n.t("Mute Toggle"),allyVolumeControlText:mejs.i18n.t("Use Up/Down Arrow keys to increase or decrease volume."),hideVolumeOnTouchDevices:!0,audioVolume:"horizontal",videoVolume:"vertical"}),a.extend(MediaElementPlayer.prototype,{buildvolume:function(b,c,d,e){if(!mejs.MediaFeatures.isAndroid&&!mejs.MediaFeatures.isiOS||!this.options.hideVolumeOnTouchDevices){var f=this,g=f.isVideo?f.options.videoVolume:f.options.audioVolume,h="horizontal"==g?a('
'+f.options.allyVolumeControlText+'
').appendTo(c):a('').appendTo(c),i=f.container.find(".mejs-volume-slider, .mejs-horizontal-volume-slider"),j=f.container.find(".mejs-volume-total, .mejs-horizontal-volume-total"),k=f.container.find(".mejs-volume-current, .mejs-horizontal-volume-current"),l=f.container.find(".mejs-volume-handle, .mejs-horizontal-volume-handle"),m=function(a,b){if(!i.is(":visible")&&"undefined"==typeof b)return i.show(),m(a,!0),void i.hide();a=Math.max(0,a),a=Math.min(a,1),0===a?h.removeClass("mejs-mute").addClass("mejs-unmute"):h.removeClass("mejs-unmute").addClass("mejs-mute");var c=j.position();if("vertical"==g){var d=j.height(),e=d-d*a;l.css("top",Math.round(c.top+e-l.height()/2)),k.height(d-e),k.css("top",c.top+e)}else{var f=j.width(),n=f*a;l.css("left",Math.round(c.left+n-l.width()/2)),k.width(Math.round(n))}},n=function(a){var b=null,c=j.offset();if("vertical"===g){var d=j.height(),f=(parseInt(j.css("top").replace(/px/,""),10),a.pageY-c.top);if(b=(d-f)/d,0===c.top||0===c.left)return}else{var h=j.width(),i=a.pageX-c.left;b=i/h}b=Math.max(0,b),b=Math.min(b,1),m(b),e.setMuted(0===b?!0:!1),e.setVolume(b)},o=!1,p=!1;h.hover(function(){i.show(),p=!0},function(){p=!1,o||"vertical"!=g||i.hide()});var q=function(){var a=Math.floor(100*e.volume);i.attr({"aria-label":mejs.i18n.t("volumeSlider"),"aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":a,"aria-valuetext":a+"%",role:"slider",tabindex:0})};i.bind("mouseover",function(){p=!0}).bind("mousedown",function(a){return n(a),f.globalBind("mousemove.vol",function(a){n(a)}),f.globalBind("mouseup.vol",function(){o=!1,f.globalUnbind(".vol"),p||"vertical"!=g||i.hide()}),o=!0,!1}).bind("keydown",function(a){var b=a.keyCode,c=e.volume;switch(b){case 38:c+=.1;break;case 40:c-=.1;break;default:return!0}return o=!1,m(c),e.setVolume(c),!1}).bind("blur",function(){i.hide()}),h.find("button").click(function(){e.setMuted(!e.muted)}),h.find("button").bind("focus",function(){i.show()}),e.addEventListener("volumechange",function(a){o||(e.muted?(m(0),h.removeClass("mejs-mute").addClass("mejs-unmute")):(m(e.volume),h.removeClass("mejs-unmute").addClass("mejs-mute"))),q(a)},!1),f.container.is(":visible")&&(m(b.options.startVolume),0===b.options.startVolume&&e.setMuted(!0),"native"===e.pluginType&&e.setVolume(b.options.startVolume))}}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{usePluginFullScreen:!0,newWindowCallback:function(){return""},fullscreenText:mejs.i18n.t("Fullscreen")}),a.extend(MediaElementPlayer.prototype,{isFullScreen:!1,isNativeFullScreen:!1,isInIframe:!1,buildfullscreen:function(b,c,d,e){if(b.isVideo){if(b.isInIframe=window.location!=window.parent.location,mejs.MediaFeatures.hasTrueNativeFullScreen){var f=function(){b.isFullScreen&&(mejs.MediaFeatures.isFullScreen()?(b.isNativeFullScreen=!0,b.setControlsSize()):(b.isNativeFullScreen=!1,b.exitFullScreen()))};b.globalBind(mejs.MediaFeatures.fullScreenEventName,f)}var g=this,h=(b.container,a('
').appendTo(c));if("native"===g.media.pluginType||!g.options.usePluginFullScreen&&!mejs.MediaFeatures.isFirefox)h.click(function(){var a=mejs.MediaFeatures.hasTrueNativeFullScreen&&mejs.MediaFeatures.isFullScreen()||b.isFullScreen;a?b.exitFullScreen():b.enterFullScreen()});else{var i=null,j=function(){var a,b=document.createElement("x"),c=document.documentElement,d=window.getComputedStyle;return"pointerEvents"in b.style?(b.style.pointerEvents="auto",b.style.pointerEvents="x",c.appendChild(b),a=d&&"auto"===d(b,"").pointerEvents,c.removeChild(b),!!a):!1}();if(j&&!mejs.MediaFeatures.isOpera){var k,l,m=!1,n=function(){if(m){for(var a in o)o[a].hide();h.css("pointer-events",""),g.controls.css("pointer-events",""),g.media.removeEventListener("click",g.clickToPlayPauseCallback),m=!1}},o={},p=["top","left","right","bottom"],q=function(){var a=h.offset().left-g.container.offset().left,b=h.offset().top-g.container.offset().top,c=h.outerWidth(!0),d=h.outerHeight(!0),e=g.container.width(),f=g.container.height();for(k in o)o[k].css({position:"absolute",top:0,left:0});o.top.width(e).height(b),o.left.width(a).height(d).css({top:b}),o.right.width(e-a-c).height(d).css({top:b,left:a+c}),o.bottom.width(e).height(f-d-b).css({top:b+d})};for(g.globalBind("resize",function(){q()}),k=0,l=p.length;l>k;k++)o[p[k]]=a('
').appendTo(g.container).mouseover(n).hide();h.on("mouseover",function(){if(!g.isFullScreen){var a=h.offset(),c=b.container.offset();e.positionFullscreenButton(a.left-c.left,a.top-c.top,!1),h.css("pointer-events","none"),g.controls.css("pointer-events","none"),g.media.addEventListener("click",g.clickToPlayPauseCallback);for(k in o)o[k].show();q(),m=!0}}),e.addEventListener("fullscreenchange",function(){g.isFullScreen=!g.isFullScreen,g.isFullScreen?g.media.removeEventListener("click",g.clickToPlayPauseCallback):g.media.addEventListener("click",g.clickToPlayPauseCallback),n()}),g.globalBind("mousemove",function(a){if(m){var b=h.offset();(a.pageYb.top+h.outerHeight(!0)||a.pageXb.left+h.outerWidth(!0))&&(h.css("pointer-events",""),g.controls.css("pointer-events",""),m=!1) +-}})}else h.on("mouseover",function(){null!==i&&(clearTimeout(i),delete i);var a=h.offset(),c=b.container.offset();e.positionFullscreenButton(a.left-c.left,a.top-c.top,!0)}).on("mouseout",function(){null!==i&&(clearTimeout(i),delete i),i=setTimeout(function(){e.hideFullscreenButton()},1500)})}b.fullscreenBtn=h,g.globalBind("keydown",function(a){(mejs.MediaFeatures.hasTrueNativeFullScreen&&mejs.MediaFeatures.isFullScreen()||g.isFullScreen)&&27==a.keyCode&&b.exitFullScreen()})}},cleanfullscreen:function(a){a.exitFullScreen()},containerSizeTimeout:null,enterFullScreen:function(){var b=this;if("native"===b.media.pluginType||!mejs.MediaFeatures.isFirefox&&!b.options.usePluginFullScreen){if(a(document.documentElement).addClass("mejs-fullscreen"),normalHeight=b.container.height(),normalWidth=b.container.width(),"native"===b.media.pluginType)if(mejs.MediaFeatures.hasTrueNativeFullScreen)mejs.MediaFeatures.requestFullScreen(b.container[0]),b.isInIframe&&setTimeout(function d(){if(b.isNativeFullScreen){var c=window.devicePixelRatio||1,e=.002,f=c*a(window).width(),g=screen.width,h=Math.abs(g-f),i=g*e;h>i?b.exitFullScreen():setTimeout(d,500)}},500);else if(mejs.MediaFeatures.hasSemiNativeFullScreen)return void b.media.webkitEnterFullscreen();if(b.isInIframe){var c=b.options.newWindowCallback(this);if(""!==c){if(!mejs.MediaFeatures.hasTrueNativeFullScreen)return b.pause(),void window.open(c,b.id,"top=0,left=0,width="+screen.availWidth+",height="+screen.availHeight+",resizable=yes,scrollbars=no,status=no,toolbar=no");setTimeout(function(){b.isNativeFullScreen||(b.pause(),window.open(c,b.id,"top=0,left=0,width="+screen.availWidth+",height="+screen.availHeight+",resizable=yes,scrollbars=no,status=no,toolbar=no"))},250)}}b.container.addClass("mejs-container-fullscreen").width("100%").height("100%"),b.containerSizeTimeout=setTimeout(function(){b.container.css({width:"100%",height:"100%"}),b.setControlsSize()},500),"native"===b.media.pluginType?b.$media.width("100%").height("100%"):(b.container.find(".mejs-shim").width("100%").height("100%"),b.media.setVideoSize(a(window).width(),a(window).height())),b.layers.children("div").width("100%").height("100%"),b.fullscreenBtn&&b.fullscreenBtn.removeClass("mejs-fullscreen").addClass("mejs-unfullscreen"),b.setControlsSize(),b.isFullScreen=!0,b.container.find(".mejs-captions-text").css("font-size",screen.width/b.width*1*100+"%"),b.container.find(".mejs-captions-position").css("bottom","45px")}},exitFullScreen:function(){var b=this;return clearTimeout(b.containerSizeTimeout),"native"!==b.media.pluginType&&mejs.MediaFeatures.isFirefox?void b.media.setFullscreen(!1):(mejs.MediaFeatures.hasTrueNativeFullScreen&&(mejs.MediaFeatures.isFullScreen()||b.isFullScreen)&&mejs.MediaFeatures.cancelFullScreen(),a(document.documentElement).removeClass("mejs-fullscreen"),b.container.removeClass("mejs-container-fullscreen").width(normalWidth).height(normalHeight),"native"===b.media.pluginType?b.$media.width(normalWidth).height(normalHeight):(b.container.find(".mejs-shim").width(normalWidth).height(normalHeight),b.media.setVideoSize(normalWidth,normalHeight)),b.layers.children("div").width(normalWidth).height(normalHeight),b.fullscreenBtn.removeClass("mejs-unfullscreen").addClass("mejs-fullscreen"),b.setControlsSize(),b.isFullScreen=!1,b.container.find(".mejs-captions-text").css("font-size",""),void b.container.find(".mejs-captions-position").css("bottom",""))}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{speeds:["2.00","1.50","1.25","1.00","0.75"],defaultSpeed:"1.00",speedChar:"x"}),a.extend(MediaElementPlayer.prototype,{buildspeed:function(b,c,d,e){var f=this;if("native"==f.media.pluginType){var g=null,h=null,i='
    ';-1===a.inArray(f.options.defaultSpeed,f.options.speeds)&&f.options.speeds.push(f.options.defaultSpeed),f.options.speeds.sort(function(a,b){return parseFloat(b)-parseFloat(a)});for(var j=0,k=f.options.speeds.length;k>j;j++)i+='
  • ";i+="
",g=a(i).appendTo(c),h=g.find(".mejs-speed-selector"),playbackspeed=f.options.defaultSpeed,h.on("click",'input[type="radio"]',function(){var b=a(this).attr("value");playbackspeed=b,e.playbackRate=parseFloat(b),g.find("button").html(b+f.options.speedChar),g.find(".mejs-speed-selected").removeClass("mejs-speed-selected"),g.find('input[type="radio"]:checked').next().addClass("mejs-speed-selected")}),h.height(g.find(".mejs-speed-selector ul").outerHeight(!0)+g.find(".mejs-speed-translations").outerHeight(!0)).css("top",-1*h.height()+"px")}}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{startLanguage:"",tracksText:mejs.i18n.t("Captions/Subtitles"),hideCaptionsButtonWhenEmpty:!0,toggleCaptionsButtonWhenOnlyOne:!1,slidesSelector:""}),a.extend(MediaElementPlayer.prototype,{hasChapters:!1,cleartracks:function(a){a&&(a.captions&&a.captions.remove(),a.chapters&&a.chapters.remove(),a.captionsText&&a.captionsText.remove(),a.captionsButton&&a.captionsButton.remove())},buildtracks:function(b,c,d,e){if(0!==b.tracks.length){var f,g=this;if(g.domNode.textTracks)for(f=g.domNode.textTracks.length-1;f>=0;f--)g.domNode.textTracks[f].mode="hidden";g.cleartracks(b,c,d,e),b.chapters=a('
').prependTo(d).hide(),b.captions=a('
').prependTo(d).hide(),b.captionsText=b.captions.find(".mejs-captions-text"),b.captionsButton=a('
").appendTo(c);var h=0;for(f=0;f0&&c.displayChapters(d)},!1),"slides"==d.kind&&c.setupSlides(d)},error:function(){c.loadNextTrack()}})},enableTrackButton:function(b,c){var d=this;""===c&&(c=mejs.language.codes[b]||b),d.captionsButton.find("input[value="+b+"]").prop("disabled",!1).siblings("label").html(c),d.options.startLanguage==b&&a("#"+d.id+"_captions_"+b).prop("checked",!0).trigger("click"),d.adjustLanguageBox()},addTrackButton:function(b,c){var d=this;""===c&&(c=mejs.language.codes[b]||b),d.captionsButton.find("ul").append(a('
  • ")),d.adjustLanguageBox(),d.container.find(".mejs-captions-translations option[value="+b+"]").remove()},adjustLanguageBox:function(){var a=this;a.captionsButton.find(".mejs-captions-selector").height(a.captionsButton.find(".mejs-captions-selector ul").outerHeight(!0)+a.captionsButton.find(".mejs-captions-translations").outerHeight(!0))},checkForTracks:function(){var a=this,b=!1;if(a.options.hideCaptionsButtonWhenEmpty){for(i=0;i=c.entries.times[a].start&&b.media.currentTime<=c.entries.times[a].stop)return b.captionsText.html(c.entries.text[a]).attr("class","mejs-captions-text "+(c.entries.times[a].identifier||"")),void b.captions.show().height(0);b.captions.hide()}else b.captions.hide()}},setupSlides:function(a){var b=this;b.slides=a,b.slides.entries.imgs=[b.slides.entries.text.length],b.showSlide(0)},showSlide:function(b){if("undefined"!=typeof this.tracks&&"undefined"!=typeof this.slidesContainer){var c=this,d=c.slides.entries.text[b],e=c.slides.entries.imgs[b];"undefined"==typeof e||"undefined"==typeof e.fadeIn?c.slides.entries.imgs[b]=e=a('').on("load",function(){e.appendTo(c.slidesContainer).hide().fadeIn().siblings(":visible").fadeOut()}):e.is(":visible")||e.is(":animated")||e.fadeIn().siblings(":visible").fadeOut()}},displaySlides:function(){if("undefined"!=typeof this.slides){var a,b=this,c=b.slides;for(a=0;a=c.entries.times[a].start&&b.media.currentTime<=c.entries.times[a].stop)return void b.showSlide(a)}},displayChapters:function(){var a,b=this;for(a=0;a100||c==b.entries.times.length-1&&100>f+g)&&(f=100-g),e.chapters.append(a('
    '+b.entries.text[c]+''+mejs.Utility.secondsToTimeCode(b.entries.times[c].start)+"–"+mejs.Utility.secondsToTimeCode(b.entries.times[c].stop)+"
    ")),g+=f;e.chapters.find("div.mejs-chapter").click(function(){e.media.setCurrentTime(parseFloat(a(this).attr("rel"))),e.media.paused&&e.media.play()}),e.chapters.show()}}),mejs.language={codes:{af:"Afrikaans",sq:"Albanian",ar:"Arabic",be:"Belarusian",bg:"Bulgarian",ca:"Catalan",zh:"Chinese","zh-cn":"Chinese Simplified","zh-tw":"Chinese Traditional",hr:"Croatian",cs:"Czech",da:"Danish",nl:"Dutch",en:"English",et:"Estonian",fl:"Filipino",fi:"Finnish",fr:"French",gl:"Galician",de:"German",el:"Greek",ht:"Haitian Creole",iw:"Hebrew",hi:"Hindi",hu:"Hungarian",is:"Icelandic",id:"Indonesian",ga:"Irish",it:"Italian",ja:"Japanese",ko:"Korean",lv:"Latvian",lt:"Lithuanian",mk:"Macedonian",ms:"Malay",mt:"Maltese",no:"Norwegian",fa:"Persian",pl:"Polish",pt:"Portuguese",ro:"Romanian",ru:"Russian",sr:"Serbian",sk:"Slovak",sl:"Slovenian",es:"Spanish",sw:"Swahili",sv:"Swedish",tl:"Tagalog",th:"Thai",tr:"Turkish",uk:"Ukrainian",vi:"Vietnamese",cy:"Welsh",yi:"Yiddish"}},mejs.TrackFormatParser={webvtt:{pattern_timecode:/^((?:[0-9]{1,2}:)?[0-9]{2}:[0-9]{2}([,.][0-9]{1,3})?) --\> ((?:[0-9]{1,2}:)?[0-9]{2}:[0-9]{2}([,.][0-9]{3})?)(.*)$/,parse:function(b){for(var c,d,e,f=0,g=mejs.TrackFormatParser.split2(b,/\r?\n/),h={text:[],times:[]};f=0&&""!==g[f-1]&&(e=g[f-1]),f++,d=g[f],f++;""!==g[f]&&f$1"),h.text.push(d),h.times.push({identifier:e,start:0===mejs.Utility.convertSMPTEtoSeconds(c[1])?.2:mejs.Utility.convertSMPTEtoSeconds(c[1]),stop:mejs.Utility.convertSMPTEtoSeconds(c[3]),settings:c[5]})}e=""}return h}},dfxp:{parse:function(b){b=a(b).filter("tt");var c,d,e=0,f=b.children("div").eq(0),g=f.find("p"),h=b.find("#"+f.attr("style")),i={text:[],times:[]};if(h.length){var j=h.removeAttr("id").get(0).attributes;if(j.length)for(c={},e=0;e$1"),i.text.push(d),0===i.times.start&&(i.times.start=2)}return i}},split2:function(a,b){return a.split(b)}},3!="x\n\ny".split(/\n/gi).length&&(mejs.TrackFormatParser.split2=function(a,b){var c,d=[],e="";for(c=0;c
    ').appendTo(a("body")).hide(),b.container.bind("contextmenu",function(a){return b.isContextMenuEnabled?(a.preventDefault(),b.renderContextMenu(a.clientX-1,a.clientY-1),!1):void 0}),b.container.bind("click",function(){b.contextMenu.hide()}),b.contextMenu.bind("mouseleave",function(){b.startContextMenuTimer()})},cleancontextmenu:function(a){a.contextMenu.remove()},isContextMenuEnabled:!0,enableContextMenu:function(){this.isContextMenuEnabled=!0},disableContextMenu:function(){this.isContextMenuEnabled=!1},contextMenuTimeout:null,startContextMenuTimer:function(){var a=this;a.killContextMenuTimer(),a.contextMenuTimer=setTimeout(function(){a.hideContextMenu(),a.killContextMenuTimer()},750)},killContextMenuTimer:function(){var a=this.contextMenuTimer;null!=a&&(clearTimeout(a),delete a,a=null)},hideContextMenu:function(){this.contextMenu.hide()},renderContextMenu:function(b,c){for(var d=this,e="",f=d.options.contextMenuItems,g=0,h=f.length;h>g;g++)if(f[g].isSeparator)e+='
    ';else{var i=f[g].render(d);null!=i&&(e+='
    '+i+"
    ")}d.contextMenu.empty().append(a(e)).css({top:c,left:b}).show(),d.contextMenu.find(".mejs-contextmenu-item").each(function(){var b=a(this),c=parseInt(b.data("itemindex"),10),e=d.options.contextMenuItems[c];"undefined"!=typeof e.show&&e.show(b,d),b.click(function(){"undefined"!=typeof e.click&&e.click(d),d.contextMenu.hide()})}),setTimeout(function(){d.killControlsTimer("rev3")},100)}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{postrollCloseText:mejs.i18n.t("Close")}),a.extend(MediaElementPlayer.prototype,{buildpostroll:function(b,c,d){var e=this,f=e.container.find('link[rel="postroll"]').attr("href");"undefined"!=typeof f&&(b.postroll=a('').prependTo(d).hide(),e.media.addEventListener("ended",function(){a.ajax({dataType:"html",url:f,success:function(a){d.find(".mejs-postroll-layer-content").html(a)}}),b.postroll.show()},!1))}})}(mejs.$); +\ Pas de fin de ligne à la fin du fichier ++}})}else h.on("mouseover",function(){null!==i&&(clearTimeout(i),delete i);var a=h.offset(),c=b.container.offset();e.positionFullscreenButton(a.left-c.left,a.top-c.top,!0)}).on("mouseout",function(){null!==i&&(clearTimeout(i),delete i),i=setTimeout(function(){e.hideFullscreenButton()},1500)})}b.fullscreenBtn=h,g.globalBind("keydown",function(a){(mejs.MediaFeatures.hasTrueNativeFullScreen&&mejs.MediaFeatures.isFullScreen()||g.isFullScreen)&&27==a.keyCode&&b.exitFullScreen()})}},cleanfullscreen:function(a){a.exitFullScreen()},containerSizeTimeout:null,enterFullScreen:function(){var b=this;if("native"===b.media.pluginType||!mejs.MediaFeatures.isFirefox&&!b.options.usePluginFullScreen){if(a(document.documentElement).addClass("mejs-fullscreen"),normalHeight=b.container.height(),normalWidth=b.container.width(),"native"===b.media.pluginType)if(mejs.MediaFeatures.hasTrueNativeFullScreen)mejs.MediaFeatures.requestFullScreen(b.container[0]),b.isInIframe&&setTimeout(function d(){if(b.isNativeFullScreen){var c=window.devicePixelRatio||1,e=.002,f=c*a(window).width(),g=screen.width,h=Math.abs(g-f),i=g*e;h>i?b.exitFullScreen():setTimeout(d,500)}},500);else if(mejs.MediaFeatures.hasSemiNativeFullScreen)return void b.media.webkitEnterFullscreen();if(b.isInIframe){var c=b.options.newWindowCallback(this);if(""!==c){if(!mejs.MediaFeatures.hasTrueNativeFullScreen)return b.pause(),void window.open(c,b.id,"top=0,left=0,width="+screen.availWidth+",height="+screen.availHeight+",resizable=yes,scrollbars=no,status=no,toolbar=no");setTimeout(function(){b.isNativeFullScreen||(b.pause(),window.open(c,b.id,"top=0,left=0,width="+screen.availWidth+",height="+screen.availHeight+",resizable=yes,scrollbars=no,status=no,toolbar=no"))},250)}}b.container.addClass("mejs-container-fullscreen").width("100%").height("100%"),b.containerSizeTimeout=setTimeout(function(){b.container.css({width:"100%",height:"100%"}),b.setControlsSize()},500),"native"===b.media.pluginType?b.$media.width("100%").height("100%"):(b.container.find(".mejs-shim").width("100%").height("100%"),b.media.setVideoSize(a(window).width(),a(window).height())),b.layers.children("div").width("100%").height("100%"),b.fullscreenBtn&&b.fullscreenBtn.removeClass("mejs-fullscreen").addClass("mejs-unfullscreen"),b.setControlsSize(),b.isFullScreen=!0,b.container.find(".mejs-captions-text").css("font-size",screen.width/b.width*1*100+"%"),b.container.find(".mejs-captions-position").css("bottom","45px")}},exitFullScreen:function(){var b=this;return clearTimeout(b.containerSizeTimeout),"native"!==b.media.pluginType&&mejs.MediaFeatures.isFirefox?void b.media.setFullscreen(!1):(mejs.MediaFeatures.hasTrueNativeFullScreen&&(mejs.MediaFeatures.isFullScreen()||b.isFullScreen)&&mejs.MediaFeatures.cancelFullScreen(),a(document.documentElement).removeClass("mejs-fullscreen"),b.container.removeClass("mejs-container-fullscreen").width(normalWidth).height(normalHeight),"native"===b.media.pluginType?b.$media.width(normalWidth).height(normalHeight):(b.container.find(".mejs-shim").width(normalWidth).height(normalHeight),b.media.setVideoSize(normalWidth,normalHeight)),b.layers.children("div").width(normalWidth).height(normalHeight),b.fullscreenBtn.removeClass("mejs-unfullscreen").addClass("mejs-fullscreen"),b.setControlsSize(),b.isFullScreen=!1,b.container.find(".mejs-captions-text").css("font-size",""),void b.container.find(".mejs-captions-position").css("bottom",""))}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{speeds:["2.00","1.50","1.25","1.00","0.75"],defaultSpeed:"1.00",speedChar:"x"}),a.extend(MediaElementPlayer.prototype,{buildspeed:function(b,c,d,e){var f=this;if("native"==f.media.pluginType){var g=null,h=null,i='
      ';-1===a.inArray(f.options.defaultSpeed,f.options.speeds)&&f.options.speeds.push(f.options.defaultSpeed),f.options.speeds.sort(function(a,b){return parseFloat(b)-parseFloat(a)});for(var j=0,k=f.options.speeds.length;k>j;j++)i+='
    • ";i+="
    ",g=a(i).appendTo(c),h=g.find(".mejs-speed-selector"),playbackspeed=f.options.defaultSpeed,h.on("click",'input[type="radio"]',function(){var b=a(this).attr("value");playbackspeed=b,e.playbackRate=parseFloat(b),g.find("button").html(b+f.options.speedChar),g.find(".mejs-speed-selected").removeClass("mejs-speed-selected"),g.find('input[type="radio"]:checked').next().addClass("mejs-speed-selected")}),h.height(g.find(".mejs-speed-selector ul").outerHeight(!0)+g.find(".mejs-speed-translations").outerHeight(!0)).css("top",-1*h.height()+"px")}}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{startLanguage:"",tracksText:mejs.i18n.t("Captions/Subtitles"),hideCaptionsButtonWhenEmpty:!0,toggleCaptionsButtonWhenOnlyOne:!1,slidesSelector:""}),a.extend(MediaElementPlayer.prototype,{hasChapters:!1,cleartracks:function(a){a&&(a.captions&&a.captions.remove(),a.chapters&&a.chapters.remove(),a.captionsText&&a.captionsText.remove(),a.captionsButton&&a.captionsButton.remove())},buildtracks:function(b,c,d,e){if(0!==b.tracks.length){var f,g=this;if(g.domNode.textTracks)for(f=g.domNode.textTracks.length-1;f>=0;f--)g.domNode.textTracks[f].mode="hidden";g.cleartracks(b,c,d,e),b.chapters=a('
    ').prependTo(d).hide(),b.captions=a('
    ').prependTo(d).hide(),b.captionsText=b.captions.find(".mejs-captions-text"),b.captionsButton=a('
    ").appendTo(c);var h=0;for(f=0;f0&&c.displayChapters(d)},!1),"slides"==d.kind&&c.setupSlides(d)},error:function(){c.loadNextTrack()}})},enableTrackButton:function(b,c){var d=this;""===c&&(c=mejs.language.codes[b]||b),d.captionsButton.find("input[value="+b+"]").prop("disabled",!1).siblings("label").html(c),d.options.startLanguage==b&&a("#"+d.id+"_captions_"+b).prop("checked",!0).trigger("click"),d.adjustLanguageBox()},addTrackButton:function(b,c){var d=this;""===c&&(c=mejs.language.codes[b]||b),d.captionsButton.find("ul").append(a('
  • ")),d.adjustLanguageBox(),d.container.find(".mejs-captions-translations option[value="+b+"]").remove()},adjustLanguageBox:function(){var a=this;a.captionsButton.find(".mejs-captions-selector").height(a.captionsButton.find(".mejs-captions-selector ul").outerHeight(!0)+a.captionsButton.find(".mejs-captions-translations").outerHeight(!0))},checkForTracks:function(){var a=this,b=!1;if(a.options.hideCaptionsButtonWhenEmpty){for(i=0;i=c.entries.times[a].start&&b.media.currentTime<=c.entries.times[a].stop)return b.captionsText.html(c.entries.text[a]).attr("class","mejs-captions-text "+(c.entries.times[a].identifier||"")),void b.captions.show().height(0);b.captions.hide()}else b.captions.hide()}},setupSlides:function(a){var b=this;b.slides=a,b.slides.entries.imgs=[b.slides.entries.text.length],b.showSlide(0)},showSlide:function(b){if("undefined"!=typeof this.tracks&&"undefined"!=typeof this.slidesContainer){var c=this,d=c.slides.entries.text[b],e=c.slides.entries.imgs[b];"undefined"==typeof e||"undefined"==typeof e.fadeIn?c.slides.entries.imgs[b]=e=a('').on("load",function(){e.appendTo(c.slidesContainer).hide().fadeIn().siblings(":visible").fadeOut()}):e.is(":visible")||e.is(":animated")||e.fadeIn().siblings(":visible").fadeOut()}},displaySlides:function(){if("undefined"!=typeof this.slides){var a,b=this,c=b.slides;for(a=0;a=c.entries.times[a].start&&b.media.currentTime<=c.entries.times[a].stop)return void b.showSlide(a)}},displayChapters:function(){var a,b=this;for(a=0;a100||c==b.entries.times.length-1&&100>f+g)&&(f=100-g),e.chapters.append(a('
    '+b.entries.text[c]+''+mejs.Utility.secondsToTimeCode(b.entries.times[c].start)+"–"+mejs.Utility.secondsToTimeCode(b.entries.times[c].stop)+"
    ")),g+=f;e.chapters.find("div.mejs-chapter").click(function(){e.media.setCurrentTime(parseFloat(a(this).attr("rel"))),e.media.paused&&e.media.play()}),e.chapters.show()}}),mejs.language={codes:{af:"Afrikaans",sq:"Albanian",ar:"Arabic",be:"Belarusian",bg:"Bulgarian",ca:"Catalan",zh:"Chinese","zh-cn":"Chinese Simplified","zh-tw":"Chinese Traditional",hr:"Croatian",cs:"Czech",da:"Danish",nl:"Dutch",en:"English",et:"Estonian",fl:"Filipino",fi:"Finnish",fr:"French",gl:"Galician",de:"German",el:"Greek",ht:"Haitian Creole",iw:"Hebrew",hi:"Hindi",hu:"Hungarian",is:"Icelandic",id:"Indonesian",ga:"Irish",it:"Italian",ja:"Japanese",ko:"Korean",lv:"Latvian",lt:"Lithuanian",mk:"Macedonian",ms:"Malay",mt:"Maltese",no:"Norwegian",fa:"Persian",pl:"Polish",pt:"Portuguese",ro:"Romanian",ru:"Russian",sr:"Serbian",sk:"Slovak",sl:"Slovenian",es:"Spanish",sw:"Swahili",sv:"Swedish",tl:"Tagalog",th:"Thai",tr:"Turkish",uk:"Ukrainian",vi:"Vietnamese",cy:"Welsh",yi:"Yiddish"}},mejs.TrackFormatParser={webvtt:{pattern_timecode:/^((?:[0-9]{1,2}:)?[0-9]{2}:[0-9]{2}([,.][0-9]{1,3})?) --\> ((?:[0-9]{1,2}:)?[0-9]{2}:[0-9]{2}([,.][0-9]{3})?)(.*)$/,parse:function(b){for(var c,d,e,f=0,g=mejs.TrackFormatParser.split2(b,/\r?\n/),h={text:[],times:[]};f=0&&""!==g[f-1]&&(e=g[f-1]),f++,d=g[f],f++;""!==g[f]&&f$1"),h.text.push(d),h.times.push({identifier:e,start:0===mejs.Utility.convertSMPTEtoSeconds(c[1])?.2:mejs.Utility.convertSMPTEtoSeconds(c[1]),stop:mejs.Utility.convertSMPTEtoSeconds(c[3]),settings:c[5]})}e=""}return h}},dfxp:{parse:function(b){b=a(b).filter("tt");var c,d,e=0,f=b.children("div").eq(0),g=f.find("p"),h=b.find("#"+f.attr("style")),i={text:[],times:[]};if(h.length){var j=h.removeAttr("id").get(0).attributes;if(j.length)for(c={},e=0;e$1"),i.text.push(d),0===i.times.start&&(i.times.start=2)}return i}},split2:function(a,b){return a.split(b)}},3!="x\n\ny".split(/\n/gi).length&&(mejs.TrackFormatParser.split2=function(a,b){var c,d=[],e="";for(c=0;c').appendTo(a("body")).hide(),b.container.bind("contextmenu",function(a){return b.isContextMenuEnabled?(a.preventDefault(),b.renderContextMenu(a.clientX-1,a.clientY-1),!1):void 0}),b.container.bind("click",function(){b.contextMenu.hide()}),b.contextMenu.bind("mouseleave",function(){b.startContextMenuTimer()})},cleancontextmenu:function(a){a.contextMenu.remove()},isContextMenuEnabled:!0,enableContextMenu:function(){this.isContextMenuEnabled=!0},disableContextMenu:function(){this.isContextMenuEnabled=!1},contextMenuTimeout:null,startContextMenuTimer:function(){var a=this;a.killContextMenuTimer(),a.contextMenuTimer=setTimeout(function(){a.hideContextMenu(),a.killContextMenuTimer()},750)},killContextMenuTimer:function(){var a=this.contextMenuTimer;null!=a&&(clearTimeout(a),delete a,a=null)},hideContextMenu:function(){this.contextMenu.hide()},renderContextMenu:function(b,c){for(var d=this,e="",f=d.options.contextMenuItems,g=0,h=f.length;h>g;g++)if(f[g].isSeparator)e+='
    ';else{var i=f[g].render(d);null!=i&&(e+='
    '+i+"
    ")}d.contextMenu.empty().append(a(e)).css({top:c,left:b}).show(),d.contextMenu.find(".mejs-contextmenu-item").each(function(){var b=a(this),c=parseInt(b.data("itemindex"),10),e=d.options.contextMenuItems[c];"undefined"!=typeof e.show&&e.show(b,d),b.click(function(){"undefined"!=typeof e.click&&e.click(d),d.contextMenu.hide()})}),setTimeout(function(){d.killControlsTimer("rev3")},100)}})}(mejs.$),function(a){a.extend(mejs.MepDefaults,{postrollCloseText:mejs.i18n.t("Close")}),a.extend(MediaElementPlayer.prototype,{buildpostroll:function(b,c,d){var e=this,f=e.container.find('link[rel="postroll"]').attr("href");"undefined"!=typeof f&&(b.postroll=a('').prependTo(d).hide(),e.media.addEventListener("ended",function(){a.ajax({dataType:"html",url:f,success:function(a){d.find(".mejs-postroll-layer-content").html(a)}}),b.postroll.show()},!1))}})}(mejs.$); diff --git a/wordpress-3.9-no_swfupload.patch b/wordpress-4.2-no_swfupload.patch similarity index 94% rename from wordpress-3.9-no_swfupload.patch rename to wordpress-4.2-no_swfupload.patch index 3d1395d..0b826e8 100644 --- a/wordpress-3.9-no_swfupload.patch +++ b/wordpress-4.2-no_swfupload.patch @@ -1,7 +1,7 @@ diff -up wordpress/wp-includes/script-loader.php.orig wordpress/wp-includes/script-loader.php --- wordpress/wp-includes/script-loader.php.orig 2014-05-07 15:55:26.485228222 +0200 +++ wordpress/wp-includes/script-loader.php 2014-05-07 15:55:18.019198073 +0200 -@@ -273,15 +273,6 @@ function wp_default_scripts( &$scripts ) +@@ -280,15 +280,6 @@ $scripts->add( 'wp-plupload', "/wp-includes/js/plupload/wp-plupload$suffix.js", array( 'plupload', 'jquery', 'json2', 'media-models' ), false, 1 ); did_action( 'init' ) && $scripts->localize( 'wp-plupload', 'pluploadL10n', $uploader_l10n ); @@ -16,4 +16,4 @@ diff -up wordpress/wp-includes/script-loader.php.orig wordpress/wp-includes/scri - $scripts->add( 'comment-reply', "/wp-includes/js/comment-reply$suffix.js", array(), false, 1 ); - $scripts->add( 'json2', "/wp-includes/js/json2$suffix.js", array(), '2011-02-23'); + $scripts->add( 'json2', "/wp-includes/js/json2$suffix.js", array(), '2011-02-23' ); diff --git a/wordpress-4.1-noupdate.patch b/wordpress-4.2-noupdate.patch similarity index 58% rename from wordpress-4.1-noupdate.patch rename to wordpress-4.2-noupdate.patch index 5105c23..2716f3f 100644 --- a/wordpress-4.1-noupdate.patch +++ b/wordpress-4.2-noupdate.patch @@ -1,7 +1,7 @@ -diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.rpm wordpress/wp-admin/includes/class-wp-upgrader.php ---- wordpress/wp-admin/includes/class-wp-upgrader.php.rpm 2014-12-16 20:54:23.000000000 +0100 -+++ wordpress/wp-admin/includes/class-wp-upgrader.php 2014-12-22 06:46:28.487097611 +0100 -@@ -2141,6 +2141,9 @@ class Core_Upgrader extends WP_Upgrader +diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.noupdate wordpress/wp-admin/includes/class-wp-upgrader.php +--- wordpress/wp-admin/includes/class-wp-upgrader.php.noupdate 2015-04-03 02:18:27.000000000 +0200 ++++ wordpress/wp-admin/includes/class-wp-upgrader.php 2015-04-24 10:33:31.166724612 +0200 +@@ -2142,6 +2142,9 @@ class Core_Upgrader extends WP_Upgrader } } @@ -11,7 +11,7 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.rpm wordpress/wp-admi // 1: If we're already on that version, not much point in updating? if ( $offered_ver == $wp_version ) return false; -@@ -2372,7 +2375,7 @@ class WP_Automatic_Updater { +@@ -2373,7 +2376,7 @@ class WP_Automatic_Updater { */ public function is_disabled() { // Background updates are disabled if you don't want file changes. @@ -20,9 +20,9 @@ diff -up wordpress/wp-admin/includes/class-wp-upgrader.php.rpm wordpress/wp-admi return true; if ( defined( 'WP_INSTALLING' ) ) -diff -up wordpress/wp-admin/includes/update.php.rpm wordpress/wp-admin/includes/update.php ---- wordpress/wp-admin/includes/update.php.rpm 2014-11-30 12:28:24.000000000 +0100 -+++ wordpress/wp-admin/includes/update.php 2014-12-22 06:46:28.487097611 +0100 +diff -up wordpress/wp-admin/includes/update.php.noupdate wordpress/wp-admin/includes/update.php +--- wordpress/wp-admin/includes/update.php.noupdate 2015-04-24 10:37:28.288734495 +0200 ++++ wordpress/wp-admin/includes/update.php 2015-04-24 10:37:46.985814124 +0200 @@ -211,8 +211,6 @@ function update_nag() { } echo "
    $msg
    "; @@ -36,15 +36,15 @@ diff -up wordpress/wp-admin/includes/update.php.rpm wordpress/wp-admin/includes/ $cur = get_preferred_from_update_core(); if ( isset( $cur->response ) && $cur->response == 'upgrade' ) -- $msg .= " " . sprintf( __('Update to %s'), $cur->current ? $cur->current : __( 'Latest' ) ) . ''; +- $msg .= '' . sprintf( __( 'Update to %s' ), $cur->current ? $cur->current : __( 'Latest' ) ) . ' '; + $msg .= ''; } - echo "

    $msg

    "; -diff -up wordpress/wp-includes/capabilities.php.rpm wordpress/wp-includes/capabilities.php ---- wordpress/wp-includes/capabilities.php.rpm 2014-12-01 02:34:24.000000000 +0100 -+++ wordpress/wp-includes/capabilities.php 2014-12-22 06:46:28.487097611 +0100 -@@ -1255,7 +1255,7 @@ function map_meta_cap( $cap, $user_id ) + $msg .= sprintf( '' . __( 'WordPress %1$s running %2$s theme.' ) . '', get_bloginfo( 'version', 'display' ), $theme_name ); +diff -up wordpress/wp-includes/capabilities.php.noupdate wordpress/wp-includes/capabilities.php +--- wordpress/wp-includes/capabilities.php.noupdate 2015-04-20 09:27:27.000000000 +0200 ++++ wordpress/wp-includes/capabilities.php 2015-04-24 10:33:31.167724617 +0200 +@@ -1281,7 +1281,7 @@ function map_meta_cap( $cap, $user_id ) // Disallow the file editors. if ( defined( 'DISALLOW_FILE_EDIT' ) && DISALLOW_FILE_EDIT ) $caps[] = 'do_not_allow'; @@ -53,7 +53,7 @@ diff -up wordpress/wp-includes/capabilities.php.rpm wordpress/wp-includes/capabi $caps[] = 'do_not_allow'; elseif ( is_multisite() && ! is_super_admin( $user_id ) ) $caps[] = 'do_not_allow'; -@@ -1273,7 +1273,7 @@ function map_meta_cap( $cap, $user_id ) +@@ -1299,7 +1299,7 @@ function map_meta_cap( $cap, $user_id ) case 'update_core': // Disallow anything that creates, deletes, or updates core, plugin, or theme files. // Files in uploads are excepted. @@ -62,9 +62,9 @@ diff -up wordpress/wp-includes/capabilities.php.rpm wordpress/wp-includes/capabi $caps[] = 'do_not_allow'; } elseif ( is_multisite() && ! is_super_admin( $user_id ) ) { $caps[] = 'do_not_allow'; -diff -up wordpress/wp-includes/update.php.rpm wordpress/wp-includes/update.php ---- wordpress/wp-includes/update.php.rpm 2014-12-22 06:48:34.883575009 +0100 -+++ wordpress/wp-includes/update.php 2014-12-22 06:48:44.144609988 +0100 +diff -up wordpress/wp-includes/update.php.noupdate wordpress/wp-includes/update.php +--- wordpress/wp-includes/update.php.noupdate 2015-03-18 23:07:28.000000000 +0100 ++++ wordpress/wp-includes/update.php 2015-04-24 10:33:31.167724617 +0200 @@ -624,9 +624,6 @@ function _maybe_update_themes() { * @since 3.1.0 */ @@ -75,7 +75,7 @@ diff -up wordpress/wp-includes/update.php.rpm wordpress/wp-includes/update.php if ( !wp_next_scheduled('wp_update_plugins') && !defined('WP_INSTALLING') ) wp_schedule_event(time(), 'twicedaily', 'wp_update_plugins'); -@@ -669,8 +666,6 @@ if ( ( ! is_main_site() && ! is_network_ +@@ -668,8 +665,6 @@ if ( ( ! is_main_site() && ! is_network_ } add_action( 'admin_init', '_maybe_update_core' ); diff --git a/wordpress.spec b/wordpress.spec index 21cd9a2..716da6e 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -16,7 +16,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 4.1.3 +Version: 4.2.1 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -33,7 +33,7 @@ Patch0: wordpress-debian_patches_hello.patch # This patch doesn’t work well, see bugzilla.redhat.com/522897 Patch1: wordpress-move-wp-content.patch # Drop swfupload: not built from source, not reasonably possible to do -Patch2: wordpress-3.9-no_swfupload.patch +Patch2: wordpress-4.2-no_swfupload.patch # Adjust tinymce's media plugin not to use its SWF plugin. This changes # 'p.getParam("flash_video_player_url",u.convertUrl(u.url+"/moxieplayer.swf"))' # to 'false' @@ -41,7 +41,7 @@ Patch3: wordpress-4.0-tinymce_noflash.patch # Adjust mediaelement not to use its SWF and Silverlight plugins. This # changes 'plugins:["flash,"silverlight","youtube","vimeo"]' to # 'plugins:["youtube","vimeo"]' -Patch4: wordpress-4.1-mediaelement-noflash_silverlight.patch +Patch4: wordpress-4.2-mediaelement-noflash_silverlight.patch # RPM configuration: # Path to installation # Disable auto-updater @@ -50,7 +50,7 @@ Patch5: wordpress-4.0-config.patch # disable version check and updated # change DISALLOW_FILE_MODS default value to true # ignore WP_AUTO_UPDATE_CORE (always false) -Patch6: wordpress-4.1-noupdate.patch +Patch6: wordpress-4.2-noupdate.patch # Use system libraries Patch7: wordpress-4.0-systemlibs.patch @@ -281,6 +281,10 @@ rm -rf ${RPM_BUILD_ROOT} %changelog +* Tue Apr 28 2015 Remi Collet - 4.2.1-1 +- WordPress 4.2.1 Security Release +- WordPress 4.2 “Powell” + * Fri Apr 24 2015 Remi Collet - 4.1.3-1 - WordPress 4.1.3 Maintenance Release From 6d48e60a95afd012ed7702dd1bc12efcf4bbdd17 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Thu, 7 May 2015 07:07:02 +0200 Subject: [PATCH 20/20] WordPress 4.2.2 Security and Maintenance Release (cherry picked from commit c3247e0fb051f1f0ae1abeb5a21e140d9d266368) --- .gitignore | 1 + sources | 2 +- wordpress.spec | 5 ++++- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 0642600..bfd35d4 100644 --- a/.gitignore +++ b/.gitignore @@ -16,3 +16,4 @@ clog /wordpress-4.1.2.tar.gz /wordpress-4.2.tar.gz /wordpress-4.2.1.tar.gz +/wordpress-4.2.2.tar.gz diff --git a/sources b/sources index 2d0742f..21680fc 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -71eef0d7c8b26fc7b65c41449eefbb2a wordpress-4.2.1.tar.gz +c40d56cf85975482d5f5fa8c4b97d1d2 wordpress-4.2.2.tar.gz diff --git a/wordpress.spec b/wordpress.spec index 716da6e..f93481e 100644 --- a/wordpress.spec +++ b/wordpress.spec @@ -16,7 +16,7 @@ Summary: Blog tool and publishing platform URL: http://www.wordpress.org Name: wordpress -Version: 4.2.1 +Version: 4.2.2 Group: Applications/Publishing Release: 1%{?dist} License: GPLv2 @@ -281,6 +281,9 @@ rm -rf ${RPM_BUILD_ROOT} %changelog +* Thu May 7 2015 Remi Collet - 4.2.2-1 +- WordPress 4.2.2 Security and Maintenance Release + * Tue Apr 28 2015 Remi Collet - 4.2.1-1 - WordPress 4.2.1 Security Release - WordPress 4.2 “Powell”