Commit Graph

5336 Commits

Author SHA1 Message Date
Robin Appelman a98b038300 Query the cache when checking if a node exists 2016-03-21 13:53:33 +01:00
Thomas Müller 16782484b9 Merge pull request #23349 from owncloud/hardenings
Hardenings
2016-03-21 09:45:05 +01:00
Lukas Reschke e867a7d54d Write .htaccess update only if not already written
The ownCloud update routine also runs the "updateHtaccess" code in case only an application gets updated. This leads to having entries multiple time in the .htaccess file leading to unpredictable behaviour.

With 9.0 we added the "#### DO NOT CHANGE ANYTHING ABOVE THIS LINE ####" entry to the .htaccess file, this change uses it to ensure that only to the .htaccess gets written if the file has not been modified already. Since the .htaccess modifications are optional this is not a big deal.

Without this change updates of applications can break the rewrite rules (ending in endless redirects) as well as breaking the code integrity checker.
2016-03-17 17:59:28 +01:00
Lukas Reschke bf017f5c11 Remove unused code
This code is not used anymore.
2016-03-17 13:09:23 +01:00
Lukas Reschke 979a3ff830 Escape App ID
While all callers do this as well this prevents a misuse of the API by mistake.
2016-03-17 13:09:22 +01:00
Manish Bisht 07e7d4836e Update oci.php
Error Fixed

combined the database errors

Merged Database Errors
2016-03-16 19:21:14 +01:00
Thomas Müller 2f5b929ee9 Merge pull request #23108 from owncloud/set-encrypted-version-at-least-to-1
Ensure that stored version is at least 1 for cross-storage copy
2016-03-16 13:14:36 +01:00
Thomas Müller 5f00724e5b Merge pull request #23189 from owncloud/require-at-least-libxml-2-7-0
Require at least libxml 2.7.0
2016-03-16 13:11:59 +01:00
Lukas Reschke 676041ba7e Ensure that stored version is at least 1 for cross-storage copy
In case of a move operation from an unencrypted to an encrypted
storage the old encrypted version would stay with "0" while the
correct value would be "1". Thus we manually set the value to "1"
for those cases.

See also https://github.com/owncloud/core/issues/23078
2016-03-16 10:36:15 +01:00
Thomas Müller f7140294f2 Merge pull request #23157 from owncloud/remove-share-prop-entries
remove old share propagation entries from appconfig
2016-03-15 16:04:17 +01:00
Thomas Müller 27760ae54e Merge pull request #23164 from owncloud/db-connection-precondition-fix
Prevent certain DBs throwing exceptions on same-value updates
2016-03-15 16:03:55 +01:00
Thomas Müller 7b06dd485d Merge pull request #23250 from owncloud/fix-support-for-php7-in-htaccess
Fix several .htaccess and .user.ini related problems
2016-03-15 16:03:18 +01:00
Robin McCorkell 1b2f1cc272 Prevent certain DBs throwing exceptions on same-value updates
A PreconditionNotMetException must only be thrown if explicit
preconditions are specified for setValues(), not if the value is merely
the same as was already in the DB.
2016-03-15 13:02:19 +01:00
Thomas Müller ad9a0804f3 Merge pull request #23226 from owncloud/fix_23190
Generate a valid URL for link notification
2016-03-15 12:55:13 +01:00
Robin Appelman 0aa83511a1 remove old share propagation entries from appconfig 2016-03-15 12:50:22 +01:00
Thomas Müller 0f6ea9fd29 Merge pull request #23039 from owncloud/invalid-share-storage
dont break when there is an invalid share
2016-03-15 12:15:05 +01:00
Thomas Müller e9eeb3607f Merge pull request #23074 from owncloud/issue-22835-correctly-use-querybuilder-api
Correctly escape join statements and use selectAlias
2016-03-15 12:14:17 +01:00
Roeland Jago Douma 1db82073a4 Generate a valid URL for link notification
fixes #23197

* Updated unit test
2016-03-15 11:10:24 +01:00
Lukas Reschke 5278bfe0e4 Add support for custom values in integrity checker 2016-03-15 10:41:17 +01:00
Lukas Reschke c7abd307c0 Replace all required values 2016-03-15 10:41:17 +01:00
Lukas Reschke 0b0077e62d Revert "Removed unnecessary check 'installed' system value' call." 2016-03-15 10:23:40 +01:00
Thomas Müller 9657f9a01b Merge pull request #23171 from maxolasersquad/master
Removed unnecessary check 'installed' system value' call.
2016-03-14 17:18:36 +01:00
Thomas Müller a058bb0d7e Merge pull request #23225 from owncloud/Phiber2000-fix_logtimezone
fix broken logtimezone
2016-03-14 17:08:48 +01:00
Thomas Müller b25077748e Merge pull request #22901 from owncloud/add-dav-authenticated
Add DAV authenticated also to other scopes
2016-03-14 16:33:09 +01:00
Thomas Müller 3661b47b6d Merge pull request #23124 from owncloud/improved-rewrite-rule
Improved rewrite rule
2016-03-14 16:13:50 +01:00
Thomas Müller f6a5fe452d Merge pull request #23190 from owncloud/use-proper-url-for-search-results
Use proper URLs for search results
2016-03-14 16:11:17 +01:00
Thomas Müller d219284961 Merge pull request #23191 from owncloud/fix-external-dav-storage
Verify the getResponse returns a ResponseInterface
2016-03-14 16:10:40 +01:00
Thomas Müller 852acd364a Merge pull request #23218 from owncloud/memcached-not-found-on-remove-means-success
Fix errors in memcached implementation
2016-03-14 16:08:47 +01:00
Phiber2000 3e7b2810e2 fix broken logtimezone 2016-03-14 15:10:47 +01:00
Joas Schilling 2f67aa9bc4 Fix errors in memcached implementation 2016-03-14 12:39:34 +01:00
Joas Schilling c3c491689b Shorter cache key for URL entries 2016-03-14 11:05:46 +01:00
Roeland Jago Douma 3f8c998afe Do not recurse link share fetching
* Might fix an issue on oracle
2016-03-13 13:31:28 +01:00
Lukas Reschke d43051f7de Verify the getResponse returns a ResponseInterface
Can also return `null` as per PHPDoc. Regression added by 97f5c095f4

