From 68dacf2b5b198dac82f38b09617175b4087f9af1 Mon Sep 17 00:00:00 2001 From: Remi Collet Date: Tue, 31 May 2016 16:32:29 +0200 Subject: owncloud: 9.0.2 --- owncloud-8.1.6-work-arround-nss-issue.patch | 50 ++++ owncloud-8.2.2-dont_update_htacess.patch | 51 ---- owncloud-8.2.3-dont_warn_php54_eol.patch | 16 ++ owncloud-8.2.3-dropbox-autoloader.patch | 25 -- owncloud-8.2.3-google-autoloader.patch | 29 --- owncloud-8.2.3-icewind-streams-encryption.patch | 40 ---- owncloud-8.2.5-videoviewer_noplugins.patch | 12 - owncloud-9.0.1-dont_update_htacess.patch | 47 ++++ owncloud-9.0.1-dropbox-autoloader.patch | 25 ++ owncloud-9.0.1-google-autoloader.patch | 37 +++ ...ud-9.0.2-default_integrity_check_disabled.patch | 13 + ...d-9.0.2-no_need_for_broken_updater_repair.patch | 12 + owncloud-conf-nginx.conf | 4 + owncloud-default-nginx.conf | 78 ++++++ owncloud-delete-nonfree.sh | 21 -- owncloud-el7-php-fpm.conf | 24 ++ owncloud-nginx.conf | 79 ------- owncloud-php-fpm.conf | 25 ++ owncloud.spec | 262 ++++++++++++--------- 19 files changed, 483 insertions(+), 367 deletions(-) create mode 100644 owncloud-8.1.6-work-arround-nss-issue.patch delete mode 100644 owncloud-8.2.2-dont_update_htacess.patch create mode 100644 owncloud-8.2.3-dont_warn_php54_eol.patch delete mode 100644 owncloud-8.2.3-dropbox-autoloader.patch delete mode 100644 owncloud-8.2.3-google-autoloader.patch delete mode 100644 owncloud-8.2.3-icewind-streams-encryption.patch delete mode 100644 owncloud-8.2.5-videoviewer_noplugins.patch create mode 100644 owncloud-9.0.1-dont_update_htacess.patch create mode 100644 owncloud-9.0.1-dropbox-autoloader.patch create mode 100644 owncloud-9.0.1-google-autoloader.patch create mode 100644 owncloud-9.0.2-default_integrity_check_disabled.patch create mode 100644 owncloud-9.0.2-no_need_for_broken_updater_repair.patch create mode 100644 owncloud-conf-nginx.conf create mode 100644 owncloud-default-nginx.conf delete mode 100755 owncloud-delete-nonfree.sh create mode 100644 owncloud-el7-php-fpm.conf delete mode 100644 owncloud-nginx.conf create mode 100644 owncloud-php-fpm.conf diff --git a/owncloud-8.1.6-work-arround-nss-issue.patch b/owncloud-8.1.6-work-arround-nss-issue.patch new file mode 100644 index 0000000..5a10748 --- /dev/null +++ b/owncloud-8.1.6-work-arround-nss-issue.patch @@ -0,0 +1,50 @@ +diff --git a/settings/controller/checksetupcontroller.php b/settings/controller/checksetupcontroller.php +index f849e3e..acfbc4e 100644 +--- a/settings/controller/checksetupcontroller.php ++++ b/settings/controller/checksetupcontroller.php +@@ -83,8 +83,8 @@ class CheckSetupController extends Controller { + + try { + $client = $this->clientService->newClient(); +- $client->get('https://www.owncloud.org/'); +- $client->get('http://www.owncloud.org/'); ++ $client->get('https://owncloud.org/'); ++ $client->get('http://owncloud.org/'); + return true; + } catch (\Exception $e) { + return false; +@@ -162,13 +162,13 @@ class CheckSetupController extends Controller { + if(strpos($versionString, 'NSS/') === 0) { + try { + $firstClient = $this->clientService->newClient(); +- $firstClient->get('https://www.owncloud.org/'); ++ $firstClient->get('https://api.owncloud.com/'); + + $secondClient = $this->clientService->newClient(); +- $secondClient->get('https://owncloud.org/'); ++ $secondClient->get('https://apps.owncloud.com/'); + } catch (ClientException $e) { + if($e->getResponse()->getStatusCode() === 400) { +- return (string) $this->l10n->t('cURL is using an outdated %s version (%s). Please update your operating system or features such as %s will not work reliably.', ['NSS', $versionString, $features]); ++ return (string) $this->l10n->t('cURL is using %s version (%s). There may be an issue with features such as %s, this is expected to fixed in the RHEL7.3 milestone - bz#1241172', ['NSS', $versionString, $features]); + } + } + } +diff --git a/lib/private/ocsclient.php b/lib/private/ocsclient.php +index 359b5b4..28370f1 100644 +--- a/lib/private/ocsclient.php ++++ b/lib/private/ocsclient.php +@@ -344,7 +344,12 @@ class OCSClient { + $tmp = $data->data->content; + $app = []; + if (isset($tmp->downloadlink)) { +- $app['downloadlink'] = (string)$tmp->downloadlink; ++ if (preg_match("/apps\.owncloud\.com/", (string)$tmp->downloadlink)) { ++ $downloadURL = preg_replace("/apps\.owncloud\.com/", "api.owncloud.com", (string)$tmp->downloadlink); ++ } else { ++ $downloadURL = (string)$tmp->downloadlink; ++ } ++ $app['downloadlink'] = $downloadURL; + } else { + $app['downloadlink'] = ''; + } diff --git a/owncloud-8.2.2-dont_update_htacess.patch b/owncloud-8.2.2-dont_update_htacess.patch deleted file mode 100644 index 4db8819..0000000 --- a/owncloud-8.2.2-dont_update_htacess.patch +++ /dev/null @@ -1,51 +0,0 @@ -diff --git a/lib/private/setup.php b/lib/private/setup.php -index 8f1ae38..adc9f6a 100644 ---- a/lib/private/setup.php -+++ b/lib/private/setup.php -@@ -369,12 +369,6 @@ class Setup { - // out that this is indeed an ownCloud data directory - file_put_contents($config->getSystemValue('datadirectory', \OC::$SERVERROOT.'/data').'/.ocdata', ''); - -- // Update htaccess files for apache hosts -- if (isset($_SERVER['SERVER_SOFTWARE']) && strstr($_SERVER['SERVER_SOFTWARE'], 'Apache')) { -- self::updateHtaccess(); -- self::protectDataDirectory(); -- } -- - //try to write logtimezone - if (date_default_timezone_get()) { - $config->setSystemValue('logtimezone', date_default_timezone_get()); -diff --git a/lib/private/updater.php b/lib/private/updater.php -index 9e5207c..6a169a6 100644 ---- a/lib/private/updater.php -+++ b/lib/private/updater.php -@@ -285,14 +285,6 @@ class Updater extends BasicEmitter { - throw new \Exception('Updates between multiple major versions and downgrades are unsupported.'); - } - -- // Update .htaccess files -- try { -- Setup::updateHtaccess(); -- Setup::protectDataDirectory(); -- } catch (\Exception $e) { -- throw new \Exception($e->getMessage()); -- } -- - // create empty file in data dir, so we can later find - // out that this is indeed an ownCloud data directory - // (in case it didn't exist before) -diff -up lib/private/setup.php.0 lib/private/setup.php ---- a/lib/private/setup.php.0 2016-03-23 08:12:31.399538916 +0100 -+++ b/lib/private/setup.php 2016-03-23 08:13:55.783981179 +0100 -@@ -415,6 +415,10 @@ class Setup { - * @throws \OC\HintException If .htaccess does not include the current version - */ - public static function updateHtaccess() { -+ -+ // Should never be called, but for safety -+ return; -+ - $setupHelper = new \OC\Setup(\OC::$server->getConfig(), \OC::$server->getIniWrapper(), - \OC::$server->getL10N('lib'), new \OC_Defaults(), \OC::$server->getLogger(), - \OC::$server->getSecureRandom()); - diff --git a/owncloud-8.2.3-dont_warn_php54_eol.patch b/owncloud-8.2.3-dont_warn_php54_eol.patch new file mode 100644 index 0000000..c3454b2 --- /dev/null +++ b/owncloud-8.2.3-dont_warn_php54_eol.patch @@ -0,0 +1,16 @@ +diff --git a/settings/controller/checksetupcontroller.php b/settings/controller/checksetupcontroller.php +index bd0737a..064058a 100644 +--- a/settings/controller/checksetupcontroller.php ++++ b/settings/controller/checksetupcontroller.php +@@ -205,10 +205,7 @@ class CheckSetupController extends Controller { + private function isPhpSupported() { + $eol = false; + +- //PHP 5.4 is EOL on 14 Sep 2015 +- if (version_compare(PHP_VERSION, '5.5.0') === -1) { +- $eol = true; +- } ++ // Red Hat provide support for the system PHP so never eol + + return ['eol' => $eol, 'version' => PHP_VERSION]; + } diff --git a/owncloud-8.2.3-dropbox-autoloader.patch b/owncloud-8.2.3-dropbox-autoloader.patch deleted file mode 100644 index 8cfd754..0000000 --- a/owncloud-8.2.3-dropbox-autoloader.patch +++ /dev/null @@ -1,25 +0,0 @@ -diff --git a/apps/files_external/ajax/oauth1.php b/apps/files_external/ajax/oauth1.php -index 3d6736b..028d21a 100644 ---- a/apps/files_external/ajax/oauth1.php -+++ b/apps/files_external/ajax/oauth1.php -@@ -23,7 +23,6 @@ - * along with this program. If not, see - * - */ --require_once __DIR__ . '/../3rdparty/Dropbox/autoload.php'; - - OCP\JSON::checkAppEnabled('files_external'); - OCP\JSON::checkLoggedIn(); -diff --git a/apps/files_external/lib/dropbox.php b/apps/files_external/lib/dropbox.php -index 6a822c3..b8e7f27 100644 ---- a/apps/files_external/lib/dropbox.php -+++ b/apps/files_external/lib/dropbox.php -@@ -31,8 +31,6 @@ namespace OC\Files\Storage; - - use Icewind\Streams\IteratorDirectory; - --require_once __DIR__ . '/../3rdparty/Dropbox/autoload.php'; -- - class Dropbox extends \OC\Files\Storage\Common { - - private $dropbox; diff --git a/owncloud-8.2.3-google-autoloader.patch b/owncloud-8.2.3-google-autoloader.patch deleted file mode 100644 index bf94192..0000000 --- a/owncloud-8.2.3-google-autoloader.patch +++ /dev/null @@ -1,29 +0,0 @@ -diff --git a/apps/files_external/ajax/oauth2.php b/apps/files_external/ajax/oauth2.php -index fbe60e1..bc7d285 100644 ---- a/apps/files_external/ajax/oauth2.php -+++ b/apps/files_external/ajax/oauth2.php -@@ -25,9 +25,6 @@ - * along with this program. If not, see - * - */ --set_include_path(get_include_path().PATH_SEPARATOR. -- \OC_App::getAppPath('files_external').'/3rdparty/google-api-php-client/src'); --require_once 'Google/Client.php'; - - OCP\JSON::checkAppEnabled('files_external'); - OCP\JSON::checkLoggedIn(); -diff --git a/apps/files_external/lib/google.php b/apps/files_external/lib/google.php -index eba2ee7..9ed0de1 100644 ---- a/apps/files_external/lib/google.php -+++ b/apps/files_external/lib/google.php -@@ -35,10 +35,6 @@ namespace OC\Files\Storage; - - use Icewind\Streams\IteratorDirectory; - --set_include_path(get_include_path().PATH_SEPARATOR. -- \OC_App::getAppPath('files_external').'/3rdparty/google-api-php-client/src'); --require_once 'Google/Client.php'; --require_once 'Google/Service/Drive.php'; - - class Google extends \OC\Files\Storage\Common { - diff --git a/owncloud-8.2.3-icewind-streams-encryption.patch b/owncloud-8.2.3-icewind-streams-encryption.patch deleted file mode 100644 index 177aad2..0000000 --- a/owncloud-8.2.3-icewind-streams-encryption.patch +++ /dev/null @@ -1,40 +0,0 @@ -diff --git a/lib/private/files/stream/encryption.php b/lib/private/files/stream/encryption.php -index e0d263d..4c32899 100644 ---- a/lib/private/files/stream/encryption.php -+++ b/lib/private/files/stream/encryption.php -@@ -471,4 +471,13 @@ protected function parentStreamSeek($position) { - return parent::stream_seek($position); - } - -+ /** -+ * @param string $path -+ * @param array $options -+ * @return bool -+ */ -+ public function dir_opendir($path, $options) { -+ return false; -+ } -+ - } -diff --git a/lib/private/files/stream/encryption.php b/lib/private/files/stream/encryption.php -index 4c32899..585a697 100644 ---- a/lib/private/files/stream/encryption.php -+++ b/lib/private/files/stream/encryption.php -@@ -167,7 +167,7 @@ public static function wrap($source, $internalPath, $fullPath, array $header, - ) - )); - -- return self::wrapSource($source, $mode, $context, 'ocencryption', $wrapper); -+ return self::wrapSource($source, $context, 'ocencryption', $wrapper, $mode); - } - - /** -@@ -181,7 +181,7 @@ public static function wrap($source, $internalPath, $fullPath, array $header, - * @return resource - * @throws \BadMethodCallException - */ -- protected static function wrapSource($source, $mode, $context, $protocol, $class) { -+ protected static function wrapSource($source, $context, $protocol, $class, $mode = 'r+') { - try { - stream_wrapper_register($protocol, $class); - if (@rewinddir($source) === false) { diff --git a/owncloud-8.2.5-videoviewer_noplugins.patch b/owncloud-8.2.5-videoviewer_noplugins.patch deleted file mode 100644 index 76397bc..0000000 --- a/owncloud-8.2.5-videoviewer_noplugins.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -up ./apps/files_videoviewer/js/mediaelement-and-player.min.js.old ./apps/files_videoviewer/js/mediaelement-and-player.min.js ---- ./apps/files_videoviewer/js/mediaelement-and-player.min.js.old 2016-05-12 21:27:46.908612955 +0200 -+++ ./apps/files_videoviewer/js/mediaelement-and-player.min.js 2016-05-12 21:27:54.536649605 +0200 -@@ -12,7 +12,7 @@ - * License: MIT - * - */ --var mejs=mejs||{};mejs.version="2.21.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/dailymotion","video/x-dailymotion","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},calculateTimeFormat:function(a,b,c){0>a&&(a=0),"undefined"==typeof c&&(c=25);var d=b.timeFormat,e=d[0],f=d[1]==d[0],g=f?2:1,h=":",i=Math.floor(a/3600)%24,j=Math.floor(a/60)%60,k=Math.floor(a%60),l=Math.floor((a%1*c).toFixed(3)),m=[[l,"f"],[k,"s"],[j,"m"],[i,"h"]];d.lengtho;o++)if(-1!==d.indexOf(m[o][1]))n=!0;else if(n){for(var q=!1,r=o;p>r;r++)if(m[r][0]>0){q=!0;break}if(!q)break;f||(d=e+d),d=m[o][1]+h+d,f&&(d=m[o][1]+d),e=m[o][1]}b.currentTimeFormat=d},twoDigitsString:function(a){return 10>a?"0"+a:String(a)},secondsToTimeCode:function(a,b){if(0>a&&(a=0),"object"!=typeof b){var c="m:ss";c=arguments[1]?"hh:mm:ss":c,c=arguments[2]?c+":ff":c,b={currentTimeFormat:c,framesPerSecond:arguments[3]||25}}var d=b.framesPerSecond;"undefined"==typeof d&&(d=25);var c=b.currentTimeFormat,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));lis=[[h,"f"],[g,"s"],[f,"m"],[e,"h"]];var j=c;for(i=0,len=lis.length;i0&&(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)}},determineScheme:function(a){return a&&-1!=a.indexOf("://")?a.substr(0,a.indexOf("://")+3):"//"}},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":""}),mejs.MediaFeatures.isChromium&&(a.canPlayType=function(a){return null!==a.match(/video\/(webm|ogv|ogg)/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(),c=/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video/":"audio/";return this.getTypeFromExtension(b,c)},getTypeFromExtension:function(a,b){switch(b=b||"",a){case"mp4":case"m4v":case"m4a":case"f4v":case"f4a":return b+"mp4";case"flv":return b+"x-flv";case"webm":case"webma":case"webmv":return b+"webm";case"ogg":case"oga":case"ogv":return b+"ogg";case"m3u8":return"application/x-mpegurl";case"ts":return b+"mp2t";default:return b+a}},createErrorMessage:function(a,b,c){var d=a.htmlMediaElement,e=document.createElement("div"),f=b.customError;e.className="me-cannotplay";try{e.style.width=d.width+"px",e.style.height=d.height+"px"}catch(g){}f||(f='',""!==c&&(f+=''),f+=""+mejs.i18n.t("Download File")+""),e.innerHTML=f,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,o.className="me-plugin",o.id=m+"_container",a.isVideo?j.parentNode.insertBefore(o,j):document.body.insertBefore(o,document.body.childNodes[0]),("flash"===a.method||"silverlight"===a.method)&&(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&&("flash"==a.method?i.push("file="+mejs.Utility.encodeUrl(a.url)):i.push("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)),window[m+"_init"]=function(){switch(n.pluginType){case"flash":n.pluginElement=n.pluginApi=document.getElementById(m);break;case"silverlight":n.pluginElement=document.getElementById(n.id),n.pluginApi=n.pluginElement.Content.MediaElementJS}null!=n.pluginApi&&n.success&&n.success(n,j)},window[m+"_event"]=function(a,b){var c,d,e;c={type:a,target:n};for(d in b)n[d]=b[d],c[d]=b[d];e=b.bufferedTime||0,c.target.buffered=c.buffered={start:function(a){return 0},end:function(a){return e},length:1},n.dispatchEvent(c)}),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,scheme:a.scheme},window.postMessage?mejs.YouTubeApi.enqueueIframe(youtubeSettings):mejs.PluginDetector.hasPluginVersion("flash",[10,0,0])&&mejs.YouTubeApi.createFlash(youtubeSettings,b);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]),u=-1;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)}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.getPlayerState=function(){return u},t.addEvent("play",function(){u=1,a(t,n,"play"),a(t,n,"playing")}),t.addEvent("pause",function(){u=2,a(t,n,"pause")}),t.addEvent("finish",function(){u=0,a(t,n,"ended")}),t.addEvent("playProgress",function(b){a(t,n,"timeupdate",b)}),t.addEvent("seek",function(b){u=3,a(t,n,"seeked",b)}),t.addEvent("loadProgress",function(b){u=3,a(t,n,"progress",b)}),n.pluginElement=o,n.pluginApi=t,n.success(n,n.pluginElement)})}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,c,d){var e,f=a.htmlMediaElement;for(e in mejs.HtmlMediaElement)f[e]=mejs.HtmlMediaElement[e];return b.success(f,f),f}},mejs.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(a){if(!this.isIframeStarted){var b=document.createElement("script");b.src=a.scheme+"www.youtube.com/player_api";var c=document.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(a),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,wmode:"transparent"},events:{onReady:function(){c.setVideoSize=function(a,b){c.setSize(a,b)},a.pluginMediaElement.pluginApi=c,a.pluginMediaElement.pluginElement=document.getElementById(a.containerId),b.success(b,b.pluginElement),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(a){return 0},end:function(a){return e},length:1}}b.dispatchEvent(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=a.scheme+"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,b.success(d,d.pluginElement),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.onYouTubePlayerAPIReady=function(){mejs.YouTubeApi.iFrameReady()},window.onYouTubePlayerReady=function(a){mejs.YouTubeApi.flashReady(a)},window.mejs=mejs,window.MediaElement=mejs.MediaElement,function(a,b,c){"use strict";var d={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:{}};d.getLanguage=function(){var a=d.locale.language||window.navigator.userLanguage||window.navigator.language;return d.ietf_lang_regex.exec(a)?a:null},"undefined"!=typeof mejsL10n&&(d.locale.language=mejsL10n.language),d.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},d.methods.t=function(a,b){return d.locale.strings&&d.locale.strings[b.context]&&d.locale.strings[b.context][a]&&(a=d.locale.strings[b.context][a]),d.methods.checkPlain(a)},d.t=function(a,b){if("string"==typeof a&&a.length>0){var c=d.getLanguage();return b=b||{context:c},d.methods.t(a,b)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=d}(document,mejs),function(a,b){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(mejs.i18n.locale.strings),/*! -+var mejs=mejs||{};mejs.version="2.21.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/dailymotion","video/x-dailymotion","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},calculateTimeFormat:function(a,b,c){0>a&&(a=0),"undefined"==typeof c&&(c=25);var d=b.timeFormat,e=d[0],f=d[1]==d[0],g=f?2:1,h=":",i=Math.floor(a/3600)%24,j=Math.floor(a/60)%60,k=Math.floor(a%60),l=Math.floor((a%1*c).toFixed(3)),m=[[l,"f"],[k,"s"],[j,"m"],[i,"h"]];d.lengtho;o++)if(-1!==d.indexOf(m[o][1]))n=!0;else if(n){for(var q=!1,r=o;p>r;r++)if(m[r][0]>0){q=!0;break}if(!q)break;f||(d=e+d),d=m[o][1]+h+d,f&&(d=m[o][1]+d),e=m[o][1]}b.currentTimeFormat=d},twoDigitsString:function(a){return 10>a?"0"+a:String(a)},secondsToTimeCode:function(a,b){if(0>a&&(a=0),"object"!=typeof b){var c="m:ss";c=arguments[1]?"hh:mm:ss":c,c=arguments[2]?c+":ff":c,b={currentTimeFormat:c,framesPerSecond:arguments[3]||25}}var d=b.framesPerSecond;"undefined"==typeof d&&(d=25);var c=b.currentTimeFormat,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));lis=[[h,"f"],[g,"s"],[f,"m"],[e,"h"]];var j=c;for(i=0,len=lis.length;i0&&(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)}},determineScheme:function(a){return a&&-1!=a.indexOf("://")?a.substr(0,a.indexOf("://")+3):"//"}},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":""}),mejs.MediaFeatures.isChromium&&(a.canPlayType=function(a){return null!==a.match(/video\/(webm|ogv|ogg)/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(),c=/(mp4|m4v|ogg|ogv|m3u8|webm|webmv|flv|wmv|mpeg|mov)/gi.test(b)?"video/":"audio/";return this.getTypeFromExtension(b,c)},getTypeFromExtension:function(a,b){switch(b=b||"",a){case"mp4":case"m4v":case"m4a":case"f4v":case"f4a":return b+"mp4";case"flv":return b+"x-flv";case"webm":case"webma":case"webmv":return b+"webm";case"ogg":case"oga":case"ogv":return b+"ogg";case"m3u8":return"application/x-mpegurl";case"ts":return b+"mp2t";default:return b+a}},createErrorMessage:function(a,b,c){var d=a.htmlMediaElement,e=document.createElement("div"),f=b.customError;e.className="me-cannotplay";try{e.style.width=d.width+"px",e.style.height=d.height+"px"}catch(g){}f||(f='',""!==c&&(f+=''),f+=""+mejs.i18n.t("Download File")+""),e.innerHTML=f,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,o.className="me-plugin",o.id=m+"_container",a.isVideo?j.parentNode.insertBefore(o,j):document.body.insertBefore(o,document.body.childNodes[0]),("flash"===a.method||"silverlight"===a.method)&&(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&&("flash"==a.method?i.push("file="+mejs.Utility.encodeUrl(a.url)):i.push("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)),window[m+"_init"]=function(){switch(n.pluginType){case"flash":n.pluginElement=n.pluginApi=document.getElementById(m);break;case"silverlight":n.pluginElement=document.getElementById(n.id),n.pluginApi=n.pluginElement.Content.MediaElementJS}null!=n.pluginApi&&n.success&&n.success(n,j)},window[m+"_event"]=function(a,b){var c,d,e;c={type:a,target:n};for(d in b)n[d]=b[d],c[d]=b[d];e=b.bufferedTime||0,c.target.buffered=c.buffered={start:function(a){return 0},end:function(a){return e},length:1},n.dispatchEvent(c)}),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,scheme:a.scheme},window.postMessage?mejs.YouTubeApi.enqueueIframe(youtubeSettings):mejs.PluginDetector.hasPluginVersion("flash",[10,0,0])&&mejs.YouTubeApi.createFlash(youtubeSettings,b);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]),u=-1;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)}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.getPlayerState=function(){return u},t.addEvent("play",function(){u=1,a(t,n,"play"),a(t,n,"playing")}),t.addEvent("pause",function(){u=2,a(t,n,"pause")}),t.addEvent("finish",function(){u=0,a(t,n,"ended")}),t.addEvent("playProgress",function(b){a(t,n,"timeupdate",b)}),t.addEvent("seek",function(b){u=3,a(t,n,"seeked",b)}),t.addEvent("loadProgress",function(b){u=3,a(t,n,"progress",b)}),n.pluginElement=o,n.pluginApi=t,n.success(n,n.pluginElement)})}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,c,d){var e,f=a.htmlMediaElement;for(e in mejs.HtmlMediaElement)f[e]=mejs.HtmlMediaElement[e];return b.success(f,f),f}},mejs.YouTubeApi={isIframeStarted:!1,isIframeLoaded:!1,loadIframeApi:function(a){if(!this.isIframeStarted){var b=document.createElement("script");b.src=a.scheme+"www.youtube.com/player_api";var c=document.getElementsByTagName("script")[0];c.parentNode.insertBefore(b,c),this.isIframeStarted=!0}},iframeQueue:[],enqueueIframe:function(a){this.isLoaded?this.createIframe(a):(this.loadIframeApi(a),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,wmode:"transparent"},events:{onReady:function(){c.setVideoSize=function(a,b){c.setSize(a,b)},a.pluginMediaElement.pluginApi=c,a.pluginMediaElement.pluginElement=document.getElementById(a.containerId),b.success(b,b.pluginElement),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(a){return 0},end:function(a){return e},length:1}}b.dispatchEvent(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=a.scheme+"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,b.success(d,d.pluginElement),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.onYouTubePlayerAPIReady=function(){mejs.YouTubeApi.iFrameReady()},window.onYouTubePlayerReady=function(a){mejs.YouTubeApi.flashReady(a)},window.mejs=mejs,window.MediaElement=mejs.MediaElement,function(a,b,c){"use strict";var d={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:{}};d.getLanguage=function(){var a=d.locale.language||window.navigator.userLanguage||window.navigator.language;return d.ietf_lang_regex.exec(a)?a:null},"undefined"!=typeof mejsL10n&&(d.locale.language=mejsL10n.language),d.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},d.methods.t=function(a,b){return d.locale.strings&&d.locale.strings[b.context]&&d.locale.strings[b.context][a]&&(a=d.locale.strings[b.context][a]),d.methods.checkPlain(a)},d.t=function(a,b){if("string"==typeof a&&a.length>0){var c=d.getLanguage();return b=b||{context:c},d.methods.t(a,b)}throw{name:"InvalidArgumentException",message:"First argument is either not a string or empty."}},b.i18n=d}(document,mejs),function(a,b){"use strict";"undefined"!=typeof mejsL10n&&(a[mejsL10n.language]=mejsL10n.strings)}(mejs.i18n.locale.strings),/*! - * - * MediaElementPlayer - * http://mediaelementjs.com/ diff --git a/owncloud-9.0.1-dont_update_htacess.patch b/owncloud-9.0.1-dont_update_htacess.patch new file mode 100644 index 0000000..d6c4efe --- /dev/null +++ b/owncloud-9.0.1-dont_update_htacess.patch @@ -0,0 +1,47 @@ +diff --git a/lib/private/setup.php b/lib/private/setup.php +index 6303d0d..7c30955 100644 +--- a/lib/private/setup.php ++++ b/lib/private/setup.php +@@ -373,10 +373,6 @@ class Setup { + // out that this is indeed an ownCloud data directory + file_put_contents($config->getSystemValue('datadirectory', \OC::$SERVERROOT.'/data').'/.ocdata', ''); + +- // Update .htaccess files +- Setup::updateHtaccess(); +- Setup::protectDataDirectory(); +- + //try to write logtimezone + if (date_default_timezone_get()) { + $config->setSystemValue('logtimezone', date_default_timezone_get()); +diff --git a/lib/private/updater.php b/lib/private/updater.php +index 0d567b8..6b0b1ad 100644 +--- a/lib/private/updater.php ++++ b/lib/private/updater.php +@@ -55,10 +55,10 @@ class Updater extends BasicEmitter { + + /** @var ILogger $log */ + private $log; +- ++ + /** @var \OC\HTTPHelper $helper */ + private $httpHelper; +- ++ + /** @var IConfig */ + private $config; + +@@ -294,14 +294,6 @@ class Updater extends BasicEmitter { + throw new \Exception('Updates between multiple major versions and downgrades are unsupported.'); + } + +- // Update .htaccess files +- try { +- Setup::updateHtaccess(); +- Setup::protectDataDirectory(); +- } catch (\Exception $e) { +- throw new \Exception($e->getMessage()); +- } +- + // create empty file in data dir, so we can later find + // out that this is indeed an ownCloud data directory + // (in case it didn't exist before) diff --git a/owncloud-9.0.1-dropbox-autoloader.patch b/owncloud-9.0.1-dropbox-autoloader.patch new file mode 100644 index 0000000..8b94444 --- /dev/null +++ b/owncloud-9.0.1-dropbox-autoloader.patch @@ -0,0 +1,25 @@ +diff --git a/apps/files_external/ajax/oauth1.php b/apps/files_external/ajax/oauth1.php +index ea7db25..4279cec 100644 +--- a/apps/files_external/ajax/oauth1.php ++++ b/apps/files_external/ajax/oauth1.php +@@ -23,7 +23,6 @@ + * along with this program. If not, see + * + */ +-require_once __DIR__ . '/../3rdparty/Dropbox/autoload.php'; + + OCP\JSON::checkAppEnabled('files_external'); + OCP\JSON::checkLoggedIn(); +diff --git a/apps/files_external/lib/dropbox.php b/apps/files_external/lib/dropbox.php +index 8381ccb..174baec 100644 +--- a/apps/files_external/lib/dropbox.php ++++ b/apps/files_external/lib/dropbox.php +@@ -33,8 +33,6 @@ use GuzzleHttp\Exception\RequestException; + use Icewind\Streams\IteratorDirectory; + use Icewind\Streams\RetryWrapper; + +-require_once __DIR__ . '/../3rdparty/Dropbox/autoload.php'; +- + class Dropbox extends \OC\Files\Storage\Common { + + private $dropbox; diff --git a/owncloud-9.0.1-google-autoloader.patch b/owncloud-9.0.1-google-autoloader.patch new file mode 100644 index 0000000..09f50e8 --- /dev/null +++ b/owncloud-9.0.1-google-autoloader.patch @@ -0,0 +1,37 @@ +diff --git a/apps/files_external/ajax/oauth2.php b/apps/files_external/ajax/oauth2.php +index b110cba..1367c7b 100644 +--- a/apps/files_external/ajax/oauth2.php ++++ b/apps/files_external/ajax/oauth2.php +@@ -26,9 +26,6 @@ + * along with this program. If not, see + * + */ +-set_include_path(get_include_path().PATH_SEPARATOR. +- \OC_App::getAppPath('files_external').'/3rdparty/google-api-php-client/src'); +-require_once 'Google/Client.php'; + + OCP\JSON::checkAppEnabled('files_external'); + OCP\JSON::checkLoggedIn(); +diff --git a/apps/files_external/lib/google.php b/apps/files_external/lib/google.php +index 62d264d..45b87c6 100644 +--- a/apps/files_external/lib/google.php ++++ b/apps/files_external/lib/google.php +@@ -37,10 +37,6 @@ use GuzzleHttp\Exception\RequestException; + use Icewind\Streams\IteratorDirectory; + use Icewind\Streams\RetryWrapper; + +-set_include_path(get_include_path().PATH_SEPARATOR. +- \OC_App::getAppPath('files_external').'/3rdparty/google-api-php-client/src'); +-require_once 'Google/Client.php'; +-require_once 'Google/Service/Drive.php'; + + class Google extends \OC\Files\Storage\Common { + +@@ -445,7 +441,6 @@ class Google extends \OC\Files\Storage\Common { + $response = $client->get($downloadUrl, [ + 'headers' => $httpRequest->getRequestHeaders(), + 'stream' => true, +- 'verify' => __DIR__ . '/../3rdparty/google-api-php-client/src/Google/IO/cacerts.pem', + ]); + } catch (RequestException $e) { + if(!is_null($e->getResponse())) { diff --git a/owncloud-9.0.2-default_integrity_check_disabled.patch b/owncloud-9.0.2-default_integrity_check_disabled.patch new file mode 100644 index 0000000..5f48dfc --- /dev/null +++ b/owncloud-9.0.2-default_integrity_check_disabled.patch @@ -0,0 +1,13 @@ +diff --git a/lib/private/integritycheck/checker.php b/lib/private/integritycheck/checker.php +index b991f66..e2111b7 100644 +--- a/lib/private/integritycheck/checker.php ++++ b/lib/private/integritycheck/checker.php +@@ -107,7 +107,7 @@ class Checker { + * applicable for very specific scenarios and we should not advertise it + * too prominent. So please do not add it to config.sample.php. + */ +- $isIntegrityCheckDisabled = $this->config->getSystemValue('integrity.check.disabled', false); ++ $isIntegrityCheckDisabled = $this->config->getSystemValue('integrity.check.disabled', true); + if($isIntegrityCheckDisabled === true) { + return false; + } diff --git a/owncloud-9.0.2-no_need_for_broken_updater_repair.patch b/owncloud-9.0.2-no_need_for_broken_updater_repair.patch new file mode 100644 index 0000000..9661d1c --- /dev/null +++ b/owncloud-9.0.2-no_need_for_broken_updater_repair.patch @@ -0,0 +1,12 @@ +diff --git a/lib/private/repair.php b/lib/private/repair.php +index 63b569b..d8e213a 100644 +--- a/lib/private/repair.php ++++ b/lib/private/repair.php +@@ -115,7 +115,6 @@ class Repair extends BasicEmitter { + new RemoveGetETagEntries(\OC::$server->getDatabaseConnection()), + new UpdateOutdatedOcsIds(\OC::$server->getConfig()), + new RepairInvalidShares(\OC::$server->getConfig(), \OC::$server->getDatabaseConnection()), +- new BrokenUpdaterRepair(), + ]; + } + diff --git a/owncloud-conf-nginx.conf b/owncloud-conf-nginx.conf new file mode 100644 index 0000000..bd0c0e8 --- /dev/null +++ b/owncloud-conf-nginx.conf @@ -0,0 +1,4 @@ +upstream php-owncloud { + server unix:/run/php-fpm/owncloud.sock; +} + diff --git a/owncloud-default-nginx.conf b/owncloud-default-nginx.conf new file mode 100644 index 0000000..81459b9 --- /dev/null +++ b/owncloud-default-nginx.conf @@ -0,0 +1,78 @@ + rewrite ^/owncloud$ /owncloud/ redirect; + + location /owncloud/ { + root /usr/share/; + + # Add headers to serve security related headers + # Before enabling Strict-Transport-Security headers please read into this topic first. + # add_header Strict-Transport-Security "max-age=15768000; includeSubDomains; preload;"; + add_header X-Content-Type-Options nosniff; + add_header X-Frame-Options "SAMEORIGIN"; + add_header X-XSS-Protection "1; mode=block"; + add_header X-Robots-Tag none; + + # set max upload size + client_max_body_size 10G; + fastcgi_buffers 64 4K; + + # Disable gzip to avoid the removal of the ETag header + gzip off; + + # Uncomment if your server is build with the ngx_pagespeed module + # This module is currently not supported. + #pagespeed off; + + index index.php; + + error_page 403 /owncloud/core/templates/403.php; + error_page 404 /owncloud/core/templates/404.php; + + location ~ ^/owncloud/apps-appstore/(.*)$ { + alias /var/lib/owncloud/apps/$1; + } + + location ~ ^/owncloud/assets/(.*)$ { + alias /var/lib/owncloud/assets/$1; + } + + location ~ ^/owncloud/(build|tests|config|lib|3rdparty|templates|data)/ { + deny all; + } + + location ~ ^/owncloud/(?:\.|autotest|occ|issue|indie|db_|console) { + deny all; + } + + rewrite ^/owncloud/remote/(.*) /owncloud/remote.php last; + rewrite ^/owncloud/core/doc/([^\/]+)(?:$|/) /owncloud/core/doc/$1/index.html; + + try_files $uri $uri/ =404; + + location ~ \.php(?:$|/) { + fastcgi_split_path_info ^(.+\.php)(/.+)$; + include fastcgi_params; + fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; + fastcgi_param PATH_INFO $fastcgi_path_info; + # fastcgi_param HTTPS on; + fastcgi_param modHeadersAvailable true; #Avoid sending the security headers twice + fastcgi_pass php-owncloud; + fastcgi_intercept_errors on; + } + + # Adding the cache control header for js and css files + # Make sure it is BELOW the location ~ \.php(?:$|/) { block + location ~* \.(?:css|js)$ { + add_header Cache-Control "public, max-age=7200"; + # Optional: Don't log access to assets + access_log off; + } + + # Optional: Don't log access to other assets + location ~* \.(?:jpg|jpeg|gif|bmp|ico|png|swf)$ { + access_log off; + } + + } + + + diff --git a/owncloud-delete-nonfree.sh b/owncloud-delete-nonfree.sh deleted file mode 100755 index fe6c53c..0000000 --- a/owncloud-delete-nonfree.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash -e - -SUFFIX=".tar.bz2" -ORIG_SOURCE=$1 -REPACK_SOURCE="$(basename $ORIG_SOURCE $SUFFIX)-repack${SUFFIX}" - -[ -d owncloud ] && rm -rf owncloud - -tar -xf $1 - -# delete jslint -pushd owncloud/apps/files_texteditor/js/vendor/ace/src-noconflict/ -sed -i '/^ \* JSHint, by JSHint Community\.$/,/^})()$/d' worker-javascript.js -popd - -# delete minify entirely as it's a mess that contains at least one instance -# of JSMin, which is under the same problematic license as jslint -rm -rf owncloud/3rdparty/mrclay/minify - -tar -cjf $REPACK_SOURCE owncloud -rm -rf owncloud diff --git a/owncloud-el7-php-fpm.conf b/owncloud-el7-php-fpm.conf new file mode 100644 index 0000000..83857bf --- /dev/null +++ b/owncloud-el7-php-fpm.conf @@ -0,0 +1,24 @@ +[owncloud] +user = apache +group = apache +listen = /run/php-fpm/owncloud.sock +listen.allowed_clients = 127.0.0.1 +pm = dynamic +pm.max_children = 50 +pm.start_servers = 5 +pm.min_spare_servers = 5 +pm.max_spare_servers = 35 +slowlog = /var/log/php-fpm/owncloud-slow.log +php_admin_value[error_log] = /var/log/php-fpm/owncloud-error.log +php_admin_flag[log_errors] = on +php_value[session.save_handler] = files +php_value[session.save_path] = /var/lib/php/session +php_value[soap.wsdl_cache_dir] = /var/lib/php/wsdlcache +php_value[upload_max_filesize] = 10G +php_value[post_max_size] = 10G +env[HOSTNAME] = $HOSTNAME +env[PATH] = /usr/local/bin:/usr/bin:/bin +env[TMP] = /tmp +env[TMPDIR] = /tmp +env[TEMP] = /tmp + diff --git a/owncloud-nginx.conf b/owncloud-nginx.conf deleted file mode 100644 index 3bd235b..0000000 --- a/owncloud-nginx.conf +++ /dev/null @@ -1,79 +0,0 @@ -# server { -# listen 80; -# server_name cloud.example.com; -# return 301 https://$server_name$request_uri; # enforce https -# } - -server { -# listen 443 ssl; - listen 80; - server_name localhost; - - allow 127.0.0.1; - deny all; - -# ssl_certificate /etc/ssl/nginx/cloud.example.com.crt; -# ssl_certificate_key /etc/ssl/nginx/cloud.example.com.key; - - # Path to the root of your installation - root /usr/share/owncloud/; - - client_max_body_size 10G; # set max upload size - fastcgi_buffers 64 4K; - - rewrite ^/caldav(.*)$ /remote.php/caldav$1 redirect; - rewrite ^/carddav(.*)$ /remote.php/carddav$1 redirect; - rewrite ^/webdav(.*)$ /remote.php/webdav$1 redirect; - - index index.php; - error_page 403 /core/templates/403.php; - error_page 404 /core/templates/404.php; - - location = /robots.txt { - allow all; - log_not_found off; - access_log off; - } - - location ~ ^/apps-appstore/(.*)$ { - alias /var/lib/owncloud/apps/$1; - } - - location ~ ^/assets/(.*)$ { - alias /var/lib/owncloud/assets/$1; - } - - location ~ ^/(data|config|\.ht|db_structure\.xml|README) { - deny all; - } - - location / { - # The following 2 rules are only needed with webfinger - rewrite ^/.well-known/host-meta /public.php?service=host-meta last; - rewrite ^/.well-known/host-meta.json /public.php?service=host-meta-json last; - - rewrite ^/.well-known/carddav /remote.php/carddav/ redirect; - rewrite ^/.well-known/caldav /remote.php/caldav/ redirect; - - rewrite ^(/core/doc/[^\/]+/)$ $1/index.html; - - try_files $uri $uri/ index.php; - } - - location ~ ^(.+?\.php)(/.*)?$ { - fastcgi_split_path_info ^(.+\.php)(/.+)$; - include fastcgi_params; - fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; - fastcgi_param PATH_INFO $fastcgi_path_info; -# fastcgi_param HTTPS on; - fastcgi_pass php-fpm; - } - - # Optional: set long EXPIRES header on static assets - location ~* ^.+\.(jpg|jpeg|gif|bmp|ico|png|css|js|swf)$ { - expires 30d; - # Optional: Don't log access to assets - access_log off; - } - -} diff --git a/owncloud-php-fpm.conf b/owncloud-php-fpm.conf new file mode 100644 index 0000000..7a79c1b --- /dev/null +++ b/owncloud-php-fpm.conf @@ -0,0 +1,25 @@ +[owncloud] +user = apache +group = apache +listen = /run/php-fpm/owncloud.sock +listen.acl_users = apache,nginx +listen.allowed_clients = 127.0.0.1 +pm = dynamic +pm.max_children = 50 +pm.start_servers = 5 +pm.min_spare_servers = 5 +pm.max_spare_servers = 35 +slowlog = /var/log/php-fpm/owncloud-slow.log +php_admin_value[error_log] = /var/log/php-fpm/owncloud-error.log +php_admin_flag[log_errors] = on +php_value[session.save_handler] = files +php_value[session.save_path] = /var/lib/php/session +php_value[soap.wsdl_cache_dir] = /var/lib/php/wsdlcache +php_value[upload_max_filesize] = 10G +php_value[post_max_size] = 10G +env[HOSTNAME] = $HOSTNAME +env[PATH] = /usr/local/bin:/usr/bin:/bin +env[TMP] = /tmp +env[TMPDIR] = /tmp +env[TEMP] = /tmp + diff --git a/owncloud.spec b/owncloud.spec index b208249..ee56bd6 100644 --- a/owncloud.spec +++ b/owncloud.spec @@ -8,7 +8,7 @@ # Please preserve changelog entries # Name: owncloud -Version: 8.2.5 +Version: 9.0.2 Release: 1%{?dist} Summary: Private file sync and share server Group: Applications/Internet @@ -16,19 +16,16 @@ Group: Applications/Internet License: AGPLv3+ and MIT and BSD and CC-BY and CC-BY-SA and GPLv3 and Public Domain and (MPLv1.1 or GPLv2+ or LGPLv2+) and (MIT or GPL+) and (MIT or GPLv2) and ASL 2.0 and LGPLv3 URL: http://owncloud.org -# Tarball with non-free sources stripped. To generate: -# ./owncloud-delete-nonfree.sh %%{name}-%%{version}.tar.bz2 -Source0: %{name}-%{version}-repack.tar.bz2 -# orig source: https://download.owncloud.org/community/%%{name}-%%{version}.tar.bz2 -# sha256sum: https://download.owncloud.org/community/%%{name}-%%{version}.tar.bz2.sha256 - -# used to repack the source tarball -Source42: %{name}-delete-nonfree.sh - +Source0: https://download.owncloud.org/community/%{name}-%{version}.tar.bz2 Source1: %{name}-httpd.conf Source2: %{name}-access-httpd.conf.avail -Source6: %{name}-nginx.conf + +Source200: %{name}-default-nginx.conf +Source201: %{name}-conf-nginx.conf +Source202: %{name}-php-fpm.conf +Source203: %{name}-el7-php-fpm.conf + # Config snippets Source100: %{name}-auth-any.inc Source101: %{name}-auth-local.inc @@ -45,20 +42,15 @@ Source7: %{name}-config.php # Our autoloader for core Source8: %{name}-fedora-autoloader.php -# Adjust mediaelement not to use its SWF and Silverlight plugins. This -# changes 'plugins:["flash,"silverlight","youtube","vimeo"]' to -# 'plugins:["youtube","vimeo"]' -Patch1: %{name}-8.2.5-videoviewer_noplugins.patch - # Stop OC from trying to do stuff to .htaccess files. Just calm down, OC. # Distributors are on the case. -Patch2: %{name}-8.2.2-dont_update_htacess.patch +Patch2: %{name}-9.0.1-dont_update_htacess.patch # Remove explicit load of dropbox -Patch3: %{name}-8.2.3-dropbox-autoloader.patch +Patch3: %{name}-9.0.1-dropbox-autoloader.patch # Remove explicit load of google -Patch4: %{name}-8.2.3-google-autoloader.patch +Patch4: %{name}-9.0.1-google-autoloader.patch # Remove explicit load of aws Patch5: %{name}-8.2.3-amazon-autoloader.patch @@ -66,9 +58,17 @@ Patch5: %{name}-8.2.3-amazon-autoloader.patch # Display the appropriate upgrade command for fedora/epel users bz#1321417 Patch6: %{name}-8.2.3-correct-cli-upgrade-command.patch -# Backport commit ca6bd5c and cfdf2b9 since icewind/streams added function in 0.3.0+ -# breaking interface from 0.2.0 and OC method spamming logs -Patch7: %{name}-8.2.3-icewind-streams-encryption.patch +# The broken updater repair step gets upset we unbundle +Patch7: %{name}-9.0.2-no_need_for_broken_updater_repair.patch + +# Disable the integrity checking whilst a better way to deal with it is found +Patch8: %{name}-9.0.2-default_integrity_check_disabled.patch + +# Need to work around an NSS issue in el7.2, due to be fix el7.3 bz#1241172 +Patch9: %{name}-8.1.6-work-arround-nss-issue.patch + +# RH provide support for php54 so don't tell users it's EOL +Patch10: %{name}-8.2.3-dont_warn_php54_eol.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildArch: noarch @@ -79,39 +79,40 @@ BuildRequires: php-pear # For sanity check BuildRequires: php-cli -BuildRequires: php-composer(sabre/dav) >= 2.1.9 -BuildRequires: php-composer(sabre/dav) < 2.2 -BuildRequires: php-composer(doctrine/dbal) >= 2.5.1 +BuildRequires: php-composer(sabre/dav) >= 3.0.8 +BuildRequires: php-composer(sabre/dav) < 4.0 +BuildRequires: php-composer(doctrine/dbal) >= 2.5.2 BuildRequires: php-composer(doctrine/dbal) < 2.6 -BuildRequires: php-composer(mcnetic/zipstreamer) >= 0.7 +BuildRequires: php-composer(mcnetic/zipstreamer) >= 1.0 +BuildRequires: php-composer(mcnetic/zipstreamer) < 2.0 BuildRequires: php-composer(phpseclib/phpseclib) >= 2.0 BuildRequires: php-composer(phpseclib/phpseclib) < 3.0 BuildRequires: php-opencloud >= 1.9.2 BuildRequires: php-composer(james-heinrich/getid3) >= 1.9.12 -BuildRequires: php-composer(jeremeamia/superclosure) >= 2.0 +BuildRequires: php-composer(jeremeamia/superclosure) >= 2.1.0 BuildRequires: php-composer(ircmaxell/random-lib) >= 1.1 BuildRequires: php-composer(ircmaxell/random-lib) < 2.0 BuildRequires: php-composer(bantu/ini-get-wrapper) >= 1.0.1 BuildRequires: php-composer(natxet/CssMin) >= 3.0.4 -BuildRequires: php-composer(punic/punic) >= 1.1.0 -BuildRequires: php-composer(pear/archive_tar) >= 1.4 +BuildRequires: php-composer(punic/punic) >= 1.6.3 +BuildRequires: php-composer(pear/archive_tar) >= 1.4.1 BuildRequires: php-composer(pear/archive_tar) < 2.0 -BuildRequires: php-composer(patchwork/utf8) >= 1.1 +BuildRequires: php-composer(patchwork/utf8) >= 1.2.6 BuildRequires: php-composer(patchwork/utf8) < 2.0 -BuildRequires: php-composer(symfony/console) >= 2.6.4 -BuildRequires: php-composer(symfony/event-dispatcher) >= 2.6.4 -BuildRequires: php-composer(symfony/routing) >= 2.6.4 -BuildRequires: php-composer(symfony/process) >= 2.6.4 -BuildRequires: php-composer(pimple/pimple) >= 3.0 +BuildRequires: php-composer(symfony/console) >= 2.8.1 +BuildRequires: php-composer(symfony/event-dispatcher) >= 2.8.1 +BuildRequires: php-composer(symfony/routing) >= 2.8.1 +BuildRequires: php-composer(symfony/process) >= 2.8.1 +BuildRequires: php-composer(pimple/pimple) >= 3.0.2 BuildRequires: php-composer(pimple/pimple) < 4.0 BuildRequires: php-composer(ircmaxell/password-compat) >= 1.0.0 -BuildRequires: php-composer(nikic/php-parser) >= 1.0 +BuildRequires: php-composer(nikic/php-parser) >= 1.4.1 BuildRequires: php-composer(nikic/php-parser) < 2.0 -BuildRequires: php-composer(icewind/streams) >= 0.2 +BuildRequires: php-composer(icewind/streams) >= 0.4.0 BuildRequires: php-composer(swiftmailer/swiftmailer) >= 5.4.1 -BuildRequires: php-composer(guzzlehttp/guzzle) >= 5.0 +BuildRequires: php-composer(guzzlehttp/guzzle) >= 5.3.0 BuildRequires: php-composer(guzzlehttp/guzzle) < 6.0 -BuildRequires: php-composer(league/flysystem) >= 1.0.4 +BuildRequires: php-composer(league/flysystem) >= 1.0.16 BuildRequires: php-composer(interfasys/lognormalizer) >= 1.0 BuildRequires: php-composer(owncloud/tarstreamer) >= 0.1 BuildRequires: php-composer(patchwork/jsqueeze) >= 2.0 @@ -127,6 +128,12 @@ BuildRequires: php-aws-sdk >= 2.7.0 BuildRequires: php-composer(symfony/yaml) >= 2.6.0 BuildRequires: php-composer(symfony/yaml) < 3.0.0 BuildRequires: php-pear(pear.dropbox-php.com/Dropbox) +BuildRequires: php-composer(symfony/polyfill-php70) >= 1.0 +BuildRequires: php-composer(symfony/polyfill-php70) < 2.0 +BuildRequires: php-composer(symfony/polyfill-php55) >= 1.0 +BuildRequires: php-composer(symfony/polyfill-php55) < 2.0 +BuildRequires: php-composer(symfony/polyfill-php56) >= 1.0 +BuildRequires: php-composer(symfony/polyfill-php56) < 2.0 Requires: %{name}-webserver = %{version}-%{release} @@ -150,29 +157,22 @@ Requires: php-simplexml Requires: php-xmlwriter Requires: php-spl Requires: php-zip -%if 0%{?fedora} || 0%{?rhel} > 6 Requires: php-filter -%endif ### External PHP libs required by OC core -# Ordering requires to match composer.json - -# "sabre/dav" : "2.1.9" -# pulls in sabre event, http and vobject as strict requires -Requires: php-composer(sabre/dav) >= 2.1.9 -Requires: php-composer(sabre/dav) < 2.2 -# "doctrine/dbal": "2.5.1" +# "doctrine/dbal": "2.5.2" # pulls in doctrine/common as a strict requires # which pulls in doctrine/{annotations,inflector,cache,collections,lexer} as strict requires -Requires: php-composer(doctrine/dbal) >= 2.5.1 +Requires: php-composer(doctrine/dbal) >= 2.5.2 Requires: php-composer(doctrine/dbal) < 2.6 -#"mcnetic/zipstreamer": "v0.7" -Requires: php-composer(mcnetic/zipstreamer) >= 0.7 +#"mcnetic/zipstreamer": "^1.0" +Requires: php-composer(mcnetic/zipstreamer) >= 1.0 +Requires: php-composer(mcnetic/zipstreamer) < 2.0 -# "phpseclib/phpseclib": "~2.0@dev" +# "phpseclib/phpseclib": "2.0.0" Requires: php-composer(phpseclib/phpseclib) >= 2.0 Requires: php-composer(phpseclib/phpseclib) < 3.0 @@ -184,8 +184,8 @@ Requires: php-opencloud >= 1.9.2 #"james-heinrich/getid3": "dev-master" Requires: php-composer(james-heinrich/getid3) >= 1.9.12 -# "jeremeamia/superclosure": "2.0.0" -Requires: php-composer(jeremeamia/superclosure) >= 2.0 +# "jeremeamia/superclosure": "2.1.0" +Requires: php-composer(jeremeamia/superclosure) >= 2.1.0 # "ircmaxell/random-lib": "~1.1" # Also pulls in ircmaxell/security-lib which is a strict requires @@ -198,62 +198,63 @@ Requires: php-composer(bantu/ini-get-wrapper) >= 1.0.1 # "natxet/CssMin": "dev-master" Requires: php-composer(natxet/CssMin) >= 3.0.4 -# "punic/punic": "1.1.0" -Requires: php-composer(punic/punic) >= 1.1.0 +# "punic/punic": "1.6.3" +Requires: php-composer(punic/punic) >= 1.6.3 -# "pear/archive_tar": "~1.4" -Requires: php-composer(pear/archive_tar) >= 1.4 +# "pear/archive_tar": "1.4.1" +Requires: php-composer(pear/archive_tar) >= 1.4.1 Requires: php-composer(pear/archive_tar) < 2.0 -# "patchwork/utf8": "~1.1" -Requires: php-composer(patchwork/utf8) >= 1.1 +# "patchwork/utf8": "1.2.6" +Requires: php-composer(patchwork/utf8) >= 1.2.6 Requires: php-composer(patchwork/utf8) < 2.0 -# "symfony/console": "2.6.4" -Requires: php-composer(symfony/console) >= 2.6.4 -# "symfony/event-dispatcher": "2.6.4" -Requires: php-composer(symfony/event-dispatcher) >= 2.6.4 -# "symfony/routing": "2.6.4" -Requires: php-composer(symfony/routing) >= 2.6.4 -# "symfony/process": "2.6.4" -Requires: php-composer(symfony/process) >= 2.6.4 - -# "pimple/pimple": "~3.0" -Requires: php-composer(pimple/pimple) >= 3.0 +# "symfony/console": "2.8.1" +Requires: php-composer(symfony/console) >= 2.8.1 +# "symfony/event-dispatcher": "2.8.1" +Requires: php-composer(symfony/event-dispatcher) >= 2.8.1 +# "symfony/routing": "2.8.1" +Requires: php-composer(symfony/routing) >= 2.8.1 +# "symfony/process": "2.8.1" +Requires: php-composer(symfony/process) >= 2.8.1 + +# "pimple/pimple": "3.0.2" +Requires: php-composer(pimple/pimple) >= 3.0.2 Requires: php-composer(pimple/pimple) < 4.0 # "ircmaxell/password-compat": "1.0.*" Requires: php-composer(ircmaxell/password-compat) >= 1.0.0 -# "nikic/php-parser": "~1.1" -Requires: php-composer(nikic/php-parser) >= 1.0 +# "nikic/php-parser": "1.4.1" +Requires: php-composer(nikic/php-parser) >= 1.4.1 Requires: php-composer(nikic/php-parser) < 2.0 -# "icewind/Streams": "0.2.0" -Requires: php-composer(icewind/streams) >= 0.2 +# "icewind/Streams": "0.4.0" +Requires: php-composer(icewind/streams) >= 0.4.0 # "swiftmailer/swiftmailer": "@stable" # Version 5.4.1 for autoloader in /usr/share/php Requires: php-composer(swiftmailer/swiftmailer) >= 5.4.1 -# "guzzlehttp/guzzle": "~5.0" +# "guzzlehttp/guzzle": "5.3.0" # pulls in guzzlehttp/ringphp as strict requires # ringphp pulls in guzzlehttp/streams and react/promise as strict requires -Requires: php-composer(guzzlehttp/guzzle) >= 5.0 +Requires: php-composer(guzzlehttp/guzzle) >= 5.3.0 Requires: php-composer(guzzlehttp/guzzle) < 6.0 -# "league/flysystem": "1.0.4" -Requires: php-composer(league/flysystem) >= 1.0.4 +# "league/flysystem": "1.0.16" +Requires: php-composer(league/flysystem) >= 1.0.16 -# "pear/pear-core-minimal": "v1.10.0alpha2" + +# "pear/pear-core-minimal": "v1.10.1" # this includes pear/console_getopt and pear/PEAR # which is not listed in composer.json unlike archive_tar -Requires: php-composer(pear/pear-core-minimal) > 1.10 +Requires: php-composer(pear/pear-core-minimal) >= 1.10.1 -# "interfasys/lognormalizer": "dev-master@dev" +# "interfasys/lognormalizer": "v1.0" Requires: php-composer(interfasys/lognormalizer) >= 1.0 -# "deepdiver1975/TarStreamer": "v0.1-beta3" +# "deepdiver1975/TarStreamer": "v0.1.0" # Despite the difference in name this is correct # https://github.com/owncloud/3rdparty/tree/master/deepdiver1975/tarstreamer Requires: php-composer(owncloud/tarstreamer) >= 0.1 @@ -262,20 +263,38 @@ Requires: php-composer(owncloud/tarstreamer) >= 0.1 Requires: php-composer(patchwork/jsqueeze) >= 2.0 Requires: php-composer(patchwork/jsqueeze) < 3.0 -# "kriswallsmith/assetic": "^1.3" -Requires: php-composer(kriswallsmith/assetic) >= 1.3 +# "kriswallsmith/assetic": "1.3.2" +# Need release 3 for the autoloader fix to avoid it spamming the logs +Requires: php-composer(kriswallsmith/assetic) >= 1.3.2-3 Requires: php-composer(kriswallsmith/assetic) < 2.0 - +# "sabre/dav" : "3.0.8" +# pulls in sabre event, http and vobject, xml, uri as strict requires +Requires: php-composer(sabre/dav) >= 3.0.8 +Requires: php-composer(sabre/dav) < 4.0 + +# symfony/polyfill-mbstring is not in composer.json but is in the 3rdparty folder +# we don't need it though as we ship mbstring itself + +# "symfony/polyfill-php70": "^1.0", +# pulls in s strict requires of paragonie/random_compat +Requires: php-composer(symfony/polyfill-php70) >= 1.0 +Requires: php-composer(symfony/polyfill-php70) < 2.0 +# "symfony/polyfill-php55": "^1.0", +Requires: php-composer(symfony/polyfill-php55) >= 1.0 +Requires: php-composer(symfony/polyfill-php55) < 2.0 +# "symfony/polyfill-php56": "^1.0" +Requires: php-composer(symfony/polyfill-php56) >= 1.0 +Requires: php-composer(symfony/polyfill-php56) < 2.0 ### For dependencies of apps/files_external ## SMB/CIFS external storage stuff -#"icewind/smb": "1.0.4" +#"icewind/smb": "1.0.8" # note that streams is a dep but already required by core anyway -Requires: php-composer(icewind/smb) >= 1.0.4 -# This makes smb external storage usable iin performance +Requires: php-composer(icewind/smb) >= 1.0.8 +# This makes smb external storage usable in performance # and doesn't break things like encryption due to timeouts %if 0%{?rhel} != 5 Requires: php-pecl(smbclient) >= 0.8.0 @@ -403,13 +422,17 @@ work with an SQLite 3 database stored on the local system. %prep %setup -q -n %{name} -%patch1 -p1 %patch2 -p1 %patch3 -p1 %patch4 -p1 %patch5 -p1 %patch6 -p1 %patch7 -p1 +%patch8 -p1 +%if 0%{?rhel} +%patch9 -p1 +%patch10 -p1 +%endif # prepare package doc cp %{SOURCE3} README.fedora @@ -419,7 +442,6 @@ cp %{SOURCE5} README.postgresql # Explicitly remove the bundled libraries we're aware of pushd 3rdparty -rm -r sabre/{dav,event,http,vobject} rm -r doctrine/{annotations,cache,collections,common,dbal,inflector,lexer} rm -r mcnetic/zipstreamer rm -r phpseclib/phpseclib @@ -448,6 +470,10 @@ rm -r interfasys/lognormalizer rm -r deepdiver1975/tarstreamer rm -r patchwork/jsqueeze rm -r kriswallsmith/assetic +rm -r sabre/{dav,event,http,vobject,uri,xml} +rm -r symfony/polyfill-{php55,php56,php70,mbstring,util} +rm -r paragonie/random_compat +rm README.md # remove composer stuff rm -r composer* @@ -498,19 +524,9 @@ for f in {l10n.pl,init.sh,setup_owncloud.sh,image-optimization.sh,install_depend done find . -size 0 -type f -exec rm {} \; -# Drop pre-compiled binary lumps: Flash and Silverlight -# This means that Flash/Silverlight video/audio fallbacks in the -# 'media' and 'videoviewer' apps are not available. -# To re-introduce these they would have to be built from the -# source as part of this package build, they cannot be shipped -# pre-compiled. - AdamW, 2013/08 -# https://fedoraproject.org/wiki/Packaging:Guidelines#No_inclusion_of_pre-built_binaries_or_libraries -rm apps/files_videoviewer/js/flashmediaelement.swf -rm apps/files_videoviewer/js/silverlightmediaelement.xap - -# let's not ship upstream's 'updater' app, which has zero chance of working and +# let's not ship upstream's 'updatenotification' app, which has zero chance of working and # a big chance of blowing things up -rm -r apps/updater +rm -r apps/updatenotification %check @@ -521,8 +537,8 @@ if [ $nb -gt 1 ]; then fi if grep -r 3rdparty %{buildroot}%{_datadir}/%{name}/apps/files_external \ - | grep -v 3rdparty/autoload.php; then - false Patch needs to be adapted + | grep -v 3rdparty/autoload.php | grep -v signature.json; then + false App files_external needs to be adapted fi php %{buildroot}%{_datadir}/%{name}/apps/files_external/3rdparty/autoload.php @@ -543,7 +559,6 @@ fi php %{buildroot}%{_datadir}/%{name}/3rdparty/autoload.php - %build # Nothing to build @@ -587,11 +602,20 @@ install -Dpm 644 %{SOURCE100} %{SOURCE101} %{SOURCE102} %{SOURCE103} \ %{buildroot}%{_sysconfdir}/httpd/conf.d/ # nginx config -install -Dpm 644 %{SOURCE6} \ +install -Dpm 644 %{SOURCE200} \ + %{buildroot}%{_sysconfdir}/nginx/default.d/%{name}.conf +install -Dpm 644 %{SOURCE201} \ %{buildroot}%{_sysconfdir}/nginx/conf.d/%{name}.conf +%if 0%{?rhel} +install -Dpm 644 %{SOURCE203} \ + %{buildroot}%{_sysconfdir}/php-fpm.d/%{name}.conf +%else +install -Dpm 644 %{SOURCE202} \ + %{buildroot}%{_sysconfdir}/php-fpm.d/%{name}.conf +%endif -%if 0%{?rhel} < 7 +%if 0%{?fedora} < 21 && 0%{?rhel} < 7 %post semanage fcontext -a -t httpd_sys_rw_content_t '%{_sysconfdir}/%{name}/config.php' 2>/dev/null || : semanage fcontext -a -t httpd_sys_rw_content_t '%{_sysconfdir}/%{name}' 2>/dev/null || : @@ -625,6 +649,14 @@ if [ $1 -eq 0 ]; then fi %post nginx +%if 0%{?rhel} + # Work around missing php session directory for php-fpm in el7 bz#1338444 + if [ ! -d /var/lib/php/session ] + then + mkdir /var/lib/php/session + fi + /usr/bin/chown apache /var/lib/php/session +%endif %if 0%{?fedora} || 0%{?rhel} > 6 /usr/bin/systemctl reload nginx.service > /dev/null 2>&1 || : /usr/bin/systemctl reload php-fpm.service > /dev/null 2>&1 || : @@ -674,7 +706,9 @@ rm -rf %{buildroot} %files nginx %defattr(-,root,root,-) +%config(noreplace) %{_sysconfdir}/nginx/default.d/%{name}.conf %config(noreplace) %{_sysconfdir}/nginx/conf.d/%{name}.conf +%config(noreplace) %{_sysconfdir}/php-fpm.d/%{name}.conf %files mysql %defattr(-,root,root,-) @@ -689,8 +723,16 @@ rm -rf %{buildroot} %changelog -* Thu May 12 2016 Remi Collet - 8.2.5-1 -- Update to 8.2.5 +* Fri May 06 2016 James Hogarth - 9.0.2-1 +- Update to 9.0.2 +- Need a better way to deal with the integrity checking stuff from upstream + +* Thu May 05 2016 James Hogarth - 9.0.1-1 +- Remove el6 conditionals as it's no longer a supported platform +- Change nginx configuration as per bz#1332900 +- Add php-fpm owncloud dedicated pool +- No longer ships non-free jshint in aceeditor so don't need repack +- Update to 9.0.1 * Thu May 5 2016 Remi Collet - 8.2.4-1 - Update to 8.2.4 -- cgit