Fixes https://github.com/owncloud/core/issues/23145
2016-03-12 22:45:07 +01:00
Lukas Reschke 3c06b08c92 Use proper URLs for search results
Fixes https://github.com/owncloud/core/issues/23136
2016-03-12 22:29:47 +01:00
Lukas Reschke 42a70ed482 Require at least libxml 2.7.0
Fixes https://github.com/owncloud/core/issues/23168
2016-03-12 22:13:05 +01:00
David Baucum c519447522 Removed unnecessary check 'installed' system value' call.
OC_Utils::checkServer makes an unnecessary call to $config->getSystemValue('installed', false), which replicates the call made immediately before it during the call to needUpgrade.
2016-03-11 15:59:11 -05:00
Thomas Müller a8922e9d35 Merge pull request #23125 from owncloud/add-port-support-to-trusteddomain
Explicitly check for port
2016-03-11 14:55:27 +01:00
Robin Appelman a8db587b1f move failedstorage to core 2016-03-11 13:15:45 +01:00
Roeland Jago Douma b8ce9c5554 Use more generic node instead of File/Folder
The phpdoc for the sharing functions was very restrictive. As a
consequence passing node object (for example from the OCS Share API
where we don't really care if it is a file or folder), would actually
be invalid.

With this loser restriction the interfaces become more generic.
2016-03-11 08:51:07 +01:00
Lukas Reschke dc6789fd5b Explicitly check for port
The setup uses `\OCP\IRequest::getInsecureServerHost` which in some cases can also include a port. This makes the trusted domain check fail thus.

I've decided to add this here that way because adjusting the setup would require parsing the host properly. This is not something that can be done very good in PHP. Check the following example for why `parse_url` is not our friend: https://3v4l.org/k501Z
2016-03-10 22:32:29 +01:00
Lukas Reschke 3e8decf5e9 Improved rewrite rule
As per https://github.com/owncloud/core/issues/23098 and https://github.com/owncloud/core/issues/23117
2016-03-10 22:20:02 +01:00
Thomas Müller 51072f742e Merge pull request #21582 from owncloud/core_composer
Composers PSR-4 autoloader in core
2016-03-10 12:06:44 +01:00
Joas Schilling 6b4117df34 Correctly escape join statements and use selectAlias 2016-03-10 10:24:08 +01:00
Thomas Müller 308c99f1fd Merge pull request #23029 from owncloud/add-rewrite-rules-after-setup
Add base rewrite rule only when RewriteBase is defined
2016-03-10 08:25:18 +01:00
Roeland Jago Douma d16b371e38 POC for PSR-4 autoloader server.php => Server.php 2016-03-09 16:53:39 +01:00
Lukas Reschke bc4a043a76 Add base rewrite rule only when RewriteBase is defined
In case Apache is configured with an `Alias` such as with the ownCloud packages the rewrite rules will fail when no valid RewriteBase is configured.
2016-03-09 15:13:07 +01:00
Thomas Müller 0cc53ee06d Merge pull request #22602 from owncloud/fix_slow_chunkcheck
Do not check all chunks of a chunked upload if we do not need to
2016-03-09 15:06:44 +01:00
Thomas Müller d0a70a9776 Merge pull request #23006 from owncloud/require-xml-reader
Add XMLReader as requirement
2016-03-09 15:03:50 +01:00
Roeland Jago Douma e8f22a16f6 Select queries in the default share provider should query for file/folder
There can be leftover calendar and contacts shares in the oc_share
table. We need to filter those out properly.
2016-03-09 11:19:57 +01:00
Lukas Reschke 642c38ffb2 Add XMLReader as requirement
The SabreDAV release in 9.0 requires XMLReader, while this is usually compiled in by default some distributions like Gentoo don't.

Without this ownCloud gives a fatal 500 error instead of telling people to enable XMLReader.

Fixes https://github.com/owncloud/core/issues/23003
2016-03-09 11:11:00 +01:00