Commit Graph

6131 Commits

Author SHA1 Message Date
Lukas Reschke ab4d5d20ea Typehint $targetVersion 2015-06-29 15:10:40 +02:00
Lukas Reschke b56af26199 Merge pull request #17222 from owncloud/issue-17101-send-oc-version-to-app-store
Send OC version to appstore so it can reply with the right links
2015-06-29 15:07:00 +02:00
Robin Appelman 8a2ef26b5e handle invalid results from mount providers 2015-06-29 14:42:34 +02:00
Thomas Müller f8127046ee Unit tests added for MaintenancePlugin 2015-06-29 14:18:09 +02:00
Joas Schilling 70eb20e3a7 Merge pull request #17030 from owncloud/lock-posthooks
Keep shared lock for post-hooks
2015-06-29 14:17:03 +02:00
Morris Jobke c57fb19b2f Merge pull request #17226 from owncloud/webdav-add-message-on-maintenance
In case of maintenance we should add a message to the exception
2015-06-29 14:11:36 +02:00
Robin Appelman 786ec82a61 add unit test 2015-06-29 14:06:29 +02:00
Robin Appelman 8ec7e9fac7 fix getting mount points when passing a path to the files:scan command 2015-06-29 14:03:23 +02:00
Lukas Reschke 5810e7ab87 Merge pull request #17050 from owncloud/request-status-from-ocs
Request approved state for disabled apps with ocsid
2015-06-29 13:41:11 +02:00
Thomas Müller e236e564af In case of maintenance we should add a message to the exception 2015-06-29 12:31:01 +02:00
Joas Schilling ae3d402dbc Send OC version to appstore so it can reply with the right links 2015-06-29 12:14:07 +02:00
Lukas Reschke 04fe9e05f0 Use new updater URL + add unit tests
Uses the new updater url "https://updates.owncloud.com/server/"
2015-06-28 11:25:28 +02:00
Lukas Reschke a793b98fd0 Fix indentation 2015-06-27 20:37:07 +02:00
Lukas Reschke af01958f3e Add missing annotations for parameters 2015-06-27 20:35:47 +02:00
Lukas Reschke d1f0ff372e Merge pull request #17163 from owncloud/update-licenses
Update license headers
2015-06-27 20:22:23 +02:00
Roeland Douma 708c6268ad Merge pull request #17206 from oparoz/bpg-media-type
Adding BPG media type
2015-06-27 10:19:56 +02:00
Olivier Paroz 158c5b5e47 Adding BPG media type 2015-06-26 19:22:12 +02:00
Vincent Petry 0684cc15dc Merge pull request #17071 from owncloud/share-get-users-non-existing
fix getUsersSharingFile with locking
2015-06-26 18:27:53 +02:00
Vincent Petry 271ef9dedb Remove test-specific method to make Bjoern and Joas happy 2015-06-26 17:37:04 +02:00
Robin Appelman c338999032 fix getUsersSharingFile with locking 2015-06-26 16:31:52 +02:00
Thomas Müller ac94126393 Merge pull request #17191 from owncloud/issue-17188-group-share-part-file
Correctly check if the real file exists, otherwise try the part file
2015-06-26 16:01:41 +02:00
Björn Schießle b318b9cf17 Merge pull request #17008 from owncloud/fix-17006
Improve splitting of username and remote adress when username contains an `@`
2015-06-26 16:01:16 +02:00
Joas Schilling 9b336765b6 Correctly check if the real file exists, otherwise try the part file 2015-06-26 13:17:23 +02:00
Thomas Müller 796aae4402 Merge pull request #17009 from owncloud/lock-downloadfile
Lock file during download
2015-06-26 13:04:34 +02:00
Thomas Müller 6c3a4282e5 Merge pull request #17165 from owncloud/federated_cloud_sharing_search_address_book
Search address book for federated cloud id
2015-06-26 10:53:02 +02:00
Vincent Petry 538e466c30 Keep shared locks in post hooks
Instead of unlocking after the file operation, change exclusive locks
back to shared locks during post hooks, and unlock after that.

Also added unit tests to test locking in pre-hooks, during operation and
post-hooks.
2015-06-25 16:33:02 +02:00
Morris Jobke f63915d0c8 update license headers and authors 2015-06-25 14:13:49 +02:00
Bjoern Schiessle a288d0eea3 ne need to check twice if $row['share_with'] is set 2015-06-25 12:14:46 +02:00
Bjoern Schiessle dd9dfc4461 show nice display name for remote shares if possible 2015-06-25 12:14:03 +02:00
Morris Jobke 1601867c9d Remove unneeded getetag entries in properties table
* fixes #13281
2015-06-25 08:44:26 +02:00
Vincent Petry 58439c337c Merge pull request #17070 from owncloud/lock-movemountbug
Lock correct paths when moving mount
2015-06-24 18:37:48 +02:00
Morris Jobke 5f59393b30 Merge pull request #17110 from owncloud/share-error-handling
[sharing] handle shares of users that aren't available anymore
2015-06-24 17:38:34 +02:00
Lukas Reschke 004280e407 Merge pull request #17136 from rullzer/fix_remove_link_OCS
Allow removing of link password in OCS again
2015-06-24 16:45:00 +02:00
Vincent Petry 8859004a2b Rollback folder scan if an entry was locked 2015-06-24 15:42:00 +02:00
Thomas Müller 161ca900e0 Merge pull request #17130 from owncloud/update-mime-types
Update wmv and add mts and mt2s
2015-06-24 13:35:58 +02:00
Roeland Jago Douma 6977eff106 set NULL correctly in password update
Old code used 'NULL' but docterine wants null. Now it is possible again
to remove the password from a link share.
2015-06-24 12:37:59 +02:00
Morris Jobke 300d1c88d0 Merge pull request #17106 from owncloud/htaccess-update-only-once
Only update the htaccess ErrorDocument links when they are not set yet
2015-06-24 12:20:22 +02:00
Vincent Petry 35047a2300 Fix locked paths in the moveMount case
When moving a mount point directly, the lock must be applied on the
local mount point path instead of the attached storage root.

Other operations will still lock the attached storage root.
2015-06-24 11:33:28 +02:00
Thomas Müller 5c213539af Update wmv and add mts and mt2s - fixes #17128 and owncloud/firewall#107 2015-06-24 11:06:29 +02:00
Morris Jobke 5ff536b45a [upgrade] add verbosity check and show repair info & steps 2015-06-24 10:25:05 +02:00
Joas Schilling dba5d5e205 Use a OutputFormatter instead of hacking into writeln() 2015-06-24 09:26:30 +02:00
Morris Jobke 4f2f8a6f28 [sharing] handle shares of users that aren't available anymore
* properly handle the case where an abandoned share is left and
  simply skip it
2015-06-23 18:22:36 +02:00
Morris Jobke 02b2b60581 Merge pull request #17095 from owncloud/proper-error-handling
Proper error handling
2015-06-23 17:40:55 +02:00
Joas Schilling 0db311c9db Only update the htaccess ErrorDocument links when they are not set yet 2015-06-23 16:45:56 +02:00
Morris Jobke c86e129ce9 [updater] keep maintenance active on failure and mark failure in red 2015-06-23 14:45:53 +02:00
Björn Schießle cce841c665 Merge pull request #17045 from owncloud/enc_improvements
encryption improvements
2015-06-23 14:30:21 +02:00
Morris Jobke 1ba9fd3ada [upgrade] print update message before running the update code
* otherwise you don't know during which app update something failed
2015-06-23 13:13:44 +02:00
Bjoern Schiessle 95602d4069 make sure that we always read the header from the original file 2015-06-23 11:41:21 +02:00
Morris Jobke fe42553e8a [updater] propagate error case properly
* add $success to the updateEnd hook
* add new return code for a update failure
* add exception class to failure hook message
2015-06-23 10:03:27 +02:00
Morris Jobke fdd01cf15c Added error message on initMountpoints exception 2015-06-23 09:54:03 +02:00
Joas Schilling 738b78f1b0 Use \OC\HintException and translate the hint 2015-06-22 15:34:06 +02:00
Joas Schilling 2b7e5f841a Merge spliteUserRemote with fixRemoteUrlInShareWith 2015-06-22 15:25:23 +02:00
Bjoern Schiessle d38a378b8c make sure that we split username and server address at the first '@' from the right to allow usernames containing '@' 2015-06-22 15:25:23 +02:00
Björn Schießle a88b370dc8 Merge pull request #12546 from oparoz/patch-1
Send the mime icon if we can't generate a preview
2015-06-22 13:55:17 +02:00
Lukas Reschke 4d23e06097 Fix undefined offset
There are cases where no trusted host is specified such as when installing the instance, this lead to an undefined offset warning in the log right after installing. (when another domain than localhost or 127.0.0.1 was used)
2015-06-22 12:28:07 +02:00
Thomas Müller c74c8eff3a Enable x-sendfile only if we do not lock the file system 2015-06-22 12:07:53 +02:00
Thomas Müller ced15c44b4 Merge pull request #16657 from owncloud/view-emit-path
emit hooks from a view as long as the path is inside the default root
2015-06-22 11:29:11 +02:00
Bernhard Posselt 7fe5ab4d4a Merge pull request #17056 from owncloud/appframework-type-cast
Allow multiple whitespace in type hints in AppFramework
2015-06-22 10:35:28 +02:00
Robin McCorkell 04b6f67f07 Allow multiple whitespace in type hints in AppFramework
Type hints such as `@param bool     $doSomething` will now correctly get
parsed, allowing for alignment of docblock parameters if the app developer so
wishes.
2015-06-20 23:52:01 +01:00
Lukas Reschke 1ead0b6f95 Use proper type
This is a string
2015-06-19 21:00:42 +02:00
Lukas Reschke 00a65e30ce Request approved state for disabled apps with ocsid
In case an application gets disabled the level is set to "experimental" if it does not contain a `shipped` tag. This can for example be reproduced by installing the documents app from the appstore and then disabling it. Or cloning an app from git.

With this change the controller will now load the level of the application from the appstore if a valid OCSID has been provided.

Fixes https://github.com/owncloud/core/issues/17003
2015-06-19 19:04:54 +02:00
Olivier Paroz ba3b6f9be4 Remove unneeded returns from private cropping methods 2015-06-19 15:07:49 +02:00
Morris Jobke 7e046d0595 Fix naming of param in private/server.php 2015-06-19 10:23:04 +02:00
Joas Schilling 6adddb3095 Merge pull request #16889 from owncloud/group-sorting-fixes
Only sort by group name when LDAP is involved
2015-06-19 08:29:25 +02:00
Vincent Petry 6697f9524c Merge pull request #16963 from owncloud/fileinfo-lock
Acquire read lock when getting file or directory info
2015-06-18 18:27:20 +02:00
Vincent Petry 0b34d888e6 Merge pull request #17017 from owncloud/cache-update-write-lock
update the file cache within the write lock
2015-06-18 18:27:02 +02:00
Robin Appelman 17be0993b4 remove unneeded normalize 2015-06-18 15:33:44 +02:00
Robin Appelman 6018567df2 unlock the file if the file doesnt exists 2015-06-18 15:26:17 +02:00
Robin Appelman d7960d5db6 dont update the cache on rename fail 2015-06-18 14:45:13 +02:00
Robin Appelman 2a50dbd1a1 update noopscanner 2015-06-18 14:42:48 +02:00
Robin Appelman 3e54696f7f extends phpdoc 2015-06-18 14:30:25 +02:00
Robin Appelman 3526b352dc update the file cache within the write lock 2015-06-18 13:47:03 +02:00
Olivier Paroz 64f0fd0889 Remove unneeded returns from private cropping methods 2015-06-18 13:30:10 +02:00
Olivier Paroz 8193e1d7c1 Move media type icon preview creation to its own method 2015-06-18 13:24:15 +02:00
Vincent Petry a9bca9e3aa Lock file before download
This will throw a LockedException if a concurrent request is currently
touching that file.
2015-06-18 12:05:26 +02:00
Olivier Paroz 13617a0475 Send the mime icon if we can't generate a preview 2015-06-18 11:35:08 +02:00
Morris Jobke 6856316122 Fix return value for OCP PHPDoc 2015-06-17 15:47:45 +02:00
Robin Appelman 72eedda16c use old cache data when locked 2015-06-17 14:13:10 +02:00
Robin Appelman 24f0151f81 handle locked exceptions when getting file/directory info in sabre 2015-06-17 14:13:10 +02:00
Vincent Petry a89bb1d383 Merge pull request #16988 from owncloud/fix-avatar-fail
Fix remaining avatar problems
2015-06-17 13:20:29 +02:00
Lukas Reschke 70ca0102f5 Fix PHPDoc annotations 2015-06-17 11:57:12 +02:00
Thomas Müller d2305f2527 Merge pull request #16729 from owncloud/scanner-read-lock
keep a read lock while scanning a file or folder
2015-06-17 11:52:54 +02:00
Vincent Petry 102c6ffc41 Normalize path in View's lock methods 2015-06-16 17:03:12 +02:00
Vincent Petry e5d34a2733 Merge pull request #16892 from owncloud/lock-returnfullpath
Rethrow LockedException with full path
2015-06-16 16:47:10 +02:00
Lukas Reschke 829f6474ff Merge pull request #16856 from owncloud/issue-15851-fetch-updates-after-page-completion
Load the update information asyncroniously to fix the page load speed
2015-06-16 11:41:44 +02:00
Joas Schilling 497fe93b6c Do not return backends but add a method to check for one 2015-06-16 11:31:04 +02:00
Joas Schilling 171f86ca2e Only sort by group name when LDAP is involved 2015-06-16 11:10:00 +02:00
Joas Schilling 7d8b728066 Merge pull request #16832 from owncloud/memcache-fail
Throw exception if memcache misconfigured or missing
2015-06-16 11:00:18 +02:00
Joas Schilling 60005bea19 Merge pull request #16943 from owncloud/sabre-convertinvalidpath
Convert invalid path exception to sabre exception on MOVE
2015-06-16 10:49:22 +02:00
Vincent Petry 0e3a3dd5d7 Rethrow LockedException with full path
Because the path is converted to md5 from the original exception,
rethrow the exception with the correct full path
2015-06-16 10:48:31 +02:00
Lukas Reschke 15ba2a4100 Reintroduce user cache
This was required by avatars and was broken with https://github.com/owncloud/core/pull/16200

Fixes https://github.com/owncloud/core/issues/16942
2015-06-15 17:54:48 +02:00
Vincent Petry 1f91e9e65d Convert invalid path exception to sabre exception on MOVE 2015-06-15 17:49:11 +02:00
Robin Appelman 4b181f73ca phpdoc 2015-06-15 15:41:52 +02:00
Robin Appelman 567df226e5 fix check if hooks should be emited in runHooks 2015-06-15 15:07:48 +02:00
Robin Appelman 9c0d69a3b2 ensure normalized path form when changing locks 2015-06-15 14:32:29 +02:00
Robin Appelman a4f808b11d properly unlock in case of failed fopen 2015-06-15 14:32:29 +02:00
Robin Appelman 7d72f7d8ce keep a read lock while scanning a file or folder 2015-06-15 14:32:29 +02:00
Thomas Müller 911c43e5f9 Merge pull request #16727 from owncloud/file-put-content-lock
add proper locking to file_put_contents when using streams
2015-06-15 14:22:06 +02:00
Thomas Müller de3ed8e077 Merge pull request #16821 from owncloud/compare-and-delete-locking-watch
Compare and delete locking watch
2015-06-15 14:09:06 +02:00
Thomas Müller b8ab6fb68d Merge pull request #16915 from aidanamavi/add-opus-mimetype
Added Opus Mimetype Support
2015-06-15 13:27:44 +02:00
Thomas Müller b6165b6865 Merge pull request #16912 from owncloud/webdav-smalltransferlockfix
Webdav PUT small file lock must be shared during hooks
2015-06-15 11:30:59 +02:00
Robin Appelman 2fb8a76705 add recursive copy polyfill for storage backends 2015-06-14 15:15:21 +02:00
Aidan Amavi 89a7aefad5 Added Opus Mimetype Support
Added Opus audio mimetype support.
2015-06-13 04:39:37 -04:00
Vincent Petry 4497aa4c68 Webdav PUT small file lock must be shared during hooks
Fixed code path for Webdav PUT of small files to use shared locks during
hook execution, and exclusive during the file operation

This makes it possible for versions to be copied by accessing the file
in a post_write hook.
2015-06-12 18:52:18 +02:00
Robin Appelman a9ff242f6a switch to using watch to implement cas and cad on redis 2015-06-12 17:28:09 +02:00
Robin Appelman 520a741876 clear memcache keys in locking 2015-06-12 17:28:09 +02:00
Robin Appelman ac9f998abd add compare-and-delete to the memcache interface 2015-06-12 17:28:09 +02:00
Robin Appelman 1bc56a99e9 compare-and-set and compare-and-delete using lua scripts for redis 2015-06-12 17:28:09 +02:00
Vincent Petry 446f628136 Merge pull request #16886 from owncloud/webdav-verify-path-again
verify path when getting a node for sabredav
2015-06-12 16:45:20 +02:00
Jan-Christoph Borchardt bb0ea6336d Merge pull request #16888 from owncloud/feature/fix-titles
fixing setting page titles
2015-06-12 14:54:42 +02:00
Vincent Petry 3b08b26589 Throw exception if memcache misconfigured or missing
Instead of falling back to null memcache, throw exceptions.
Also throw file locking specific exceptions in case the class is not
available.
2015-06-12 12:33:06 +02:00
Joas Schilling 5586b2db09 Don't use limit on explode to have only 1 code path 2015-06-12 11:58:26 +02:00
Joas Schilling a7d2b3b9ae Add return value to lock methods and check it in tests 2015-06-12 11:41:05 +02:00
Joas Schilling caf16b083e Only lock files in data/username/files/ 2015-06-12 11:09:38 +02:00
Clark Tomlinson 62286f00a1 fixing setting page titles 2015-06-11 11:39:34 -04:00
Robin Appelman 05cecb101d verify path when getting a node for sabredav 2015-06-11 17:11:33 +02:00
Vincent Petry f13a2d9251 Revert "verify path when getting a node for sabredav" 2015-06-11 15:25:06 +02:00
Robin Appelman 4d10dab813 verify path when getting a node for sabredav 2015-06-11 14:12:04 +02:00
Joas Schilling 4582d14832 Order all use statements correctly 2015-06-11 11:29:27 +02:00
Joas Schilling 05f1ff8715 Correctly import NullCache class 2015-06-11 10:48:30 +02:00
Thomas Müller 3090348bf7 Null -> NullCache 2015-06-11 00:44:13 +02:00
Thomas Müller 48e915c7be Revert "Null -> NullCache"
This reverts commit ff24554e76.
2015-06-11 00:40:26 +02:00
Thomas Müller ff24554e76 Null -> NullCache 2015-06-11 00:34:03 +02:00
Joas Schilling 580155abe7 Load the update information asyncroniously to fix the page load speed 2015-06-10 12:11:05 +02:00
Thomas Müller 9d90421e62 Merge pull request #16803 from owncloud/issue/16801-group-reshare-part-file-enc-keys
Check if the part files has keys when the original file does not
2015-06-09 11:41:36 +02:00
Victor Dubiniuk c7c6556187 Do not use digits in random index names 2015-06-08 19:02:07 +03:00
Thomas Müller 64c9c27f7e Merge pull request #16382 from oparoz/providers-are-responsible-for-the-size-of-their-preview
Fix max preview, some resizing and caching issues and force preview providers to resize their previews properly
2015-06-08 16:14:35 +02:00
Joas Schilling e6681857d2 Check if the part files has keys when the original file does not 2015-06-08 15:42:38 +02:00
Olivier Paroz 3d0a523217 Make sure we have a resource before measuring its size 2015-06-08 15:10:29 +02:00
Thomas Müller 97a3d8c313 Fix login handler for file cache - fixes #16795 2015-06-08 14:13:38 +02:00
Thomas Müller a968b8409d Merge pull request #16158 from owncloud/mountprovider-after-setup
Call newly registered mount providers after the filesystem is setup
2015-06-08 13:42:02 +02:00
Thomas Müller f051b7381b Merge pull request #16402 from owncloud/issue-15956-slow-group-usercount
Sort user groups by group name and hide the user count
2015-06-08 12:11:22 +02:00
Olivier Paroz 71d65cb713 Fix max preview, some resizing and caching issues and force preview providers to resize their previews properly
* introduces a method in OC_Image which doesn't stretch images when trying to make them fit in a box
* adds the method to all key providers so that they can do their job, as expected by the Preview class
* improves the caching mechanism of Preview in order to reduce I/O and to avoid filling the available disk space
* fixes some long standing issues
* **contains mostly tests**
2015-06-06 16:25:04 +02:00
Lukas Reschke ca10ee4d0d Merge pull request #16771 from owncloud/fix-storage-full-message
Add owner to the storage stats to enable better notifications
2015-06-05 20:09:55 +02:00
Morris Jobke 3b188d0b72 Merge pull request #16768 from owncloud/add-missing-mime-types
Adding mimetype x-h for header files
2015-06-05 20:08:34 +02:00
Lukas Reschke cbb15f3cbd Merge pull request #16767 from owncloud/webdav-preventdeleteroot
Prevent deleting Webdav root
2015-06-05 19:56:20 +02:00
Morris Jobke 62ae39208a Add owner to the storage stats to enable better notifications
* getstoragestats.php returns now the owner and it's display name
* show proper storage stats notifications for shared folders
2015-06-05 18:21:41 +02:00
Thomas Müller 5481a846c2 Adding mark down mime type mkd - fixes https://github.com/owncloud/files_texteditor/issues/45 2015-06-05 17:11:14 +02:00
Thomas Müller 5d93353a02 Adding mimetype x-h for header files - fixes https://github.com/owncloud/files_texteditor/issues/70 2015-06-05 16:57:01 +02:00
Vincent Petry 6ae5ae2e31 Prevent deleting Webdav root 2015-06-05 16:55:09 +02:00
Thomas Müller 85d1ca11d4 Merge pull request #16765 from owncloud/fix-chunked-upload-jenkins
Fix chunked upload jenkins
2015-06-05 16:20:33 +02:00
Thomas Müller 5e60795962 Bring back OC\Cache\File - fixes #16760 2015-06-05 14:21:17 +02:00
Joas Schilling 1df95ea1ca Fix "@throws" tags on doc blocks 2015-06-05 13:55:59 +02:00
Vincent Petry 06dda427f3 Validate path in getChild 2015-06-05 12:08:18 +02:00
Joas Schilling bb0cb0aaec Merge pull request #15895 from owncloud/dav-getremoteetag
Get etag from remote OC server
2015-06-03 17:20:25 +02:00
Robin Appelman bcf13aff6f change lock back to shared before updating the cache 2015-06-03 17:18:50 +02:00
Robin Appelman 6b0874203d add proper locking to file_put_contents when using streams 2015-06-03 17:18:50 +02:00
Clark Tomlinson 00742a9d68 Merge pull request #16721 from owncloud/fix-grammar-enc-module
Fixing grammar - refs https://www.transifex.com/projects/p/owncloud/t
2015-06-03 09:54:50 -04:00
Thomas Müller 5dc5b7f86d Catch NotFoundException and return no quota information which simply reflects the current state - no file storage has been initialized for the user. 2015-06-03 15:00:56 +02:00
Thomas Müller 259b6ac2c1 Fixing grammar - refs https://www.transifex.com/projects/p/owncloud/translate/#en_GB/lib/50330746 2015-06-03 14:56:18 +02:00
Thomas Müller 739c3f01aa Merge pull request #16434 from owncloud/persist-maintenance-state
Persist the state of the maintenance after an upgrade
2015-06-03 13:56:17 +02:00
Thomas Müller 69d1e7aaf4 Merge pull request #16687 from owncloud/issue-16113-redis-minimum-version
Check for redis to be 2.2.5+
2015-06-03 13:55:26 +02:00
Morris Jobke e3440863bc Merge pull request #16708 from owncloud/enc_fix_move_to_trash
make sure that we always use the correct owner for both source and target
2015-06-03 13:49:46 +02:00
Vincent Petry 6ab38be40e Translate invalid path exception to sabre exception for files 2015-06-03 12:22:31 +02:00
Bjoern Schiessle 7eb2b31e34 make sure that we always use the correct owner for both source and target 2015-06-03 11:59:06 +02:00
Morris Jobke 259937680b Merge pull request #16667 from owncloud/issue-16510-fix-encryption-with-s2s-shares
Add tests for the storage wrapper and fix the wrapping
2015-06-02 16:42:32 +02:00
Joas Schilling bdc82dcfb9 Check for redis to be 2.2.5+ 2015-06-02 15:42:48 +02:00
Robin Appelman a9455be14a more hints 2015-06-02 14:16:37 +02:00
Robin Appelman 0497534a6e more type hints 2015-06-02 14:07:55 +02:00
Robin Appelman 8926bca0c7 phpdoc, strict and type hints 2015-06-02 14:07:55 +02:00
Robin Appelman 6f47a547d8 only use mount provider if we have a valid user 2015-06-02 14:07:54 +02:00
Robin Appelman 24131586d7 call mount providers that are registered after the filesystem is setup 2015-06-02 14:07:54 +02:00
Robin Appelman c91b52d38c move emitter implementation to a trait 2015-06-02 14:07:54 +02:00
Robin Appelman 4b48dd424f emit hooks from a view as long as the path is inside the default root 2015-06-02 14:07:20 +02:00
Thomas Müller 3ebc8f0564 Merge pull request #16107 from owncloud/fix-getLocalFile-encryption-master
Fix get local file encryption master
2015-06-02 13:47:37 +02:00
Joas Schilling be1f319511 Correctly ignore remote shares aswell 2015-06-02 12:33:51 +02:00
Joas Schilling 50a31fa8f9 Add unit tests for wrapStorage 2015-06-02 12:33:17 +02:00
Joas Schilling 9a4040c7ca Move the storage wrapping into a testable method 2015-06-02 12:29:06 +02:00
Vincent Petry 30d7f92763 Get etag from remote OC server 2015-06-02 11:42:03 +02:00
Morris Jobke cf2c599218 Merge pull request #16200 from owncloud/kill-globalfilecache
Drop file caching
2015-06-02 09:11:33 +02:00
Lukas Reschke 73875da4b0 Clean application identifier before processing 2015-06-01 17:03:51 +02:00
Thomas Müller 2104c2ffdd Fixing undefined index 'foo' 2015-06-01 14:10:00 +02:00
Robin Appelman 8902e2be73 fix nooplockingprovider 2015-06-01 13:25:27 +02:00
Robin Appelman ce04cf6610 shared lock around hooks 2015-06-01 13:24:02 +02:00
Robin Appelman 661c9e2444 add changeLock to the storage api 2015-06-01 13:24:02 +02:00
Robin Appelman a1372b2fb5 add method to atomically change between shared and exclusive lock 2015-06-01 13:24:02 +02:00
Vincent Petry 270a10b754 Return 423 instead of 503 for locked files 2015-06-01 13:24:02 +02:00
Vincent Petry 0451a6652d Move locking exceptions 2015-06-01 13:24:02 +02:00
Vincent Petry ba174ac626 Convert LockedException to FileLocked in Sabre connector
For Sabre to be able to return the proper error code instead of 500, the
LockedException is now rethrown as FileLocked exception in the Sabre
connector
2015-06-01 13:22:57 +02:00
Robin Appelman 8665a98744 add locking for non-chunking webdav upload 2015-06-01 13:22:57 +02:00
Robin Appelman 72776b165f use arraycache for locking in unit tests 2015-06-01 13:22:56 +02:00
Robin Appelman 6b965d71d1 add seperate config option for locking memcache backend 2015-06-01 13:22:56 +02:00
Robin Appelman 72847dbc77 always use locking in unit tests 2015-06-01 13:22:56 +02:00
Robin Appelman 437c0b55a6 unlock source file when we cant lock the target in a rename 2015-06-01 13:22:56 +02:00
Robin Appelman 668fafd4d2 close file handle after sending sabre response 2015-06-01 13:22:56 +02:00
Vincent Petry 2f4f468399 Added config switch for file locking 2015-06-01 13:22:56 +02:00
Vincent Petry 6df502a5aa Fix Null memcache fallback to match interface 2015-06-01 13:22:56 +02:00
Robin Appelman 006eaa84aa dont release shared lock if we dont have any 2015-06-01 13:22:56 +02:00
Robin Appelman f0b8672729 fix locking root of a view 2015-06-01 13:22:56 +02:00
Robin Appelman e08423f956 release all locks on shutdown 2015-06-01 13:22:56 +02:00
Robin Appelman 2d63fd77de dont apply callback wrapper when fopen failed 2015-06-01 13:22:56 +02:00
Robin Appelman 1270c6800d dont lock on meta data operations 2015-06-01 13:22:56 +02:00
Robin Appelman 35c377f7a9 phpdoc and minor issues 2015-06-01 13:22:56 +02:00
Vincent Petry 8d53dc803f Use md5 + prefix for file locking keys in memcache
Also trim slashes from paths to make sure the locks are based on the
same paths.
2015-06-01 13:22:56 +02:00
Vincent Petry 0775e9c1ca Use md5 for lock key 2015-06-01 13:22:56 +02:00
Vincent Petry 5edf294ce5 Add CAS methods to Null memcache
This prevents breaking ownCloud completely when memcache is not enabled
and the locking code is triggered
2015-06-01 13:22:56 +02:00
Robin Appelman a1a25a9b5b fix unlocking when moving mount points 2015-06-01 13:22:56 +02:00
Robin Appelman 7e418c7d69 high level locking wip 2015-06-01 13:22:56 +02:00
Robin Appelman e64360e72d always use arraycache for unit tests 2015-06-01 13:22:56 +02:00
Robin Appelman bf7002bc65 add locking to the view apo 2015-06-01 13:22:56 +02:00
Robin Appelman 536e187e51 add locking to the storage api 2015-06-01 13:22:56 +02:00
Robin Appelman cdf7f91259 expose locking provider in the server container 2015-06-01 13:22:55 +02:00
Vincent Petry 06f8c80af6 Validate target file name for some webdav ops 2015-05-29 19:14:38 +02:00
Thomas Müller 67cef93fdd Merge pull request #16578 from owncloud/fix_16556
show txt preview when file contains text
2015-05-28 20:48:16 +02:00
Morris Jobke 7f83829db3 Merge pull request #16592 from owncloud/fix-16574
Add type hint for OC_Channel
2015-05-28 20:36:44 +02:00
Vincent Petry e114d00242 Only use quota stream wrapper on "files"
Prevent using the quota stream wrapper on trashbin folders and other
metadata folders
2015-05-28 18:31:20 +02:00
Vincent Petry ded62ff693 Merge pull request #16501 from owncloud/enc_fix_move_versions_between_storages
[encryption] fix move versions between storages
2015-05-28 15:28:25 +02:00
Vincent Petry 474c99e19a Merge pull request #16577 from owncloud/enc_improve_migration
only request encryption module for files which are not excluded
2015-05-28 11:31:33 +02:00
Björn Schießle e1483f65c3 Merge pull request #16591 from owncloud/enc_improved_error_message
improved error message for various states
2015-05-28 10:55:53 +02:00
Bjoern Schiessle 5549641f1f improve error messages displayed to the user 2015-05-27 21:00:02 +02:00
Victor Dubiniuk 4239054383 Add type hint for OC_Channel 2015-05-27 18:03:11 +03:00
Bjoern Schiessle 0de59acb49 only request encryption module for files which are not excluded 2015-05-27 15:47:40 +02:00
Lukas Reschke ffd73ef2e4 Fix indentation 2015-05-27 14:57:19 +02:00
Georg Ehrke bb676f2799 show txt preview when file contains text 2015-05-27 14:11:33 +02:00
Morris Jobke 3de945d13d Merge pull request #16527 from owncloud/end-processing-when-404
End processing when file is not found
2015-05-27 09:36:05 +02:00
Thomas Müller 4513cf5967 Revert "Revert "Revert "FIX for webdav.mediencenter.t-online.de""" 2015-05-26 14:40:07 +02:00
Oliver Kohl D.Sc f8938f004d Revert "Revert "FIX for webdav.mediencenter.t-online.de"" 2015-05-26 13:36:45 +02:00
Björn Schießle f70c309c2d Merge pull request #16561 from owncloud/add-default-timeout-back
Add connection timeout to default POST options
2015-05-26 12:23:57 +02:00
Vincent Petry f1fc7b155c Merge pull request #16515 from owncloud/deprecate-useless-helper-class
Deprecate useless helper class
2015-05-26 12:22:05 +02:00
Vincent Petry 39c6a36488 Merge pull request #16532 from owncloud/cors-no-cookie-auth
Disallow cookie auth for cors requests
2015-05-26 12:12:04 +02:00
Björn Schießle ab0747113c Merge pull request #16452 from owncloud/enc_ftp_upload
always write file, if fseek doesn't work we write the whole file
2015-05-26 12:02:41 +02:00
Thomas Müller 3babcd0344 Merge pull request #16339 from owncloud/master-override-channel
Allow change update channel via public API
2015-05-26 11:42:41 +02:00
Lukas Reschke dff361dc5c Add connection timeout to default POST options
Fixes https://github.com/owncloud/core/issues/16560
2015-05-26 11:22:50 +02:00
jknockaert a577e723b0 flush() comments + perf opt 2015-05-26 10:22:52 +02:00
Vincent Petry ce34edacfa Merge pull request #16526 from owncloud/enc_fix_versions_webdav_upload
remove part file extension before we read a filekey
2015-05-22 16:42:52 +02:00
Bjoern Schiessle c63f2286c0 copy keys before we move a file between storages to make sure that the new target file reuses the old file key, otherwise versions will break 2015-05-22 15:41:28 +02:00
Bernhard Posselt c8e3599cad disallow cookie auth for cors requests
testing ...

fixes

fix test

add php doc

fix small mistake

add another phpdoc

remove not working cors annotations from files app
2015-05-22 14:06:26 +02:00
Bjoern Schiessle fef75e5417 remove part file extension before we read a filekey to reuse a existing key if possible, otherwise stuff like versioning will break 2015-05-22 12:12:31 +02:00
Lukas Reschke 8ce3d6ea57 End processing when file is not found
We have to end the processing when a file is not found or otherwise the method is proceeding and even sending invalid file paths to the sendfile methods.

Due to nginx preventing directory traversals this is luckily not immediately exploitable. We should for hardening purposes however quit the script execution just as we do for 403 cases and others as well.
2015-05-22 11:53:02 +02:00
Vincent Petry b82d902e18 Merge pull request #16493 from owncloud/cache-movewithcorrectmimetype
Get correct mimetype when moving and changing extension
2015-05-22 11:37:11 +02:00
Joas Schilling d7b2bc9e2f Merge pull request #16516 from owncloud/fix-phpdoc-trait
Fix PHPDoc
2015-05-22 09:47:59 +02:00
Lukas Reschke 3d8ea96e55 Fix PHPDoc
Use correct parameters
2015-05-22 00:17:38 +02:00
Lukas Reschke c1f8829590 Deprecate useless helper class
The helper class has no real reason anymore with 8.1.0 as we now have better public APIs. No need for an `IHelper` class like that from my opinion.
2015-05-21 23:35:37 +02:00
jknockaert bf6151e799 fix calculation of $count, $count is always 8129 so we need to check this
against the unencrypted file size
2015-05-21 14:15:26 +02:00
Bjoern Schiessle 5a20edac82 test to simulate a non-seekable stream wrapper 2015-05-21 14:15:26 +02:00
jknockaert fb51880a4a encrypted filesize calculation in flush() 2015-05-21 14:15:26 +02:00
Bjoern Schiessle 38bceb0d74 distinguish between source and target mount point to allow copy/rename between system wide mount points and user specific mountpoints 2015-05-21 14:06:45 +02:00
Lukas Reschke 94077caea9 Merge pull request #16499 from owncloud/fix-phpdoc-annotations
Fix PHPDoc 🙈
2015-05-21 13:54:01 +02:00
Lukas Reschke 694d639f94 Fix PHPDoc 🙈
*sigh*
2015-05-21 13:07:54 +02:00
Vincent Petry 22968e806c Get correct mimetype when moving and changing extension
Fixes issue when restoring folders from trash cross-storage, as such
folders have an extension ".d12345678".

Fixes issue when moving folders between storages and at the same time
changing their extension.
2015-05-21 10:57:58 +02:00
Steffen Lindner 48040c46cb Skip disable3rdParty Apps 2015-05-20 17:06:00 +02:00
Morris Jobke 39d1e99228 Merge pull request #16322 from owncloud/trash-view
dont go trough the view when moving to trash
2015-05-20 14:44:01 +02:00
Vincent Petry 7386257676 Merge pull request #16075 from owncloud/skeleton-copy-delay
wait with copying the skeleton untill login and setupfs are done
2015-05-20 13:52:08 +02:00
Morris Jobke 1e59be2d2d Merge pull request #16453 from cmeh/patch-6
Clean-up of orthography, grammar
2015-05-20 10:26:42 +02:00
Thomas Müller f9d04f62a8 Merge pull request #16440 from owncloud/scrutinizer-patch-1
Scrutinizer Auto-Fixes
2015-05-19 22:12:35 +02:00
Christian Hoffmann 35207ae363 Clean-up of orthography, grammar
* Changed "instead to" to "instead of".
* Changed "setup" to "set up" (past participle).
2015-05-19 21:15:22 +02:00
Thomas Müller f59576c3ca Merge pull request #16447 from owncloud/fix-minor-code-problems
Fix unexisting class and broken doc
2015-05-19 16:23:36 +02:00
Joas Schilling d832c4ae23 Fix unexisting class and broken doc 2015-05-19 15:27:50 +02:00
Thomas Müller 10d1fd1306 Merge pull request #16419 from owncloud/user-group-backend-performance
Reduce the complexity of the search queries in the user/group backends to a minimum
2015-05-19 14:51:13 +02:00
Robin Appelman 9c751f1d87 use copy when doing a crossStorageCopy on the same storage 2015-05-19 14:21:58 +02:00
Scrutinizer Auto-Fixer fdbc21fc6c Scrutinizer Auto-Fixes
This commit consists of patches automatically generated for this project on https://scrutinizer-ci.com
2015-05-19 11:23:06 +00:00
Thomas Müller ad88a7d53d exception class will be logged as well - helps especially in cases where the message contained is empty - e.g. "message":"OCP\\Files\\NotFoundException: at \/home\/deepdiver\/Development\/ownCloud\/core-autotest\/apps\/provisioning_api\/lib\/users.php#354", 2015-05-19 12:35:22 +02:00
Thomas Müller a52afb040a Merge pull request #15965 from owncloud/conditional-logging
Conditional logging
2015-05-19 12:00:19 +02:00
Thomas Müller d90b83725f Merge pull request #16085 from owncloud/encryption-module-rename
rename to 'Default encryption module'
2015-05-19 11:13:33 +02:00
Morris Jobke 064f5204cc Persist the state of the maintenance after an upgrade
* if maintenance mode was enabled before an upgrade
  it will be enabled afterwards too
* fixes #16429
2015-05-19 10:56:04 +02:00
Morris Jobke aae9274210 Merge pull request #16293 from owncloud/xcache
Mute XCache error when trying to clear the opcode cache
2015-05-19 09:32:17 +02:00
Björn Schießle 1c411baf17 Merge pull request #16412 from owncloud/jknockaert-patch-1
fix #16356
2015-05-18 19:26:40 +02:00
Clark Tomlinson f9b6ee86cd Merge pull request #16399 from owncloud/enc_rmdir_fix
[encryption] only try to delete file keys if it is a valid path
2015-05-18 11:09:36 -04:00
Joas Schilling 8efc8c0a96 Reduce the complexity of the search queries in the backends to a minimum 2015-05-18 16:39:21 +02:00
Thomas Müller c28cd03770 Merge pull request #16403 from owncloud/fix-command-loading
Only load commands of enabled apps
2015-05-18 16:16:04 +02:00
jknockaert 2834971a77 fix #16356 2015-05-18 15:06:55 +02:00
Björn Schießle a1e60e7882 Merge pull request #15980 from owncloud/jknockaert-patch-1
fix bug #15973
2015-05-18 15:01:16 +02:00
Vincent Petry 9d3d7ec659 Small perf tweak in strlen loop 2015-05-18 13:27:22 +02:00
Joas Schilling d683752b37 Sort user groups by group name and hide the user count 2015-05-18 12:55:19 +02:00
Morris Jobke ad3a32edf6 Only load commands of enabled apps 2015-05-18 12:33:56 +02:00
Robin Appelman 077d41a9ce wait with copying the skeleton untill login and setupfs are done 2015-05-18 12:11:31 +02:00
Bjoern Schiessle efa674f10d only try to delete file keys if it is a valid path 2015-05-18 11:54:51 +02:00
Vincent Petry 7e271012b2 Merge pull request #16243 from owncloud/error_if_download_failed
redirect to error page if download failed
2015-05-18 11:42:55 +02:00
Morris Jobke 7ee3f99a4a Merge pull request #16364 from owncloud/add-warning-webdav
Add notice that WebDAV interface is not intended for browsers
2015-05-18 11:28:47 +02:00
Roeland Jago Douma 9866066d3e Depreatace OC_Util::getUrlContent
It is just a wrapper and the other functions are deprecated already
2015-05-18 11:03:48 +02:00
Bjoern Schiessle 887be709f5 a new approach to display the error message 2015-05-18 10:15:17 +02:00
Vincent Petry 246000f799 Merge pull request #16176 from owncloud/fix-provisioning-api-set-quota
Validate the quota value to be a correct value
2015-05-15 18:07:13 +02:00
Joas Schilling 0991c0cc02 Merge pull request #16292 from owncloud/webdav-storage-fireprehooks
Fire prehooks when uploading directly to storage
2015-05-15 15:08:27 +02:00
Thomas Müller 937306b416 Merge pull request #16323 from owncloud/enc_webdav_fixes
some encryption fixes
2015-05-15 10:38:22 +02:00
Lukas Reschke 13778893d9 Add notice that WebDAV interface is not intended for browsers
Fixes https://github.com/owncloud/core/issues/16359
2015-05-15 09:07:39 +02:00
Victor Dubiniuk af814ba270 Allow change update channel via public API 2015-05-13 20:29:33 +03:00
Bjoern Schiessle ccbefb6e75 delete all file keys doesn't need the encryption module as parameter; implement rmdir; getFileKeyDir should also work for part files and complete directories 2015-05-13 19:06:23 +02:00
Vincent Petry 3cae0135ad Fire prehooks when uploading directly to storage 2015-05-13 17:47:04 +02:00
Robin Appelman 4789e87a53 Merge pull request #16276 from owncloud/dav-quota-root
fix webdav quota check for the root of the dav endpoint
2015-05-13 14:43:02 +02:00
Arthur Schiwon e5a91fc185 remove file cache remainings from server container 2015-05-13 12:26:36 +02:00
Lukas Reschke cbfdbf96d2 Mute XCache error when trying to clear the opcode cache
From https://github.com/owncloud/core/issues/16287:

> This is caused by XCache at 8e59d4c64b/lib/private/util.php (L1276) where we are trying to reset the opcode cache with `XC_TYPE_PHP`.
> I suspect that while XCache is installed its opcode component is not used. Unfortunately, the XCache API is not really properly documented and thus I don't know what API we would have to call to check whether the `XC_TYPE_PHP` cache is populated. In fact, there is an [open XCache bug](http://xcache.lighttpd.net/ticket/176) since 7 years that discusses this problem and is likely to never get fixed since XCache is abandonware.

Fixes https://github.com/owncloud/core/issues/16287
2015-05-12 19:22:39 +02:00
Morris Jobke dc362823e0 Merge pull request #16269 from owncloud/master-fix-16179
Check if cURL supports the desired features
2015-05-12 18:27:57 +02:00
Arthur Schiwon d6becb8d82 add repair steps to get rid of old background jobs 2015-05-12 18:19:44 +02:00
Arthur Schiwon e016ed55ff also free joblist and base from file cache code 2015-05-12 17:44:31 +02:00
Robin Appelman 11e1acd8ec fix webdav quota check for the root of the dav endpoint 2015-05-12 14:02:27 +02:00
Björn Schießle fbe4b77c49 Merge pull request #16228 from owncloud/enc_fix_restore
use hooks to update encryption keys
2015-05-12 13:10:16 +02:00
Lukas Reschke 4613456a8a Check if cURL supports the desired features
Older versions of cURL that are unfortunately still bundled by distributors don't support these features which will result in errors and other possibly unpredictable behaviour.

Fixes https://github.com/owncloud/core/issues/16179 for master – stable8 requires another patch.
2015-05-12 12:00:56 +02:00
Morris Jobke b11c0c533e Merge pull request #16233 from owncloud/enc_fix_check_if_file_is_excluded
fix check if a file is excluded from encryption
2015-05-12 09:12:38 +02:00
Morris Jobke afcec88c6f Merge pull request #16234 from owncloud/issue-16206-fix-app-config-parallel-insert
Issue 16206 fix app config parallel insert
2015-05-11 16:05:30 +02:00
Bjoern Schiessle 9dd517071e fix check if file is excluded from encryption 2015-05-11 12:38:59 +02:00
Joas Schilling dfed287dc0 Use insertIfNotExists to avoid problems with parallel calls 2015-05-11 12:38:33 +02:00
Bjoern Schiessle 0d5c7a11e2 use hooks to update encryption keys instead of the storage wrapper if a file gets renamed/restored, as long as we
are in the storage wrapper the file cache isn't up-to-date
2015-05-11 12:06:57 +02:00
Thomas Müller 9c57ae89d9 Some locales need to be converted to be compliant with CLDR 2015-05-08 23:45:07 +02:00
Morris Jobke e79c255cab Conditional logging
* Log condition for log level increase based on conditions. Once one of these
   conditions is met, the required log level is set to debug. This allows to
   debug specific requests, users or apps

 * Supported conditions (setting `log_condition` in `config.php`):
    - `shared_secret`: if a request parameter with the name `log_secret` is set to
                this value the condition is met
    - `users`:  if the current request is done by one of the specified users,
                this condition is met
    - `apps`:   if the log message is invoked by one of the specified apps,
                this condition is met
 * fix unit test and add app log condition test
2015-05-08 15:58:33 +02:00
Morris Jobke 892b5ceeeb Move log level check to logger parent class
* remove duplicate code from child classes
2015-05-08 15:14:45 +02:00
Arthur Schiwon 3de7f58321 remove file cache classes and its tests 2015-05-08 14:05:54 +02:00
Lukas Reschke c9921ec127 Merge pull request #16124 from owncloud/issue-16109-fix-share-email-with-shared-folder
Fix the share mail notification when the item is in a folder
2015-05-08 13:03:28 +02:00
Lukas Reschke 16a0de6314 Merge pull request #16146 from owncloud/issue-16103-hide-module-already-exists-on-enable-app
Avoid the log entry with the ModuleAlreadyExists exception when enabl…
2015-05-08 11:55:02 +02:00
Thomas Müller 4659927d7a Pure numbers are returned as bytes right away 2015-05-08 10:54:54 +02:00
Thomas Müller 15d134124b Validate the quota value to be a correct value 2015-05-07 17:56:13 +02:00
Robin Appelman 06a65fab13 use cross storage move when renaming the part file during webdav put 2015-05-07 14:28:31 +02:00
Joas Schilling 49f94b17f7 Avoid the log entry with the ModuleAlreadyExists exception when enabling the app 2015-05-07 11:00:55 +02:00
Thomas Müller 55eaa165f8 Merge pull request #16119 from owncloud/fix-16056
[HHVM] Throw RunTimeException from OC\AppFramework\App::buildAppNamespace()
2015-05-07 00:20:57 +02:00
Andreas Fischer e418ced656 Check return value of OC_App::getAppPath() and verify info.xml exists. 2015-05-06 17:15:28 +02:00
Joas Schilling b4471c2591 Fix the share mail notification when the item is in a folder 2015-05-06 15:44:19 +02:00
Jan-Christoph Borchardt 35292eb66c rename to 'Default encryption module' 2015-05-06 15:31:05 +02:00
Joas Schilling aea734aaf1 Fix missing types on doc block and deduplicate the method name 2015-05-06 14:31:10 +02:00
Bjoern Schiessle e4829a2358 update 'encrypted'-flag in file cache according to the storage settings 2015-05-06 14:20:05 +02:00
Bjoern Schiessle dc39bda870 move/copy from storage 2015-05-06 14:20:02 +02:00
Bjoern Schiessle 83ed4ee5b6 unit tests 2015-05-06 12:28:15 +02:00
Bjoern Schiessle e7a3911c83 check if encryption is enbaled before we start moving keys 2015-05-06 11:35:45 +02:00
Lukas Reschke 9a159372cb Merge pull request #16067 from owncloud/verbosity-in-app-code-check
Add verbosity option to app:check-code
2015-05-06 11:21:23 +02:00
Thomas Müller 35a2fd3f89 Only return cached files if existing 2015-05-06 11:16:44 +02:00
Morris Jobke 874d35b27a Merge pull request #16070 from owncloud/enc_update_file_cache_on_copy
make sure that we keep the correct encrypted-flag and the (unencrypted)size
2015-05-06 10:28:10 +02:00
Morris Jobke f1903f61a1 Merge pull request #16072 from owncloud/phpdoc-cache
improve phpdoc of cache classes
2015-05-06 09:38:56 +02:00
Morris Jobke c3fb021acf Merge pull request #16017 from owncloud/proper-update-notification
Use OC.Notification for update notifications
2015-05-06 09:28:42 +02:00
Jörn Friedrich Dreyer 4c0d1b0460 Merge pull request #16050 from owncloud/add-workaround-for-populate-raw-post-data
Don't display errors and log them
2015-05-06 08:55:46 +02:00
Thomas Müller a96c2b8354 Only use cached files in case encryption is enabled - in any other case let the underlying storage handle this accordingly - refs #16061 #16062 and others 2015-05-05 16:19:24 +02:00
Bjoern Schiessle 7089af96f2 make sure that we keep the correct encrypted-flag and the (unencrypted)size if a file gets copied 2015-05-05 16:17:14 +02:00
Robin Appelman e0d151505f improve phpdoc of cache classes 2015-05-05 16:06:28 +02:00
Morris Jobke 56b1c93a79 Add verbosity option to app:check-code
* by default only lists files with errors
* option -v lists all files even if there are no errors
2015-05-05 13:57:23 +02:00
Thomas Müller aae098c24a Check usage of != and == - refs #16054 2015-05-05 12:59:33 +02:00
Lukas Reschke 11310355ed Don't depend on always_populate_raw_post_data 2015-05-05 12:36:15 +02:00
Lukas Reschke 7c5558327d Check `mbstring.func_overload` only if the mb module is installed.
Fixes https://github.com/owncloud/core/issues/14670
2015-05-04 17:13:25 +02:00
Lukas Reschke 64393b4c03 Remove PHP 5.4 warning in checkSetup
This is catched in index.php as older PHP versions will never execute the code path until there due to 5.4 syntax changes.
2015-05-04 17:11:17 +02:00
Thomas Müller 08b98a8ede Merge pull request #16042 from owncloud/fix-output-buffering
Remove hard-dependency on disabled output_buffering
2015-05-04 16:43:32 +02:00
Lukas Reschke 5c7d15b941 Merge pull request #16043 from owncloud/activity-288-log-entry-when-no-favorite
Fix undefined variable $tagId
2015-05-04 16:22:21 +02:00
Joas Schilling 50f6386c63 Fix undefined variable $tagId 2015-05-04 16:19:26 +02:00
Joas Schilling 59c657da53 Merge pull request #15772 from owncloud/issue-15771-dont-restrict-permissions-for-share-owner
Do not restrict permissions for the original owner
2015-05-04 15:07:37 +02:00
Lukas Reschke 4b9e034968 Remove hard-dependency on disabled output_buffering
This removes the hard-dependency on output buffering as requested at https://github.com/owncloud/core/issues/16013 since a lot of distributions such as Debian and Ubuntu decided to use `4096` instead of the PHP recommended and documented default value of `off`.

However, we still should encourage disabling this setting for improved performance and reliability thus the setting switches in `.user.ini` and `.htaccess` are remaining there. It is very likely that we in other cases also should disable the output buffering but aren't doing it everywhere and thus causing memory problems.

Fixes https://github.com/owncloud/core/issues/16013
2015-05-04 14:15:15 +02:00
Thomas Müller 4de45b5e61 Merge pull request #15958 from owncloud/usage-of-public-log-interface
Use internally \OCP\ILogger instead of \OC\Log
2015-05-04 09:13:26 +02:00
Morris Jobke cd516eedcd Use OC.Notification for update notifications
* instead of a static rendering inside PHP use the
  JS OC.Notification.showTemporary to hide the
  notification after 7 seconds automatically
* fixes #14811
2015-05-03 17:26:03 +02:00
Lukas Reschke 6738c17cb5 Add proper versioning for doc URL
As per 8.1 we have docs for minor versions as well so we need to link to `8.1` here instead to `8.0`.

Fixes https://github.com/owncloud/core/issues/16002
2015-05-02 21:05:11 +02:00
Thomas Müller 6b691e3840 Merge pull request #15937 from owncloud/file-locking
Add memcache based shared/exclusive locking
2015-05-01 17:47:23 +02:00
jknockaert f5415653fd fix #15973
Rework of stream_seek handling; there where basically two bugs: 1. seeking to the end of the current file would fail (with SEEK_SET); and 2. if seeking to an undefined position (outside 0,unencryptedSize) then newPosition was not defined. I used the opportunity to simplify the code.
2015-04-30 17:10:18 +02:00
Robin Appelman ba7d221cff allow getting the path from the lockedexception 2015-04-30 14:48:42 +02:00
Robin Appelman a40a237441 use trait for cas polyfill for xcache 2015-04-30 14:48:39 +02:00
Robin Appelman 96f9573a4b add memcache based shared/exclusive locking 2015-04-30 14:48:39 +02:00
Robin Appelman acf30ede95 add compare and swap to memcache 2015-04-30 14:48:39 +02:00
Robin Appelman 29213b6136 extends memcache with add, inc and dec 2015-04-30 14:48:36 +02:00
Bernhard Posselt 360d0e3e5e fix #15962 2015-04-30 12:44:45 +02:00
Morris Jobke fbba7a61cb Use internally \OCP\ILogger instead of \OC\Log
* this is the preparation for some upcoming logger related changes
* also fixes an issue in the public interface where we request
  an internal class as parameter
2015-04-30 11:52:30 +02:00
Thomas Müller d308ec4f0e Merge pull request #15949 from owncloud/l10n-string-json
Implement json serialize for l10n string
2015-04-30 11:11:16 +02:00
Bernhard Posselt 1e58538f0e add aliases to pascal case constructor paramters to make it possible to auto assemble controllers 2015-04-29 22:29:45 +02:00
Bernhard Posselt 5b857a6eab implement json serialize for l10n string 2015-04-29 21:22:42 +02:00
Joas Schilling f524ae261a Ignore "parent" shares when the sharee is the owner of the reshare-source 2015-04-29 14:18:46 +02:00
Joas Schilling 3c37cbdfe7 Correctly select file cache values also when checking group shares 2015-04-29 14:12:12 +02:00
Morris Jobke 8c7db2536d Merge pull request #15596 from owncloud/issue/15589
Correctly generate the feedback URL for remote share
2015-04-29 10:52:43 +02:00
Morris Jobke 7df7a3b360 Merge pull request #15906 from rullzer/fix_15777
Password set via OCS API should not be double escaped
2015-04-29 10:44:25 +02:00
Lukas Reschke 34d0e610cc Filter potential dangerous filenames for avatars
We don't want to have users misusing this API resulting in a potential file disclosure of "avatar.(jpg|png)" files.
2015-04-28 16:57:23 +02:00
Joas Schilling 2eecfcbb80 Fix scrutinizer complains and return type doc 2015-04-28 11:28:55 +02:00
Joas Schilling 9fb7d0bca9 Correctly remove the protocol before prepeding it 2015-04-28 11:28:54 +02:00
Joas Schilling 8f7c64253e Correctly generate the feedback URL for remote share
The trailing slash was added in c78e3c4a7f
to correctly generate the encryption keys
2015-04-28 11:28:54 +02:00
Morris Jobke de8c15e1a4 Merge pull request #14764 from owncloud/shared-etag-propagate
Propagate etags across shared storages
2015-04-28 10:58:50 +02:00
Morris Jobke b4a15db046 Merge pull request #15901 from owncloud/fix-share-docs
fix several issues with doc blocks on share.php
2015-04-28 10:41:04 +02:00
Roeland Jago Douma 73bb3a22f6 Password set via OCS API should not be double escaped 2015-04-28 10:33:19 +02:00
Joas Schilling 7c65448377 Fix return type of the getRootFolder() method 2015-04-28 09:36:29 +02:00
Joas Schilling 46083006e1 fix several issues with doc blocks on share.php 2015-04-28 08:40:47 +02:00
Thomas Müller eb0e9e5646 Merge pull request #15890 from owncloud/fix-helper-docs
Fix several type(hint) errors in private/helper.php
2015-04-27 15:28:50 +02:00
Thomas Müller 7d0eba7a41 Merge pull request #15886 from owncloud/fix-15848-master
Adjust isLocal() on encryption wrapper
2015-04-27 15:06:26 +02:00
Joas Schilling db6395ae20 Fix several type(hint) errors in private/helper.php 2015-04-27 14:45:05 +02:00
Thomas Müller 678b7d7e4d Merge pull request #15860 from owncloud/enc_fallback_old_encryption
[encryption] handle encrypted files correctly which where encrypted with a old version of ownCloud (<=oc6)
2015-04-27 14:32:19 +02:00
Thomas Müller 936d564058 fixes #15848 2015-04-27 14:26:05 +02:00
Morris Jobke 93c25a1f4a Merge pull request #15882 from owncloud/fix-type-annotation
Fix type annotation
2015-04-27 14:17:59 +02:00
Robin Appelman 2e897f05b1 triger propagation for webdav uploads
use post hooks for share etag propagator
2015-04-27 14:07:16 +02:00
Robin Appelman 45784f213f fix propagation when renaming a directly reshared folder 2015-04-27 14:07:16 +02:00
Robin Appelman 30ad56813a propagate etags for all user of a share 2015-04-27 14:07:15 +02:00
Robin Appelman 518d5aadf5 Allow getting *all* share entries owned by a user 2015-04-27 14:07:15 +02:00
Robin Appelman 849e5521de Make the change propagator an emitter 2015-04-27 14:07:15 +02:00
Thomas Müller cc331609bf Merge pull request #15411 from mmattel/fix_for_15375_better_message_text
Improve error messge text for app upgrade try (#15375)
2015-04-27 13:38:16 +02:00
Lukas Reschke d0363fe396 Fix type annotation
Obviously should be an int
2015-04-27 13:31:18 +02:00
Bjoern Schiessle 27683f9442 fall back to the ownCloud default encryption module and aes128 if we read a encrypted file without a header 2015-04-27 13:01:18 +02:00
Joas Schilling d600955a51 Make getDefaultModuleId public and get module protected 2015-04-27 11:03:51 +02:00
Joas Schilling a09df6d453 Verify that the encryption module exists before setting it 2015-04-27 11:03:50 +02:00
Lukas Reschke 4dfdaf741c Merge pull request #15834 from owncloud/make-temporary-file-really-unique
Fix collision on temporary files + adjust permissions
2015-04-25 23:18:26 +02:00
Lukas Reschke b9df932e3c Merge pull request #15683 from owncloud/block-legacy-clients
Block old legacy clients
2015-04-24 18:21:10 +02:00
Bjoern Schiessle 9a5783b284 fix unit tests 2015-04-24 16:47:27 +02:00
jknockaert 49df8ef525 Update encryption.php 2015-04-24 16:44:00 +02:00
jknockaert 238302ee7d fixed name 2015-04-24 16:44:00 +02:00
jknockaert 1756562501 Update encryption.php 2015-04-24 16:44:00 +02:00
jknockaert 735f6cc037 fix encryption header error
When moving back the pointer to position 0 (using stream_seek), the pointer on the encrypted stream will be moved to the position immediately after the header. Reading the header again (invoked by stream_read) will cause an error, writing the header again (invoked by stream_write) will corrupt the file. Reading/writing the header should therefore happen when opening the file rather than upon read or write. Note that a side-effect of this PR is that empty files will still get an encryption header; I think that is OK, but it is different from how it was originally implemented.
2015-04-24 16:43:16 +02:00
Joas Schilling 4334e77035 Merge pull request #15839 from owncloud/enc_fix_moving_shared_files
[encryption] fix moving files to a shared folder
2015-04-24 15:07:36 +02:00
Joas Schilling 1592be117a Use public interfaces for type hinting 2015-04-24 13:06:03 +02:00
Bjoern Schiessle 24128d1384 only update share keys if the file was encrypted 2015-04-24 10:19:09 +02:00
Bjoern Schiessle 2646bccb83 update share keys if file gets copied 2015-04-23 17:18:48 +02:00
Bjoern Schiessle 2990b0e07e update share keys if a file is moved to a shared folder 2015-04-23 17:18:48 +02:00
Thomas Müller b1bb6a3d36 Ignore test folders when checking the code for compliance 2015-04-23 16:59:26 +02:00
Lukas Reschke ab9ea97d3a Catch not existing User-Agent header
In case of an not sent UA header consider the client as valid
2015-04-23 16:33:51 +02:00
Lukas Reschke 155ae44bc6 Fix collision on temporary files + adjust permissions
This changeset hardens the temporary file and directory creation to address multiple problems that may lead to exposure of files to other users, data loss or other unexpected behaviour that is impossible to debug.

**[CWE-668: Exposure of Resource to Wrong Sphere](https://cwe.mitre.org/data/definitions/668.html)**
The temporary file and folder handling as implemented in ownCloud is performed using a MD5 hash over `time()` concatenated with `rand()`. This is insufficiently and leads to the following security problems:
The generated filename could already be used by another user. It is not verified whether the file is already used and thus temporary files might be used for another user as well resulting in all possible stuff such as "user has file of other user".

Effectively this leaves us with:

1. A timestamp based on seconds (no entropy at all)
2. `rand()` which returns usually a number between 0 and 2,147,483,647

Considering the birthday paradox and that we use this method quite often (especially when handling external storage) this is quite error prone and needs to get addressed.

This behaviour has been fixed by using `tempnam` instead for single temporary files. For creating temporary directories an additional postfix will be appended, the solution is for directories still not absolutely bulletproof but the best I can think about at the moment. Improvement suggestions are welcome.

**[CWE-378: Creation of Temporary File With Insecure Permissions](https://cwe.mitre.org/data/definitions/378.html)**

Files were created using `touch()` which defaults to a permission of 0644. Thus other users on the machine may read potentially sensitive information as `/tmp/` is world-readable. However, ownCloud always encourages users to use a dedicated machine to run the ownCloud instance and thus this is no a high severe issue. Permissions have been adjusted to 0600.

**[CWE-379: Creation of Temporary File in Directory with Incorrect Permissions](https://cwe.mitre.org/data/definitions/379.html)**

Files were created using `mkdir()` which defaults to a permission of 0777. Thus other users on the machine may read potentially sensitive information as `/tmp/` is world-readable. However, ownCloud always encourages users to use a dedicated machine to run the ownCloud instance and thus this is no a high severe issue. Permissions have been adjusted to 0700.Please enter the commit message for your changes.
2015-04-23 15:07:54 +02:00
Martin 676e86b314 Improve error messge text for app upgrade try (#15375) 2015-04-22 13:24:11 +02:00
Morris Jobke 3e8f6cdba9 Merge pull request #15635 from owncloud/issue/15634-empty-txt-previews
Scale up the font on larger previews
2015-04-20 15:55:32 +02:00
Morris Jobke ce2c8533d9 Merge pull request #15735 from owncloud/fix-visibility
Fix visibility of interfaces in \OCP
2015-04-20 14:39:15 +02:00
Lukas Reschke 3959f8ac4e Merge pull request #15637 from owncloud/migrate-certificate-stuff
Migrate personal certificate handling to AppFramework controllers
2015-04-20 13:56:35 +02:00
Lukas Reschke e9d6807c5c Merge pull request #15733 from owncloud/remove-oc_backgroundjob
Removed OC_BackgroundJob - reduce class overhead
2015-04-20 13:17:58 +02:00
Lukas Reschke 1cc2aefa46 Proper return types 2015-04-20 13:00:02 +02:00
Lukas Reschke 9f61cf60d4 Verify if returned object is an array
The error has to be thrown at this point as otherwise errors and notices are thrown since the time cannot be parsed in L60 and L61
2015-04-20 12:58:57 +02:00
Lukas Reschke ed0b465cf9 Use 403 instead a 50x response 2015-04-20 12:53:40 +02:00
Joas Schilling 6da9e1a742 Fix visibility of public API methods 2015-04-20 12:52:40 +02:00
Lukas Reschke 4ea205e262 Block old legacy clients
This Pull Request introduces a SabreDAV plugin that will block all older clients than 1.6.1 to connect and sync with the ownCloud instance.

This has multiple reasons:

1. Old ownCloud client versions before 1.6.0 are not properly working with sticky cookies for load balancers and thus generating sessions en masse
2. Old ownCloud client versions tend to be horrible buggy

In some cases we had in 80minutes about 10'000 sessions created by a single user. While this change set does not really "fix" the problem as 3rdparty legacy clients are affected as well, it is a good work-around and hopefully should force users to update their client
2015-04-20 11:12:17 +02:00
Lukas Reschke a98b819366 Add version to deprecation notice
As requested by @MorrisJobke
2015-04-20 10:30:16 +02:00
Lukas Reschke f672e120fc Deprecate unused `\OCP\Response::sendFile`
This function is unused in our own code and can be better achieved using the AppFramework. Also very easy to do grave mistaked using this function.
2015-04-20 10:02:34 +02:00
Morris Jobke 9cb260d310 Merge pull request #15717 from owncloud/issue/15716-fixing-ocp-api-namespace-usage
Fixing OCS API namespace usage
2015-04-20 09:43:19 +02:00
Morris Jobke d4ac7ac723 Merge pull request #15739 from DavidPrevot/symfony-2.7
Replace `_method` requirement by {g,s}etMethods()
2015-04-19 23:46:21 +02:00
Georg Ehrke 8f51efc49e get rid of OC_Geo 2015-04-19 20:16:56 +02:00
David Prévot 7f2f92847b Replace `_method` requirement by {g,s}etMethods()
Make the call compatible with future Symfony version, and avoid
E_USER_DEPRECATED as thrown by the current 2.7.0-beta1:

The "_method" requirement is deprecated since version 2.2 and will be
removed in 3.0. Use getMethods() instead. at
…/Symfony/Component/Routing/Route.php#554

The "_method" requirement is deprecated since version 2.2 and will be
removed in 3.0. Use the setMethods() method instead or the "methods"
option in the route definition. at
…/Symfony/Component/Routing/Route.php#662
2015-04-19 12:08:29 -04:00
Robin McCorkell 80b892e7ed Merge pull request #15729 from owncloud/remove-unused-variables
Remove unused variables
2015-04-19 12:38:29 +01:00
Morris Jobke 60b8aa2a83 Removed OC_BackgroundJob - reduce class overhead
* method code is now in the static public namespace (5 sloc)
2015-04-18 23:37:32 +02:00
Thomas Müller cdf82909b8 Merge pull request #15718 from owncloud/issue/15694-display-name-of-encryption-modules
Issue/15694 display name of encryption modules
2015-04-18 22:51:15 +02:00
Thomas Müller d2a31bcd93 Merge pull request #15727 from owncloud/cleanup-db-interface
DB: remove unused parameter - was forgotten during the migration to doct...
2015-04-18 22:47:40 +02:00
Morris Jobke e837927ad5 fix followup issues with unneeded parameters 2015-04-18 17:02:39 +02:00
Morris Jobke ccf47f40aa Remove unused variables
* should make scrutinizer a lot more happy
* reduces maybe memory footprint
2015-04-18 16:35:19 +02:00
Morris Jobke 47ecfd98a3 DB: remove unused parameter - was forgotten during the migration to doctrine
* 377e9a8677 <- doctrine merge
2015-04-18 15:57:13 +02:00
Morris Jobke 11f29f6d95 add visibility of methods in server container and interface 2015-04-18 14:19:22 +02:00
Joas Schilling 3f3f8c2f99 Fix usage of deprecated private constants 2015-04-18 10:30:02 +02:00
Joas Schilling 4d238c3949 Fix display name of encryption modules 2015-04-18 10:18:58 +02:00
Joas Schilling 6ce1abfa5c Deprecate the OC_API constants in favor of the OCP ones 2015-04-18 09:29:52 +02:00
Morris Jobke 7ab1f807fb Merge pull request #15691 from owncloud/vobject-sabre2.1
Get rid of the obsolete OC_VObject class
2015-04-17 22:33:00 +02:00
Thomas Müller d9990c2b4e Delay initialization of the OC\Encryption\Update - introducing 'OC\Encryption\HookManager' 2015-04-17 13:55:31 +02:00
Vincent Petry b7e5884b54 Get rid of the obsolete OC_VObject class
The class isn't needed any more since the update to Sabre 2.1
2015-04-17 12:55:31 +02:00
Bjoern Schiessle 7d4b1b52d0 always create a new instance of the encryption module 2015-04-17 10:31:33 +02:00
Clark Tomlinson 1174ad0681 Merge pull request #15445 from owncloud/enc2_migration
add migration script from old encryption to new one
2015-04-16 09:34:47 -04:00
Joas Schilling c7e5e30b86 Merge pull request #15674 from owncloud/fix-console-check-output
Convert error and hint to string before writing to the output
2015-04-16 14:51:29 +02:00
Bjoern Schiessle b25c06f576 detect system wide mount points correctly 2015-04-16 14:15:04 +02:00
Bjoern Schiessle 67500d5f2f if we start writing a file from the beginning, size should start by zero; result of floor needs to be casted to int in order to compare it with ->size 2015-04-16 14:15:04 +02:00
Bjoern Schiessle e3d77c4b01 add migration script from old encryption to new one 2015-04-16 14:15:04 +02:00
Thomas Müller 07243f0482 Convert error and hint to string before writing to the output - fixes https://mailman.owncloud.org/pipermail/devel/2015-April/001184.html 2015-04-16 12:32:17 +02:00
Thomas Müller bcf65d9c13 Using TRANSACTION_READ_COMMITTED 2015-04-16 11:49:12 +02:00
Jörn Friedrich Dreyer 2e06cf49a5 Merge pull request #15623 from t3chguy/master
Redis DB Index via Select
2015-04-16 09:30:07 +02:00
Vincent Petry 903d52d45f Merge pull request #15809 from owncloud/view-null-root
dont allow using null as view root
2015-04-22 18:10:26 +02:00
Robin Appelman bd57902d1d typo 2015-04-22 16:24:37 +02:00
Thomas Müller 750f0bc489 Merge pull request #15799 from owncloud/fix-enc-folder-move
Fix enc folder move
2015-04-22 16:04:29 +02:00
Robin Appelman f391f88d7f dont allow using null as view root 2015-04-22 14:51:02 +02:00
Morris Jobke 42d9ba0f83 Merge pull request #15787 from owncloud/trash-partfiles
Do not trash part files, delete directly
2015-04-22 14:10:26 +02:00
Morris Jobke a971fa8a90 Merge pull request #15549 from owncloud/jcf-fix-cache-update
don't update identical values
2015-04-22 13:34:08 +02:00
Thomas Müller 0042bdd2e7 fix PHPDoc 2015-04-22 13:12:52 +02:00
Thomas Müller 225cde2183 pass KeyStorage via ctor 2015-04-22 13:09:42 +02:00
Thomas Müller 987bc138df calling renameKeys() on directory level as well - fixes #15778 2015-04-22 12:12:27 +02:00
Thomas Müller fc4127dd62 add $encryptionModuleId to methods of Keys/IStorage 2015-04-22 11:53:05 +02:00
Björn Schießle 570718fb6b Merge pull request #15757 from owncloud/enc-fixfeofforlastblock
Fix encryption feof to not return too early
2015-04-22 11:32:21 +02:00
Vincent Petry ffc796edcb Do not trash part files, delete directly 2015-04-21 18:28:15 +02:00
Bjoern Schiessle 19e8c4fcb1 get dirname from sharePath 2015-04-21 14:58:01 +02:00
Björn Schießle b0fcf0fa0e Merge pull request #15636 from owncloud/enc2_performance_improvement
[encryption2] set size and unencrypted size to zero at the beginning of a write operation
2015-04-21 11:01:33 +02:00
Vincent Petry a13088818a Merge pull request #15748 from owncloud/fixing-enc-filesize-once-more
Introduce Storage::getData() to allow storage implementations more contr...
2015-04-20 18:36:23 +02:00
Vincent Petry 76dad297ff Fix encryption feof to not return too early
This is because stream_read will pre-cache the next block which causes
feof($this->source) to return true prematurely. So we cannot rely on it.

Fixed encryption stream wrapper unit tests to actually simulate 6k/8k
blocks to make sure we cover the matching logic.

Added two data files with 8192 and 8193 bytes.
2015-04-20 18:32:40 +02:00
Lukas Reschke fe2cbc3795 Merge pull request #15744 from owncloud/fix-inverted-path-in-resourcenotfound
Fix wrong path generation
2015-04-20 16:55:36 +02:00
Thomas Müller 32995ace1c move permission related code into getMetaData() 2015-04-20 16:50:12 +02:00
Thomas Müller 23f1bdc3d4 Introduce Storage::getMetaData() to allow storage implementations more control over the data array 2015-04-20 14:54:54 +02:00
Thomas Müller 92b60e36de Introduce Storage::getData() to allow storage implementations more control over the data array 2015-04-20 14:25:39 +02:00
Bjoern Schiessle 7fe0e09d14 set size and unencrypted size to zero on fopen 2015-04-20 11:06:13 +02:00
Morris Jobke 80be3b0c47 Fix wrong path generation
* fixes #15742
2015-04-20 11:01:33 +02:00
Michael Telatynski 8ebf9de3f8 Memcache\Redis Add DB Select Functionality 2015-04-15 21:24:38 +01:00
Joas Schilling 1592f25ed0 Scale up the font on larger previews 2015-04-15 14:03:40 +02:00
Morris Jobke e33e5b425a Merge pull request #12006 from owncloud/dav-put-storage
Work directly on the storage when uploading over webdav
2015-04-15 03:08:52 +02:00
Thomas Müller 70480423ff Merge pull request #15597 from oparoz/another-fallback-for-findbinarypath
Adding a final fallback for findBinaryPath
2015-04-15 00:16:56 +02:00
Thomas Müller 1aa368effe Merge pull request #15592 from owncloud/fix-15590-master
Avoid php message "Invalid argument supplied for foreach()"
2015-04-15 00:14:08 +02:00
Björn Schießle 4f0437fbde Merge pull request #15598 from owncloud/fix-enc-file-size-master
Fix file size of encrypted files
2015-04-14 16:48:04 +02:00
Robin Appelman eeecca04e6 Keep phpdoc updated. 2015-04-14 16:25:52 +02:00
Robin Appelman 308af8b909 pass a stream to the tests 2015-04-14 15:25:52 +02:00
Morris Jobke 82cab25762 Merge pull request #13360 from owncloud/cross-storage-move
Proper copy/move between multiple local storages
2015-04-14 14:35:08 +02:00
Olivier Paroz bb0c09e994 Adding a final fallback for findBinaryPath 2015-04-14 14:06:58 +02:00
Thomas Müller 967e882757 return size from cache in case the cache entry is marked as encrypted 2015-04-14 13:08:59 +02:00
Thomas Müller 387984a0d5 preserve filesize on rename after upload 2015-04-14 12:27:12 +02:00
Thomas Müller 88cc52c408 Avoid php message "Invalid argument supplied for foreach()" - refs #15590 2015-04-14 11:00:20 +02:00
Morris Jobke 5f66f867b6 Merge pull request #15581 from owncloud/deduplicate-oc-repair-namespace
Fix namespace duplication and other issues in repairlegacystorages
2015-04-13 21:51:38 +02:00
Morris Jobke 9eff199a17 Merge pull request #15360 from owncloud/cross-storage-move-cache
Preserve cache data when doing a cross storage move
2015-04-13 21:48:30 +02:00
Robin Appelman f605c98531 Fix cross storage move with shared storages 2015-04-13 17:10:05 +02:00
Robin Appelman addfafd9da Fix moving mount points 2015-04-13 17:10:02 +02:00
Robin Appelman caadc8cdd9 reuse cache move logic 2015-04-13 17:10:01 +02:00
Robin Appelman d7b3a1a35a preserve cache data when doing a cross storage move 2015-04-13 17:10:01 +02:00
Joas Schilling 71de1d58cd Fix namespace duplication and other issues in repairlegacystorages 2015-04-13 16:34:10 +02:00
Thomas Müller 660aa7ff1e Merge pull request #15568 from owncloud/cache_user_folder_for_file_search_results
cach user folder for file search results
2015-04-13 15:16:07 +02:00
Robin Appelman c29419e6d7 fix rebase issue 2015-04-13 15:13:03 +02:00
Robin Appelman 0772e3b4c1 Properly handle copy/move failures in cross storage copy/move 2015-04-13 15:13:03 +02:00
Robin Appelman 404773940d Detect storage full when doing cross storage copy/move 2015-04-13 15:13:03 +02:00
Robin Appelman d26c6cab90 properly return false if we cant delete the source file 2015-04-13 15:13:03 +02:00
Robin Appelman c4ec8fbeff Make getSourcePath accessible for storage wrappers 2015-04-13 15:13:03 +02:00
Robin Appelman 31e94708f8 Improve cross storage copy between local storages 2015-04-13 15:13:02 +02:00
Robin Appelman 8575bb2cb9 Move cross storage copy logic to the storage 2015-04-13 15:13:02 +02:00
Robin Appelman b302592a64 Small cleanup of rename code 2015-04-13 15:11:03 +02:00
Robin Appelman 2fd44dbde4 rewind and update error message 2015-04-13 14:14:48 +02:00
Robin Appelman dcfe014103 use our own stream copy instead 2015-04-13 14:13:21 +02:00
Vincent Petry 2822d0579e Properly add trailing slash to mount point
Fixes resolving mount points when shared mount point's target name has
the same prefix as the source name
2015-04-13 12:36:47 +02:00
Jörn Friedrich Dreyer b717681e3a cach user folder for file search results 2015-04-13 11:29:10 +02:00
Morris Jobke c3fbc2b6fd Merge pull request #15563 from owncloud/fix-try-getting-propert-of-non-object-ocsclient
Prevent php message: "Trying to get property of non-object at /xxx/lib/p...
2015-04-13 10:30:31 +02:00
Thomas Müller 906b6b7337 Prevent php message: "Trying to get property of non-object at /xxx/lib/private/ocsclient.php#282" 2015-04-13 09:43:45 +02:00
Thomas Müller 8450b6aa2d Properly import used classes 2015-04-13 09:26:30 +02:00
Lukas Reschke 84041a4fa2 Merge pull request #15541 from owncloud/add-reply-to-support
Add "Reply-To" support for sharing mails as well as refactor code and add unit-tests
2015-04-12 22:30:35 +02:00
Jens-Christian Fischer 9c95315a9e clarify the duplication of the $params array 2015-04-12 14:49:18 +02:00
Jens-Christian Fischer 22c6216f5c don't update identical values
The UPDATE oc_filecache statement blindly overwrites identical data.
Databases like Postgres that create a new row on an update
and mark the old one as dead will suffer from the previous
behaviour, as millions of "new" rows are created in the database.

This patch changes the WHERE clause to test for identical
values and not updating if the values in the DB are identical
to the ones being passed.
2015-04-11 18:06:21 +02:00
Lukas Reschke e3ad99d252 Add "Reply-To" support to sharing mails and refactor code 2015-04-10 17:30:07 +02:00
Lukas Reschke 77afef328d Merge pull request #15458 from owncloud/web-shell-master
Move console application to it's own class - allows reuse in the web shell
2015-04-10 16:33:01 +02:00
Vincent Petry e512a69a59 Merge pull request #15395 from owncloud/fix-imagepath
Fix UrlGenerator::imagePath() for app paths
2015-04-10 16:11:57 +02:00
Thomas Müller 7b2d53603c Merge pull request #15489 from owncloud/dont_hide_exceptions_master
Dont hide exceptions master
2015-04-10 15:49:45 +02:00
Lukas Reschke a881218fc2 Add "Reply-To" support for mails 2015-04-10 15:05:34 +02:00
Morris Jobke 25dd4ec767 Throw ServerNotAvailableException always 2015-04-10 14:51:21 +02:00
Thomas Müller a163243e31 Merge pull request #15510 from owncloud/cron-singleuser
block cron when in single user mode
2015-04-10 14:38:50 +02:00
Vincent Petry 73afca6207 Catch more exceptions when connecting to remote DAV server
Added InvalidArgumentException to catch HTML parsing errors when XML was
expected.
Made convertSabreException more generic to be able to handle more
exception cases.
2015-04-10 12:02:06 +02:00
Jörn Friedrich Dreyer fafecd1c05 fix cherrypicking 2015-04-10 11:08:24 +02:00
Jörn Friedrich Dreyer b069f33a72 throw exception when backends don't provide a user instead of creating legacy local storages 2015-04-10 09:12:37 +02:00
Morris Jobke 5626a02d69 throw exception if setup is incomplete 2015-04-10 09:12:37 +02:00
Thomas Müller 5abbf6d5b0 Merge pull request #13920 from owncloud/sharing_no_user_entry_for_group_shares
only create a db entry for the user in case of a name conflict on group share
2015-04-09 23:37:02 +02:00
Morris Jobke de4a81f462 Merge pull request #15517 from owncloud/fixRenameFailDeleteTargetKeepSource
fixes #15326
2015-04-09 18:41:18 +02:00
Thomas Müller f7c906902a Throw an exception in case checkServer() returns errors 2015-04-09 16:42:34 +02:00
Lukas Reschke b60d5d3d6f Merge pull request #14540 from owncloud/windows-setup-check
Disallow Windows Server in Server Check
2015-04-09 16:38:11 +02:00
Thomas Müller 890a18e1a6 Introduce own console application class 2015-04-09 16:28:53 +02:00
Robin Appelman 8af106cc75 block webdav in single user mode 2015-04-09 15:56:41 +02:00
Lukas Reschke 0abce86b31 Disallow Windows Server in Server Check
Will prevent users from use ownCloud on Windows Server 🙈
2015-04-09 15:56:37 +02:00
Jörn Friedrich Dreyer 8af52e3876 fixes #15326 2015-04-09 15:37:00 +02:00
Björn Schießle 0710db77bc Merge pull request #13896 from owncloud/share-generatetarget-remove-exclude
Dont create exclude list for generating the share target
2015-04-09 14:51:15 +02:00
Robin Appelman cbcee34eb0 update tests 2015-04-09 14:46:25 +02:00
Thomas Müller 1d9bd3d31e Merge pull request #15496 from owncloud/enc-check-if-key-exists-before-deleting
Check if the key exists, before trying to delete it
2015-04-09 14:45:40 +02:00
Bjoern Schiessle 332ea77865 only create a db entry for the user in case of a name conflict on group share 2015-04-09 11:16:08 +02:00
Joas Schilling 45575d0135 Check if the key exists, before trying to delete it 2015-04-09 10:28:02 +02:00
Lukas Reschke ba52f6f8fc Merge pull request #15314 from owncloud/app-categories-15274
Add different trust levels to AppStore interface
2015-04-09 10:07:32 +02:00
Morris Jobke 9c76d068c3 Merge pull request #15196 from owncloud/limit-file-activities-to-favorites
Limit file activities to favorites
2015-04-09 00:18:31 +02:00
Morris Jobke f3ef17a963 Merge pull request #15490 from owncloud/remove-debug-logging
remove unessesary logging of methods instantiation
2015-04-08 21:42:47 +02:00
Morris Jobke 4e60b81264 Merge pull request #14120 from owncloud/dav-statcache
Stat cache for DAV storage, improves s2s performance a little bit
2015-04-08 21:09:28 +02:00
Clark Tomlinson 3ffb2d8abd remove unessesary logging of methods instantiation 2015-04-08 14:46:01 -04:00
Bjoern Schiessle c379557e1d don't throw exception if a file gets uploaded and encryption is disabled 2015-04-08 16:41:20 +02:00
Morris Jobke 103d451459 Merge pull request #14987 from rullzer/ocs_password_fix2
OCS Fixes to allow setting of password without removing additional settings
2015-04-08 14:44:17 +02:00
Robin Appelman 6a59502759 Work directly on the storage when uploading over webdav 2015-04-08 14:04:58 +02:00
Morris Jobke 59322a5037 Merge pull request #15333 from owncloud/copy-cross-device
fix copying folder across devices
2015-04-08 12:35:15 +02:00
Morris Jobke 6c327f8331 Merge pull request #14879 from oparoz/fix-preview-caching
Introducing the maximum size preview
2015-04-07 18:16:24 +02:00
Thomas Müller a4483243ac fixing license headers - encryption code related 2015-04-07 17:02:49 +02:00
Olivier Paroz 74bf9806b0 Introducing the maximum size preview
The first time we're asked to generate a preview we'll generate one of the maximum dimension indicated in the configuration and all future resizing requests will be done on that preview in order to not waste time converting the same file over and over.

One of the fixes required for #12465
2015-04-07 16:45:59 +02:00
Thomas Müller 161d80da5b In case of encryption exceptions we return 503 - this will allow the client to retry 2015-04-07 14:17:42 +02:00
Lukas Reschke dd7c491bff Fix PHPDoc 2015-04-07 13:49:16 +02:00
Lukas Reschke a2182cde90 Deduplicate code 2015-04-07 13:48:33 +02:00
Thomas Müller 4a70ca665c respect mount option while encrypting 2015-04-07 13:30:31 +02:00
Thomas Müller 111fbabfb4 PHPDoc cleanup - clean code \o/ 2015-04-07 13:30:31 +02:00
Thomas Müller 69e95531f8 comment change as it broke unit tests 2015-04-07 13:30:31 +02:00
Thomas Müller ba9a797eaa Encryption storage wrapper is enabled by default - necessary to detect encrypted files even if encryption was disabled after files have been encrypted - prevents data corruption 2015-04-07 13:30:31 +02:00
Bjoern Schiessle 3d7404fe68 add unit tests to the keystorage 2015-04-07 13:30:31 +02:00
Bjoern Schiessle fe74a0cb4f implement webdav copy 2015-04-07 13:30:31 +02:00
Thomas Müller 8991272269 Using stream_get_contents in file_get_contents implementation + close handle 2015-04-07 13:30:31 +02:00
jknockaert ff16e3dbff Adjusting count on read 2015-04-07 13:30:31 +02:00
jknockaert 02404a6a8c Fixing encryption stream wrapper seek - thanks @jknockaert 2015-04-07 13:30:30 +02:00
Thomas Müller 104d11ec4c Fixing encryption storage wrapper tests 2015-04-07 13:30:30 +02:00
Thomas Müller d9c41b00ab Introducing trait LocalTempFileTrait 2015-04-07 13:30:30 +02:00
Bjoern Schiessle fac7ec3fc4 fix re-shares with encryption 2015-04-07 13:30:30 +02:00
Thomas Müller 8ffa6db110 fixing unit tests for stream wrapper 2015-04-07 13:30:30 +02:00
Thomas Müller 9d8c07850d fixing unencrypted file size 2015-04-07 13:30:30 +02:00
Bjoern Schiessle a74ee67476 don't wrap share storages 2015-04-07 13:30:30 +02:00
Thomas Müller 664b2bb7af cleaning up exception mess 2015-04-07 13:30:30 +02:00
Thomas Müller c9d6ed3d7d in case the file exists we require the explicit module as specified in the file header - otherwise we need to fail hard to prevent data loss on client side 2015-04-07 13:30:30 +02:00
Bjoern Schiessle 51302d5812 getUidAndFilename() always get uid from path 2015-04-07 13:30:30 +02:00
Thomas Müller cac83642f2 Finally fixing encryption with public share 2015-04-07 13:30:30 +02:00
Thomas Müller a57918fb10 Hook: fixing error message in exception case 2015-04-07 13:30:30 +02:00
Thomas Müller 137c135664 file_put_contents has to return the number of written bytes 2015-04-07 13:30:30 +02:00
Thomas Müller f20844ac89 PHPDoc 2015-04-07 13:30:30 +02:00
Bjoern Schiessle 83cb382b3f pass file helper to encryption wrapper 2015-04-07 13:30:29 +02:00
Bjoern Schiessle e4895bda01 add helper class accessible for encryption modules to ask for a list of users with access to a file, needed to apply the recovery key to all files 2015-04-07 13:30:29 +02:00
Thomas Müller a98b7dbf6f Fix double registration of encryption module 2015-04-07 13:30:29 +02:00
Thomas Müller 4db75e3407 Setting up the encryption wrapper in a setup hook - temporarily fixes the wrapping order 2015-04-07 13:30:29 +02:00
Thomas Müller bf809ac85a Removing left overs from old encryption app 2015-04-07 13:30:29 +02:00
Thomas Müller 6ccd3ffa23 adding function getSecureRandom(); to IServerContainer 2015-04-07 13:30:29 +02:00
Bjoern Schiessle 0f28d538a0 add session class to handle all session operations 2015-04-07 13:30:28 +02:00
Thomas Müller 1b42b492dc kill OC_FileProxy 💥 2015-04-07 13:30:28 +02:00
Thomas Müller dbdd754c3f Further cleanup of files_encryption 2015-04-07 13:30:28 +02:00
Thomas Müller 00338f9dca Removing files_encryption left overs 2015-04-07 13:30:28 +02:00
Thomas Müller 99255ff3a9 Fix - public sharing: in case on user is available - get it from the path 2015-04-07 13:30:28 +02:00
Bjoern Schiessle 0eee3a2618 remove unencrypted_size from the cache, size will contain the unencrypted size 2015-04-07 13:30:28 +02:00
Thomas Müller d185761d31 initializing some variables + update size after writing the headers 2015-04-07 13:30:28 +02:00
Thomas Müller 4441835d18 https://github.com/owncloud/core/pull/15305#discussion_r27382305
Conflicts:
	lib/private/files/stream/encryption.php
2015-04-07 13:30:28 +02:00
Thomas Müller 90487384f7 initializing some variables 2015-04-07 13:30:28 +02:00
Bjoern Schiessle 0c48b069ba call end() before closing the file 2015-04-07 13:30:28 +02:00
Thomas Müller 498625ea3a adding unit tests for stream wrapper 2015-04-07 13:30:28 +02:00
Thomas Müller a905f641b3 various fixes & start to unit test the encryption storage wrapper 2015-04-07 13:30:28 +02:00
jknockaert 3e6eb28ee3 Applying diff as of https://github.com/owncloud/core/pull/15303 2015-04-07 13:30:28 +02:00
Bjoern Schiessle a85e2e0bfd make recovery settings work 2015-04-07 13:30:28 +02:00
Bjoern Schiessle 937efe856d fix lib/private/encryption/util.php call 2015-04-07 13:30:28 +02:00
Bjoern Schiessle c266b3b5b7 remove debug code from core 2015-04-07 13:30:28 +02:00
Bjoern Schiessle c64e0af4fb check if recovery key exists and encrypt the file with the recovery key if needed 2015-04-07 13:30:28 +02:00
Bjoern Schiessle 2244ea998d core: documentation fixes 2015-04-07 13:30:27 +02:00
Bjoern Schiessle cb9980823d core: small fixes 2015-04-07 13:30:27 +02:00
Bjoern Schiessle 810ca9105c implement rename and delete of encryption keys 2015-04-07 13:30:27 +02:00
Clark Tomlinson 0c2f9ca849 Updating keystorage movement and fixing hooks 2015-04-07 13:30:27 +02:00
Bjoern Schiessle 506222567e add deleteKey methods to key storage 2015-04-07 13:30:27 +02:00
Bjoern Schiessle e2f714263f fix encryption manager to handle more than one encryption module 2015-04-07 13:30:27 +02:00
Bjoern Schiessle 5bc9ababeb fix keystorage and add unit tests 2015-04-07 13:30:27 +02:00
Clark Tomlinson 39733c8da1 Initial commit 2015-04-07 13:30:27 +02:00
Bjoern Schiessle 63e7fe608a create basic interfaces and wrapper to make encryption more modular 2015-04-07 13:30:27 +02:00
Joas Schilling 3bde7c2f67 When guessing the timezone, the offset might only be valid on a given timestamp 2015-04-07 10:13:06 +02:00
Robin McCorkell fbb84a518f Fix UrlGenerator::imagePath() for app paths 2015-04-03 23:42:18 +01:00
Thomas Müller 3bf269e565 Merge pull request #15229 from owncloud/response-setContentLengthHeader
Add OC_Response::setContentLengthHeader() for Apache PHP SAPI workaround...
2015-04-03 22:51:36 +02:00
Thomas Müller b2b3e1ac94 Merge pull request #15391 from owncloud/fix-language-caching
fix caching of preferred language
2015-04-03 22:51:13 +02:00
Thomas Müller 3d2116dfe7 Merge pull request #15386 from oparoz/yaml-cnf-mediatype
Introducing media types for yml, yaml, cnf, conf
2015-04-03 22:49:41 +02:00
Robin Appelman 712e478cb2 fix caching of preferred language 2015-04-03 15:36:24 +02:00
Lukas Reschke 25531bad88 Make user names clickable 2015-04-03 13:36:03 +02:00
Lukas Reschke 0816cf9142 Add experimental applications switch
Allows administrators to disable or enabled experimental applications as well as show the trust level.
2015-04-03 13:21:24 +02:00
Morris Jobke a2087f30d1 Merge pull request #15383 from owncloud/fix-exception-message
Update exception messages to better reflect and describe the problem
2015-04-03 10:15:23 +02:00
Olivier Paroz 70ec74e88b Introducing media types for yml, yaml, cnf, conf 2015-04-02 21:37:57 +02:00
Lukas Reschke fa079a5959 Merge pull request #12314 from oparoz/patch-3
Make findBinaryPath compatible with open_basedir
2015-04-02 18:54:03 +02:00
Joas Schilling a8d1ede347 Fix the exception messages 2015-04-02 18:40:06 +02:00
Thomas Müller 9f58097e4d Merge pull request #14113 from owncloud/chunking-chunkpartfiles
Added part files for when writing chunks
2015-04-02 18:15:27 +02:00
Thomas Müller 4082436419 Merge pull request #15367 from owncloud/pre-setup-hook
setup storage wrappers before setting up the filesystem
2015-04-02 17:40:23 +02:00
Morris Jobke 1720fdf5f4 Merge pull request #15346 from oparoz/split-image-provider
Split image provider in one sub-class per media type
2015-04-02 13:40:09 +02:00
Robin Appelman f585994c4b setup mount manager before wrappers 2015-04-02 13:28:36 +02:00
Olivier Paroz 8ec6dfdbf8 Split image provider in one sub-class per media type 2015-04-02 10:31:24 +02:00
Morris Jobke 82f91c50c7 Merge pull request #15349 from oparoz/limit-bitmap-previews-2
The bitmap preview class now takes maxX and maxY into consideration
2015-04-02 10:23:55 +02:00
Thomas Müller 9e5b319ed4 Merge pull request #15362 from owncloud/issue/15359-purge-memcache-console-app-disable
Correctly purge the cache when an app is disabled via cli
2015-04-02 09:26:15 +02:00
Joas Schilling 696c750cfe Fix docs and line breaks 2015-04-02 08:28:42 +02:00
Robin Appelman 3cb53b7756 setup storage wrappers before setting up the filesystem 2015-04-01 17:12:06 +02:00
Olivier Paroz 1525ecd3dd The bitmap preview class now takes maxX and maxY into consideration
This is a fix for owncloud#13607 and is part of the global programme: owncloud#13609

The image aspect ratio is kept intact.
2015-04-01 15:54:22 +02:00
Joas Schilling d01cfde982 Correctly purge the cache when an app is disabled via cli 2015-04-01 15:43:38 +02:00
Roeland Jago Douma 288da619b1 Deprecate functions that only call the urlgenerator anyway 2015-04-01 14:32:49 +02:00
Joas Schilling 730efe25a4 Make scrutinizer happy 2015-04-01 12:13:49 +02:00
Pierre Jochem a1828ff034 More secure proposal 2015-04-01 11:28:53 +02:00
Olivier Paroz 0f01de9f7e Use getenv to get the paths for `find` 2015-03-31 23:49:21 +02:00
Olivier Paroz 7c41c0c13f use ExecutableFinder and find in findBinaryPath
When using open_basedir, commands such as `which`or `command`can fail
because they might try to look outside of the restricted perimeter.
Symfony's ExecutableFinder can be used instead to look in standard
locations and we can use `find` as a last resort

A better solution would be to adopt a mechanism similar to what has
been done for office documents where a configuration parameter is used
to indicate the path where the executable is to be found.
2015-03-31 23:49:16 +02:00
Robin Appelman 068c624b0d fix copying folder across devices 2015-03-31 13:50:11 +02:00
Roeland Jago Douma 0bf06d6691 No injections 2015-03-30 20:07:12 +02:00
Morris Jobke bf17ac929d Merge pull request #15169 from rullzer/fix_displayNamesInGroup
Groupmanagers displayNamesInGroup should actually search in displaynames
2015-03-30 17:04:09 +02:00
Joas Schilling b95d12700c Add logic for getting the user from the rss token to the Manager 2015-03-30 15:23:09 +02:00
Roeland Jago Douma b0aa17b13f OCS Fixes to allow setting of password without removing additional settings
- Added setPassword to share.php
- Fixed OCS API call
- Added unit tests
2015-03-30 14:00:50 +02:00
Lukas Reschke 65202d2a18 Add check for activated local memcache
Also used the opportunity to refactor it into an AppFramework controller so that we can unit test it.

Fixes https://github.com/owncloud/core/issues/14956
2015-03-28 13:59:22 +01:00
Vincent Petry d3752ca1e9 Merge pull request #15289 from owncloud/min-upload-limit
Require minimum 1 MiB upload limit
2015-03-28 11:34:11 +01:00
Robin McCorkell ab991458ad Require minimum 1 MiB upload limit 2015-03-27 23:43:35 +00:00
Robin McCorkell 1511a42da7 Check for relative datadirectory path 2015-03-27 23:29:46 +00:00
Vincent Petry a32c71d25e Revert "Deprecated \OCP\IAppConfig - add missing methods to IConfig"
This reverts commit 012016d331.
2015-03-27 18:50:11 +01:00
Morris Jobke f4dc9e6bf3 Merge pull request #15155 from owncloud/share-donotreturntrashedfiles
Do not return shares for files outside "files"
2015-03-27 17:05:14 +01:00
Thomas Müller 4d12c4a38b Merge pull request #13938 from owncloud/deprecate-iappconfig
Deprecated \OCP\IAppConfig - add missing methods to IConfig
2015-03-27 16:07:41 +01:00
Thomas Müller 722e50a112 Merge pull request #15240 from owncloud/storage-wrapper-priority
add priority to storage wrappers
2015-03-27 15:18:44 +01:00
Thomas Müller 98bc1ad70a Merge pull request #15265 from owncloud/enc2_fixes
core improvements for Encryption 2.0
2015-03-27 14:58:33 +01:00
Morris Jobke e918bcf212 Merge pull request #15247 from owncloud/fix_group_share_master_backport
also call generateTarget for group shares
2015-03-27 14:40:52 +01:00
Vincent Petry 80f83ab5e0 Do not return shares for files outside "files" 2015-03-27 13:25:23 +01:00
Vincent Petry 7ad4dfa201 Merge pull request #15227 from owncloud/ocetag-header
Copy Etag header to OC-Etag for sabre calls
2015-03-27 13:10:27 +01:00
Bjoern Schiessle b5fad75e57 add deleteAllFileKeys to public interface and add "uid" as parameter for the
update call
2015-03-27 11:51:53 +01:00
Bjoern Schiessle c6be1ba8d3 fix check if a file is excluded from encryption or not 2015-03-27 11:51:50 +01:00
Morris Jobke a62f38a18b Merge pull request #15225 from owncloud/make-setups-for-users-that-tend-to-use-owncloud-on-not-proper-machines-a-little-bit-more-secure
Add some generic default headers as well via PHP
2015-03-27 09:54:40 +01:00
Lukas Reschke 9622fbdf29 Filter potential dangerous characters in path name
We should not allow / or \ in the postfix here.
2015-03-26 23:17:18 +01:00
Vincent Petry 670ca68453 Added stat cache for DAV storage
The stat cache stored known states of files/folders to avoid requerying
the DAV server multiple times.
2015-03-26 23:15:53 +01:00
Vincent Petry 746be98e03 Merge pull request #13654 from oparoz/tmpfile-with-extension
Keep the extension in temp files
2015-03-26 23:08:08 +01:00
Robin McCorkell c2909355bf Merge pull request #14925 from owncloud/ext-mountoptions-ui
Mount options GUI for external storage
2015-03-26 21:36:34 +00:00
Lukas Reschke 9d1ce53cb1 Add some generic default headers as well via PHP 2015-03-26 22:32:57 +01:00
Bjoern Schiessle 223cca2a07 also call generateTarget for group share to add the correct prefix if share_folder is defined in config.php 2015-03-26 22:31:45 +01:00
Morris Jobke e8109f0bc3 Merge pull request #13802 from owncloud/share-partfilepermissions
Fix share permission checks
2015-03-26 22:01:05 +01:00
Morris Jobke 4c00be4961 Merge pull request #14488 from owncloud/enhancement/security/inline-disposition
Serve all files with a Content-Disposition of 'attachment' via WebDAV
2015-03-26 21:45:30 +01:00
Robin Appelman cb9ead7dde add priority to storage wrappers 2015-03-26 21:26:38 +01:00
Thomas Müller 232518ac54 Merge pull request #15234 from owncloud/encryption2_core
core part of encryption 2.0
2015-03-26 21:14:59 +01:00
Bjoern Schiessle ff9c85ce60 implement basic encryption functionallity in core to enable multiple encryption modules 2015-03-26 20:56:51 +01:00
Lukas Reschke 8ebe667202 Remove unneeded argument 2015-03-26 20:45:39 +01:00
Lukas Reschke 74a9fc29b4 Merge pull request #14399 from owncloud/ignore-empty-plurals
Ignore empty plurals just like with singulars
2015-03-26 20:15:33 +01:00
Lukas Reschke 55fd0082aa Serve all files with a Content-Disposition of 'attachment' via WebDAV
As an additional security hardening it's sensible to serve these files with a Content-Disposition of 'attachment'. Currently they are served 'inline' and get a "secure mimetype" assigned in case of potential dangerous files.

To test this change ensure that:

- [ ] Syncing with the Desktop client still works
- [ ] Syncing with the Android client still works
- [ ] Syncing with the iOS client still works

I verified that the 1.8 OS X and iOS client still work with this change.
2015-03-26 20:01:05 +01:00
Lukas Reschke c8c722bc6d Merge pull request #15129 from owncloud/version-command-bus
expire versions in a background command
2015-03-26 19:55:13 +01:00
Morris Jobke 70e64822b9 Merge pull request #14665 from owncloud/fileid-increment
SQLite autoincrement test
2015-03-26 19:36:18 +01:00
Vincent Petry 58b4c2c0e5 Make sure mountOptions keep their data type
str_replace for $user substitution was converting the data type of
mountOptions to string. This fix prevents this to happen by making sure
only strings are processed by substitution.

Also added a int conversion when reading the watcher policy
2015-03-26 19:24:37 +01:00
Thomas Müller a8b756154a Merge pull request #14495 from owncloud/update-mailmap-01
Updating .mailmap
2015-03-26 17:17:18 +01:00
Robin Appelman 8c903c100f check limit of serialized command in unit tests 2015-03-26 17:07:02 +01:00
Robin Appelman 268f249e8d ensure commands can be serialized in unit tests 2015-03-26 17:07:02 +01:00
Robin Appelman ddd6a67d2a Handle exceptions thrown during hooks when running unit tests 2015-03-26 17:07:02 +01:00
Robin Appelman 3ed6ed3c36 Force test cases using background commands to handle setting up the filesystem 2015-03-26 17:07:02 +01:00
Andreas Fischer 0f58315543 Add OC_Response::setContentLengthHeader() for Apache PHP SAPI workaround.
Do not send Content-Length headers with a value larger than PHP_INT_MAX
(2147483647) on Apache PHP SAPI 32-bit. PHP will eat them and send 2147483647
instead.

When X-Sendfile is enabled, Apache will send a correct Content-Length header,
even for files larger than 2147483647 bytes. When X-Sendfile is not enabled,
ownCloud will not send a Content-Length header. This prevents progress bars
from working, but allows the actual transfer to work properly.
2015-03-26 16:37:38 +01:00
Joas Schilling 39dbf9509b Merge pull request #15224 from owncloud/issue/15191-app-code-checker-error-list
Correctly only send the errors of the current file to the event
2015-03-26 16:35:46 +01:00
Vincent Petry 70acd58336 Copy Etag header to OC-Etag for sabre calls 2015-03-26 16:06:43 +01:00
Joas Schilling db763027bb Correctly only send the errors of the current file to the event 2015-03-26 15:33:31 +01:00
Vincent Petry a84ade5f32 Revert "adding OC-ETag header"
This reverts commit 30ee8b6f99.
2015-03-26 15:04:41 +01:00
Vincent Petry daceb1a9ac Revert "adding unit tests"
This reverts commit 8d327c94a8.
2015-03-26 15:04:36 +01:00
Vincent Petry cda7f7fd61 Merge pull request #15168 from owncloud/oc-etag-master
adding OC-ETag header
2015-03-26 13:52:43 +01:00
Lukas Reschke 468456e168 Merge pull request #14125 from dratini0/master
[nginx] Extending X-Accel-Redirect support
2015-03-26 13:35:00 +01:00
Jenkins for ownCloud b585d87d9d Update license headers 2015-03-26 11:44:36 +01:00
Morris Jobke 20f5290462 Merge pull request #15195 from owncloud/reanimate-add-guzzle
Add wrapper for Guzzle
2015-03-26 11:06:48 +01:00
Vincent Petry f056558b72 Add repair step to fix SQLite autoincrement
Force Doctrine to generate alter table SQL statements for SQLite to make
sure the code from OCSqlitePlatform is triggered.
2015-03-26 11:00:22 +01:00
Thomas Müller 8d327c94a8 adding unit tests 2015-03-26 10:49:26 +01:00
Robin Appelman ac8254de6a Rename platform 2015-03-25 18:33:21 +01:00
Robin Appelman 24a30c10d7 Add custom sqlite platform to set auto increment 2015-03-25 18:33:21 +01:00
Lukas Reschke 5f044ebf1b Add wrapper for Guzzle 2015-03-25 16:04:41 +01:00
Andreas Fischer 630b7edc54 Do not use APCu when apc.enabled is Off. 2015-03-25 14:52:01 +01:00
Thomas Müller 43beaba0dc Merge pull request #15171 from owncloud/sabre-logforbiddenasdebug
Log forbidden in debug level
2015-03-24 23:31:35 +01:00
Lukas Reschke ec12f5e019 Merge pull request #14949 from owncloud/sabre-2.1.3
Update sabre-2.1.3 thirdparty submodule
2015-03-24 23:16:57 +01:00
Vincent Petry 72c1c89bcd Log forbidden in debug level 2015-03-24 22:08:11 +01:00
Thomas Müller 30ee8b6f99 adding OC-ETag header 2015-03-24 21:36:46 +01:00
Roeland Jago Douma abfb524b29 When searching for displayname then search for displayname 2015-03-24 21:35:44 +01:00
Lukas Reschke 5a9c9b86f8 Merge pull request #15153 from owncloud/uniquename-node
Add `getNonExistingName()` to the node api
2015-03-24 15:51:12 +01:00
Robin Appelman d11f01fa0f Add `getNonExistingName()` to the node api 2015-03-24 15:00:36 +01:00
Vincent Petry 331f0196e0 Merge pull request #15150 from owncloud/sabre-removerangeexceptionforencryption
Remove range header exception for encryption
2015-03-24 14:29:01 +01:00
Morris Jobke 92791bb8ba Merge pull request #15126 from owncloud/sabre-storagenotavailable
Soft fail in CustomPropertiesBackend whenever storage not available
2015-03-24 14:01:47 +01:00
Joas Schilling 5e71d1558a Merge pull request #15149 from owncloud/fix-enable-for-group
Correctly get array of groups and send OCP\IGroup objects to enable meth...
2015-03-24 13:50:56 +01:00
Vincent Petry 46475bf580 Merge pull request #15003 from owncloud/issue/14859-speed-up-favorite-list
Do not walk over the users directory, but over the list of tagged objects
2015-03-24 13:26:59 +01:00
jknockaert a1b68b5a48 Remove range header exception for encryption
revert #10422
2015-03-24 13:19:49 +01:00
Joas Schilling b262c30fa9 Correctly get array of groups and send OCP\IGroup objects to enable method 2015-03-24 12:56:42 +01:00
dratini0 d4e5ef4f38 Removed simplified X-accel-redirect even further 2015-03-23 17:51:12 +01:00
Vincent Petry eb894e6625 Soft fail in CustomPropertiesBackend whenever storage not available
When a storage is not available, it will not fail the whole call any
more but still return a usable file list.
2015-03-23 17:41:32 +01:00
Morris Jobke 0adcb99110 Merge pull request #14862 from owncloud/introduce-shipped.json-master
shipped apps are now defined in core/shipped.json - the shipped tag in i...
2015-03-23 17:17:33 +01:00
dratini0 c432b52c74 Changed the disputed while loop to a single if. 2015-03-23 16:12:03 +01:00
Joas Schilling 1a26263123 Do not walk over the users directory, but over the list of tagged objects
Way quicker
2015-03-23 15:10:58 +01:00
Olivier Paroz f3fe46685b Introducing 3D images support (media type)
So that people with 3D images can at least see a 2D picture
Full 3D support is possible via an app
2015-03-20 22:11:42 +01:00
Thomas Müller afa8872955 Merge pull request #14857 from owncloud/preview-provider-registration-in-manager
Preview provider registration in manager
2015-03-20 16:34:22 +01:00
Morris Jobke a45e45df1e Merge pull request #14941 from AdamWill/pipeline-apps
fall back to absolute path for pipelined assets (#14940)
2015-03-20 14:56:02 +01:00
Thomas Müller 0b1c4bfc3b Merge pull request #15062 from owncloud/fix-15053-master
Handle session initialization errors and display error page
2015-03-20 14:07:15 +01:00
Vincent Petry 67160e0861 Do not automatically add "update" permission to shared mounts
In the past it seems the update permission was needed to be able to
rename shared mounts, but it doesn't seem to be the case any more.

Removing the "update" permission that used to be added automatically
fixes the read-only permission check when trying to overwrite a
read-only file over WebDAV.
2015-03-20 12:33:59 +01:00
Thomas Müller 843fef0490 Handle session initialization errors and display error page - fixes #15053 2015-03-20 12:21:03 +01:00
Thomas Müller cce303ff5c Merge pull request #15047 from owncloud/connect-failed-exception-message
be a little more verbose in the exception message when we cant connect to...
2015-03-20 10:06:06 +01:00
Robin Appelman faa4918355 be a little more verbose in the exception message when we cant connect to the db 2015-03-20 03:56:38 +01:00
Robin Appelman 2df20aaffb show exception type in debug mode 2015-03-20 03:51:21 +01:00
Vincent Petry 5ba508b346 Fix permission checks in Sabre connector
This fixes moving files in and out of shared folders with some exotic
permission combinations.
2015-03-19 21:18:48 +01:00
Thomas Müller 857b22c61b Merge pull request #15025 from rullzer/ocs_respect_enforced_date
Ocs respect enforced date
2015-03-19 17:06:04 +01:00
Robin Appelman 73874ca27f Merge pull request #14704 from owncloud/storage-wrapper-mount
pass mountpoint to storage wrapper callback
2015-03-19 16:20:38 +01:00
Olivier Paroz f890c3ffb1 Make the method compatible with all types of extensions
Fix existing tests
2015-03-19 16:09:16 +01:00
Olivier Paroz 60b1643f02 Fix the office class
The office converter already replaces the original extension with '.pdf', so we need to switch the extensions of the tmp file instead of appending '.pdf' to it
2015-03-19 16:09:09 +01:00
Olivier Paroz 8d6b2b8867 Keep the extension in temp files
The file extension helps some applications like ImageMagick to properly
process files
2015-03-19 16:09:02 +01:00
Thomas Müller 0868e49663 Merge pull request #14980 from owncloud/fix-fileglobalgc
Fix fileglobalgc unlink parameter warnings
2015-03-19 14:17:20 +01:00
Roeland Jago Douma 3c39658a1c When the expiration date is enforced respect this
Make sure that we do not allow removing of the expiration date when this
is enforced in the settings.
2015-03-19 10:07:17 +01:00
Vincent Petry fe8002a7db Merge pull request #14995 from owncloud/remove-unrequired-backtick-removal
Remove unrequired backtick removal
2015-03-18 19:34:49 +01:00
Robin McCorkell 693ca9a92f Add unit tests for gc() for \OC\Cache\FileGlobalGC 2015-03-18 16:19:04 +00:00
Robin Appelman e2e16249a1 Merge pull request #14999 from owncloud/kill-fileoperations-proxy
kill fileoperations proxy
2015-03-18 15:42:00 +01:00
Lukas Reschke 7310575f07 Merge pull request #14994 from owncloud/sabre-customprops-softfail
Soft fail in custom properties backend
2015-03-18 15:39:35 +01:00
Robin Appelman 8f9ddef435 kill fileoperations proxy
check is now handled by storage backends
2015-03-18 15:04:28 +01:00
Morris Jobke 378eef7eb4 migrate share helper method to IConfig 2015-03-18 13:07:39 +01:00
Lukas Reschke bb5c5a3691 Remove unreqired backtick removal
Without this files with a ` (backtick) in the beginning of the filenames where simply not correctly referenced as the ` got removed. This can lead to all possible havoc situations.

Should get backported to stable8 and in future we might consider if it is really worth to backport such changes when it is just for SQLite 🙈

Regression of https://github.com/owncloud/core/pull/14734
2015-03-18 12:38:19 +01:00
Vincent Petry 50194c31b4 Soft fail in custom properties backend
This makes it possible for clients to still receive a file list (minus
the broken files) instead of getting no list at all
2015-03-18 12:36:37 +01:00
Lukas Reschke 917cb66a5b Use ArrayCache if ownCloud is not installed
If ownCloud has not been installed yet the prefix might otherwise change at this point quite some time and thus the cache runs havoc.

This made installing ownCloud impossible on systems where APCu or so was available. However, I was not able to reproduce the same problem for application upgrades so this patch seems to work fine for this situation as well.

Fixes itself.
2015-03-18 11:47:16 +01:00
Robin McCorkell 42fcd0e8b7 Fix fileglobalgc unlink parameter warnings 2015-03-18 00:07:18 +00:00
Thomas Müller c69cd28a73 Merge pull request #14968 from owncloud/files-reallowsinglequote
Reallow single quote in file names
2015-03-17 23:50:16 +01:00
Thomas Müller a4d2c7810e Merge pull request #14975 from owncloud/add-smtp-debug-mode
Add debug mode back to mailer
2015-03-17 23:49:19 +01:00
Lukas Reschke f13216d275 Use `FILTER_UNSAFE_RAW` instead of `FILTER_SANITIZE_STRING`
`FILTER_SANITIZE_STRING` will still encode everything else.
2015-03-17 21:56:16 +01:00
Bernhard Posselt 087117d87d Merge pull request #14961 from owncloud/onlyrequireinfo
Only hard depend on the info.xml and not the app.php
2015-03-17 21:27:51 +01:00
Robin McCorkell 760f5fc5e5 Merge pull request #14954 from owncloud/cache-image-path
Cache \OC\URLGenerator::imagePath
2015-03-17 19:36:23 +00:00
Lukas Reschke aea4b3166b Add debug mode back to mailer
This re-adds the debug mode for the mailer which will log the whole SMTP traffic within the log file if enabled.
2015-03-17 19:41:13 +01:00
Morris Jobke 012016d331 Deprecated \OCP\IAppConfig - add missing methods to IConfig 2015-03-17 17:19:33 +01:00
Bernhard Posselt 57ceed590a only hard depend on the info.xml and not the app.php
fix comment
2015-03-17 15:43:48 +01:00
Thomas Müller 6d5f52484e Merge pull request #14948 from owncloud/prefix-memcache
Add version and path to cache prefix
2015-03-17 13:39:22 +01:00
Lukas Reschke 1f4aa5350a Reuse cache result 2015-03-17 13:15:52 +01:00
Lukas Reschke 4f9b76d821 Read theme only if required 2015-03-17 12:47:46 +01:00
Lukas Reschke c233f2c90b Add version and path to cache prefix
Prevents to have the cache reused by other instances on the server which have possible the same instance ID and also invalidates older cache entries after an upgrade which can cause unwanted side-effects.

Impact for deployment: The same cache will only get used if ownCloud is installed with the same version and under the same path. But this should be a basic requirement anyways.
2015-03-17 12:39:49 +01:00
Lukas Reschke 9e2ebf2dce Cache \OC\URLGenerator::imagePath
\OC\URLGenerator::imagePath is a really expensive operation due to all the I/O handling and can really benefit from caching.
2015-03-17 12:35:47 +01:00
Vincent Petry 5ea8ab3bb0 Fix Principal connector override 2015-03-17 12:22:29 +01:00
Joas Schilling 9c45ab49a1 Use a closure for the files app entry and deprecate old methods 2015-03-17 12:17:09 +01:00
Thomas Müller 98a42dbccc Merge pull request #14927 from oparoz/raw-mimetypes
Introducing the Raw media types
2015-03-17 11:32:09 +01:00
Lukas Reschke e4c6b0abf5 Merge pull request #14931 from owncloud/issue/14881-closures-for-navigation-entries
Issue/14881 closures for navigation entries
2015-03-17 11:28:27 +01:00
Lukas Reschke b1c19f74a1 Merge pull request #12085 from owncloud/add-swift-mailer
Migrate OC_Mail to SwiftMailer
2015-03-17 11:15:39 +01:00
Adam Williamson fa1be7d296 fall back to absolute path for pipelined assets (#14940)
If the asset is, for example, in an apps directory that is
outside the $SERVERROOT, we won't be able to get a relative
path. We shouldn't just fail hard in this case. Fall back to
using the absolute path instead (as we used to).
2015-03-16 19:08:11 -07:00
Vincent Petry 7bc09f8f06 Fix setup config 2015-03-16 17:57:34 +01:00
Vincent Petry 6f687fa6ae Merge pull request #14923 from owncloud/fix-preference-key-definition
Fix user preference key definition for insertIfNotExists()
2015-03-16 17:14:09 +01:00
Thomas Müller 54e1edbf03 Merge pull request #13733 from mmattel/Try_to_write_logtimezone_during_installation
Write the parameter 'logtimezone' into config.php during setup
2015-03-16 17:04:06 +01:00
Olivier Paroz bef12488c3 Introducing the Raw mimetypes 2015-03-16 16:25:04 +01:00
Joas Schilling 970846624f Allow registering closures for navigation entries
This speeds up all pages that don't use the navigation by 0.04sec per app,
because we don't need to create the routing anymore, unless we really need to.
2015-03-16 16:17:43 +01:00
Joas Schilling c2a5bd6a01 Also add a note that clob does not work in the compare array 2015-03-16 15:41:00 +01:00
Joas Schilling 06b2446269 The key is over configkey, user and app, not the value
stupid me :(
2015-03-16 15:37:12 +01:00
Lukas Reschke d7c7808a5e Add debug log message back 2015-03-16 13:01:17 +01:00
Lukas Reschke e32f1582c7 Show more detailed error message 2015-03-16 12:47:06 +01:00
Lukas Reschke f92f3a1a6e Incorporate review changes 2015-03-16 12:47:05 +01:00
Lukas Reschke 13486a5ada Migrate to SwiftMail
Replaces the OC_Mail and phpmailer with SwiftMail allowing us to mock it properly.

Fixes the unit test execution on master on local machines and https://github.com/owncloud/core/issues/12014

Conflicts:
	3rdparty
	lib/private/server.php
	lib/public/iservercontainer.php
	tests/lib/mail.php
	tests/settings/controller/mailsettingscontrollertest.php

Conflicts:
	3rdparty
	lib/private/mail.php
	lib/private/server.php
	lib/public/iservercontainer.php
	settings/ajax/lostpassword.php
	settings/application.php
2015-03-16 12:47:05 +01:00
Joas Schilling 2731b80f74 Only register the core providers when necessary 2015-03-16 12:45:18 +01:00
Joas Schilling 8ed27d2ce0 Create an interface for OC_Image and OCP\Image for the public API 2015-03-16 12:45:15 +01:00
Joas Schilling 3b7aec1b7d Only sort the list when required 2015-03-16 12:44:12 +01:00
Joas Schilling 37b827f0b2 Order the providers alphabetically 2015-03-16 12:44:12 +01:00
Joas Schilling 9c86574acf Only do all the "find path" magic when we need to register them 2015-03-16 12:44:11 +01:00
Joas Schilling e38dea3542 Cache result for isMimeTypeSupported() 2015-03-16 12:44:11 +01:00
Joas Schilling e518eacba6 Add more type hinting 2015-03-16 12:44:11 +01:00
Joas Schilling 1a1dc9b335 Use DI for the config 2015-03-16 12:44:11 +01:00
Joas Schilling c1f266db88 Add an interface for the preview providers 2015-03-16 12:44:11 +01:00
Joas Schilling 227ff0a9e3 Clean up some docs 2015-03-16 12:44:11 +01:00
Joas Schilling 0b37d5aea3 Move default provider registration to preview manager 2015-03-16 12:44:11 +01:00
Joas Schilling cae8529359 Register preview providers on the preview manager instead of OC\Preview 2015-03-16 12:44:11 +01:00
Thomas Müller 1075914f8a Merge pull request #14883 from owncloud/imagepng_expects_resource_issue
validate resource's integrity before using it
2015-03-16 12:22:27 +01:00
Georg Ehrke 09b05373ed validate resource's integrity before using it 2015-03-16 10:57:01 +01:00
Morris Jobke 17b10ef9b4 Add spaces 2015-03-16 10:52:29 +01:00
Morris Jobke 997a7a2668 Merge pull request #14766 from owncloud/fix-insertifnotexists-poc
Allow specifying the compare-array for insertIfNotExists()
2015-03-16 10:31:36 +01:00
Vincent Petry b495ca4924 Added part files for when writing chunks
Whenever a chunk is being written, it is now written to a part file
first. This is to avoid a concurrent chunk upload to believe that the
former chunk already exists, even though it's not fully written.

This makes sure that the final file assembly is only done when all
chunks were successfully written.

Also added an extra unique id to chunk parts in case the same chunk is
uploaded twice concurrently.
2015-03-16 10:13:13 +01:00
Thomas Müller bbaf97ca43 Merge pull request #14644 from owncloud/trash-expire-command
Expire files from the trash in the background
2015-03-16 10:04:05 +01:00
Thomas Müller 6927773648 Merge pull request #14776 from owncloud/fix-14629-master
verify the file name length not to exceed 255 characters + verify path d...
2015-03-16 09:58:41 +01:00
Thomas Müller b159c7f274 Merge pull request #14848 from owncloud/kill-curl-fallback-master
drop any fallback code related to curl
2015-03-16 09:56:31 +01:00
Thomas Müller 918b86a5bc Merge pull request #14871 from owncloud/use-proper-error-type
Use proper error type and clean-up code
2015-03-13 23:30:49 +01:00
Lukas Reschke e77d2ff2b4 Remove outdated comment 2015-03-13 16:19:52 +01:00
Lukas Reschke bf9030e874 Drop example user backend
We already provide an interface for application developers, this file is outdated and thus should get removed.

Addresses No. 3 from https://github.com/owncloud/core/issues/14847
2015-03-13 16:12:32 +01:00
Morris Jobke 0d9f149dd9 Merge pull request #14867 from owncloud/drop-OC_User_HTTP
Remove OC_User_HTTP
2015-03-13 15:53:22 +01:00
Lukas Reschke 38fec9b095 Can also be null
If the user does not exist this returns null and can lead to nasty bugs since the IDE is not indicating this...
2015-03-13 14:01:24 +01:00
Lukas Reschke 4eb118dd33 Use proper error type and clean-up code 2015-03-13 13:21:09 +01:00
Lukas Reschke 93a303970f Remove OC_User_HTTP
Addresses No. 1 from https://github.com/owncloud/core/issues/14847
2015-03-13 12:26:33 +01:00
Thomas Müller 0bd2b3cb0c [WIP] upgrade app store apps during console upgrade 2015-03-13 12:16:16 +01:00
Thomas Müller 40b2889785 shipped apps are now defined in core/shipped.json - the shipped tag in info.xml is ignored from now on - never trust an app 🙊 2015-03-13 11:18:39 +01:00
Thomas Müller 5855108e9b drop any fallback code related to curl - refs https://github.com/owncloud/core/pull/14838#issuecomment-78586447 2015-03-12 21:43:41 +01:00
Lukas Reschke 00f5025ff1 Add cURL as hard-dependency
It is required by other functionalities such as S2S anyways and ownCloud will fail hard at a lot of places without it.
2015-03-12 18:39:54 +01:00
Thomas Müller 80ef53eff0 verify the file name length not to exceed 255 characters + verify path during rename 2015-03-12 10:47:47 +01:00
Joas Schilling fefcbb966b Also use all keys for an empty array, just in case 2015-03-12 09:18:43 +01:00
Morris Jobke dbd2bb66e9 Merge pull request #14357 from owncloud/fix/1373
Run `updateDataDirectory` after Update
2015-03-11 18:33:51 +01:00
Lukas Reschke f9fd1629da Merge pull request #14705 from rullzer/avatarcontroller
Move AvatarController to AppFramework
2015-03-11 17:15:42 +01:00
Morris Jobke 82254ad5ef Merge pull request #13893 from owncloud/create-cachedir-on-user
Only make sure the cache directory exists when we use it
2015-03-11 16:49:24 +01:00
Roeland Jago Douma 1a0f9c375b Avatar controller moved to AppFrameWork
* Original avatarcontroller migrated to the appframework
* Added DataDisplayResponse that show data inline in the browser (used
  to retrun the image)
* Removed some unneeded code
* Added unit tests for the avatarcontroller
2015-03-11 16:37:42 +01:00
Lukas Reschke 73dc02d42c Merge pull request #14798 from owncloud/enable-oci-autotest-master
Setting oci as supported database
2015-03-11 16:14:54 +01:00
Morris Jobke 04eef93b25 Merge pull request #13648 from oparoz/sfnt-fonts-preview
Add support for font previews
2015-03-11 15:56:32 +01:00
Thomas Müller 96b223676d Don't play with config values ... 2015-03-11 15:47:24 +01:00
Robin Appelman 169031d1c5 fix factory test 2015-03-11 15:07:59 +01:00
Robin Appelman e1f2a6df94 Allow setting the watcher policy as mount option 2015-03-11 15:07:23 +01:00
Robin Appelman 7adda88786 Copy mount options to the storage 2015-03-11 15:06:48 +01:00
Robin Appelman 4f0f175f8b Allow getting all mount options as array 2015-03-11 15:06:12 +01:00
Robin Appelman e5c8fd37df pass mountpoint to storage wrapper callback 2015-03-11 15:06:12 +01:00
Morris Jobke dbade19362 Merge pull request #13839 from owncloud/issue/13678-improve-remote-domain-detection-in-sharedropdown
Better finding the remote URL from user input in share dropdown
2015-03-11 14:38:41 +01:00
Morris Jobke ad97ceb787 Merge pull request #13513 from owncloud/repair-legacystoragenofatalfail
Do not abort when meeting unfixable legacy storages
2015-03-11 13:32:33 +01:00
Lukas Reschke 8154ed4d2c Merge pull request #14791 from owncloud/fix-14516
Adding a more meaningful message for sabre dav exception
2015-03-11 12:52:18 +01:00
Thomas Müller 0d0f9a52d2 Merge pull request #14788 from cmeh/patch-3
Correct "one invalid characters" to "one invalid character"
2015-03-11 12:26:49 +01:00
Thomas Müller 0f3e36fdfd Adding a more meaningful message for sabre dav exception - fixes #14516 2015-03-11 11:53:31 +01:00
Bernhard Posselt abb726c994 Merge pull request #14789 from owncloud/better-app-install-error-messages
display app update error messages
2015-03-11 11:28:28 +01:00
Thomas Müller ffe06ac5c7 display app update error messages - fixes #14611 2015-03-11 09:59:56 +01:00
cmeh 4a0c649c8a Correct "one invalid characters" to "one invalid character"
Corrected "one invalid characters" to "one invalid character" in line 1575.
2015-03-11 09:59:42 +01:00
Joas Schilling 2af8fea2be Throw a RuntimeException in the cache aswell 2015-03-11 09:33:50 +01:00
Thomas Müller 6c1a1234f8 Properly handle available databases at runtime and respect setup checks in command line as well 2015-03-11 09:27:12 +01:00
Thomas Müller 81fa9550a0 No need to restart the web server in cli mode 2015-03-11 09:27:12 +01:00
Joas Schilling d1511cdbee Fix doc blocks of insertIfNotExists() method 2015-03-11 09:05:30 +01:00
Lukas Reschke 284bd6647c Merge pull request #14759 from owncloud/clean-up-code
Clean-up code and use proper exception types
2015-03-10 14:18:21 +01:00
Lukas Reschke 6dc59019af Merge pull request #14346 from owncloud/storage-based-path-validation
adding storage specific filename verification
2015-03-10 11:02:47 +01:00
Thomas Müller c8ed88f4d6 Merge pull request #14689 from owncloud/better-missing-resource-handling
Log errors and create 404 in network list when a css or js is missing
2015-03-09 23:33:25 +01:00
Thomas Müller 89be55a672 let insertIfNotExist() throw the native DBALException - no need to hide the real exception 2015-03-09 22:37:49 +01:00
Joas Schilling 2747a83a49 Get the id before using it 2015-03-09 22:37:49 +01:00
Joas Schilling 3115d66d60 Better save then sorry 2015-03-09 22:37:49 +01:00
Joas Schilling 940163e16b insertIfNotExists() for storage insertion 2015-03-09 22:37:49 +01:00
Joas Schilling c917ea183c Only check unique keys for the comparison on filecache insert & update otherwise 2015-03-09 22:37:49 +01:00
Joas Schilling 8fa692388b Allow specifying the compare-array for insertIfNotExists() 2015-03-09 22:37:49 +01:00
Morris Jobke d34662122d Merge pull request #14429 from owncloud/issue/14176-validate-timezone-before-using
Etc timezones don't exist for .5 and .75 offsets
2015-03-09 16:16:16 +01:00
Joas Schilling 01cd83a902 Merge pull request #14713 from owncloud/issue/14671-preview-delete-check-for-valid-fileid
Check whether the file id is valid, before using it to delete the previews
2015-03-09 11:56:46 +01:00
Lukas Reschke 2ac6f3a4f5 Clean-up code and use proper exception types 2015-03-09 11:48:55 +01:00
Joas Schilling a12e16e985 Check whether the file id is valid, before using it to delete the previews 2015-03-09 11:25:18 +01:00
Thomas Müller 3623f14e73 no translation service in common storage class 2015-03-09 10:38:38 +01:00
Thomas Müller 2367797c17 Respect http header 'Accept-Language' on ocs and remote.php calls 2015-03-09 10:38:38 +01:00
Thomas Müller 33b11682f9 translate error messages 2015-03-09 10:38:38 +01:00
Lukas Reschke 2f18a09a20 Optimize loop 2015-03-09 10:38:38 +01:00
Thomas Müller e28d314b53 deprecate isValidFileName() 2015-03-09 10:38:38 +01:00
Thomas Müller 49e1a81eba fixing namespaces and PHPDoc 2015-03-09 10:38:37 +01:00
Thomas Müller 4bac595068 adding storage specific filename verification - refs #13640 2015-03-09 10:38:37 +01:00
Morris Jobke d550143ba0 proper filename for "require version.php" 2015-03-09 08:03:28 +01:00
Lukas Reschke 60c507cd4e Merge pull request #14722 from owncloud/master-14711
Fix totally broken AppStore code...
2015-03-06 18:52:12 +01:00
Thomas Müller 1b08b7c726 use insertIfNotExist() in cache put 2015-03-06 15:32:58 +01:00
Thomas Müller 4e37831d85 Fix PHPDoc on the way .... 2015-03-06 14:54:57 +01:00
Thomas Müller 987b683895 Use an atomic implementation on sqlite for insertIfNotExist() 2015-03-06 14:54:54 +01:00
Lukas Reschke d5a8225c0e Fix totally broken AppStore code...
As it turned out the AppStore code was completely broken when it came from apps delivered from the appstore, this meant:

1. You could not disable and then re-enable an application that was installed from the AppStore. It simply failed hard.
2. You could not disable apps from the categories but only from the "Activated" page
3. It did not show the activation state from any category page

This code is completely static and thus testing it is impossible. We really have to stop with "let's add yet another feature in already existing static code". Such stuff has to get refactored first.

That said, this code works from what I can say when clicking around in the AppStore page GUI. However, it may easily be that it does not work with updates or whatsever as I have no chance to test that since the AppStore code is not open-source and it is impossible to write unit-tests for that.

Fixes https://github.com/owncloud/core/issues/14711
2015-03-06 00:16:17 +01:00
Robin McCorkell 78819da3bf \OC\Memcache\Cache implements \OCP\ICache 2015-03-05 11:36:34 +00:00
Robin McCorkell 0e4933e6d2 Refactor \OC\Memcache\Factory
Caches divided up into two groups: distributed and local. 'Low latency' is an
alias for local caches, while the standard `create()` call tries to get
distributed caches first, then local caches.

Memcache backend is set in `config.php`, with the keys `memcache.local` and
`memcache.distributed`. If not set, `memcache.distributed` defaults to the value
of `memcache.local`.
2015-03-05 11:36:34 +00:00
Joas Schilling 716ba49a82 Log errors and create 404 in network list when a css or js is missing 2015-03-04 17:56:33 +01:00
Vincent Petry aa11b83158 Merge pull request #14682 from owncloud/issue/14681-noop-scanner-outdated
Update scanFile() and scanChildren() to the new signature of the parent ...
2015-03-04 10:07:42 +01:00
Morris Jobke ac10441600 Merge pull request #14326 from owncloud/remove-unnessary-backslashes-from-translation
Remove unnecessary backslashes from translations
2015-03-04 09:58:42 +01:00
Morris Jobke f1d74e8803 Merge pull request #14651 from owncloud/add-some-headers-to-htaccess-for-my-best-friend-jenkins
Let users configure security headers in their Webserver
2015-03-04 09:36:01 +01:00
Joas Schilling 09ac2df1f8 Update scanFile() and scanChildren() to the new signature of the parent class 2015-03-04 09:22:53 +01:00
Joas Schilling e12c83e3dc Merge pull request #14674 from owncloud/fix-l10n-getlanguagecode-2
Jenkins #14650
2015-03-03 18:33:08 +01:00
Joas Schilling b669bf26d6 Fix the behaviour of getLanguageCode() to match the expectation of the name 2015-03-03 16:47:31 +01:00
Joas Schilling ed4c05c7b5 Use findLanguage() instead of creating the object first 2015-03-03 16:47:31 +01:00
Joas Schilling 1761b162e6 Merge pull request #14660 from metaworx/replace-static-dbtableprefix-with-config-dbtableprefix
use `dbtableprefix` for temp table and index names
2015-03-03 16:43:47 +01:00
Thomas Müller be27188649 Merge pull request #14574 from owncloud/fix-irequest-for-older-php-versions
Read from IRequest instead of reading twice
2015-03-03 14:22:56 +01:00
Thomas Müller e30ca8198f Merge pull request #14638 from owncloud/issue/14538-repairstep-drop-old-tables
Add a repair step to delete old tables
2015-03-03 13:37:54 +01:00
Thomas Müller 29ecbc8c6c Merge pull request #14496 from owncloud/kill-substr-mssql-master
[Master] Remove hacky Substring support for MSSQL
2015-03-03 11:00:13 +01:00
Joas Schilling 276d678080 Etc timezones don't exist for .5 and .75 offsets 2015-03-03 09:08:47 +01:00
martin-rueegg 6be8ab65a5 replace 'oc_' with dbtableprefix form config for temporary table names and indexes 2015-03-03 01:54:15 +01:00
Lukas Reschke c3c993446e Run `updateDataDirectory` after Update
Fixes https://github.com/owncloud/core/issues/13731
2015-03-02 19:39:17 +01:00
Lukas Reschke bbd5f28415 Let users configure security headers in their Webserver
Doing this in the PHP code is not the right approach for multiple reasons:

1. A bug in the PHP code prevents them from being added to the response.
2. They are only added when something is served via PHP and not in other cases (that makes for example the newest IE UXSS which is not yet patched by Microsoft exploitable on ownCloud)
3. Some headers such as the Strict-Transport-Security might require custom modifications by administrators. This was not possible before and lead to buggy situations.

This pull request moves those headers out of the PHP code and adds a security check to the admin settings performed via JS.
2015-03-02 19:07:46 +01:00
Robin Appelman 00568af74d Allow running the async commands from unit tests 2015-03-02 15:25:31 +01:00
Vincent Petry e61aa3723e Merge pull request #14573 from owncloud/enc-migrate-disable-updater
Disable the cache updater when doing the encryption migration
2015-03-02 14:53:29 +01:00
Joas Schilling 195c577c77 Add a repair step to delete old tables 2015-03-02 12:02:14 +01:00
Lukas Reschke faddd1e256 Simplify code 2015-03-01 11:46:39 +01:00
Lukas Reschke 4100610390 Disable some server checks when running on HHVM
Ref https://github.com/owncloud/core/issues/10837#issuecomment-76516839
2015-02-28 10:08:41 +01:00
Robin Appelman f6182aa87e Allow disabling the cache updater 2015-02-27 17:14:16 +01:00
Morris Jobke b4dfd043d7 Merge pull request #14575 from owncloud/cache-rename-overwrite
Fix cache update when doing a rename that overwrites the target
2015-02-27 17:11:37 +01:00
Robin Appelman fc027bceb7 Fix cache update when doing a rename that overwrites the target 2015-02-27 16:39:58 +01:00
Bernhard Posselt 970b14d297 Merge pull request #13616 from owncloud/streamresponse
AppFramework StreamResponse
2015-02-27 15:43:01 +01:00
Bernhard Posselt 95239ad21e AppFramework StreamResponse
First stab at the StreamResponse, see #12988

The idea is to use an interface ICallbackResponse (I'm not 100% happy with the name yet, suggestions?) that allow the response to output things in its own way, for instance stream the file using readfile

Unittests are atm lacking, plan is to

check if a mock of ICallbackResponse will be used by calling its callback (also unhappy with this name) method
Usage is:

$response = new StreamResponse('path/to/file');

rename io to output, add additional methods and handle error and not modified cases when using StreamResponse

fix indention and uppercasing, also handle forbidden cases

fix indention

fix indention

no forbidden, figuring out if a file is really readable is too complicated to get to work across OSes and streams

remove useless import

remove useless import

fix intendation
2015-02-27 15:42:33 +01:00
Joas Schilling c5a9bad919 Merge pull request #14567 from owncloud/node-check-fileinfo-interface
Add "throws" lines to calling methods and interface aswell
2015-02-27 15:15:09 +01:00
Lukas Reschke 5c2fafa05f Read from IRequest instead of reading twice
Potentially fixes https://github.com/owncloud/core/issues/14541 and https://github.com/owncloud/core/issues/14506
2015-02-27 14:22:35 +01:00
Vincent Petry 22bc37cb82 Properly forward repair errors and warnings
This makes repair errors and warnings visible for the user when
upgrading on the command line or in the web UI.
2015-02-27 12:44:04 +01:00
Thomas Müller 8abb80c642 Merge pull request #14565 from owncloud/more-https
Add more HTTPS endpoints
2015-02-27 03:31:08 -08:00
Joas Schilling 3a6a0501c4 Add "throws" lines to calling methods and interface aswell 2015-02-27 12:16:53 +01:00
Vincent Petry e6abe96374 Do not abort when meeting unfixable legacy storages 2015-02-27 12:03:22 +01:00
Thomas Müller 7fe07e93fe Merge pull request #14437 from owncloud/node-check-fileinfo
Check if we have a proper fileinfo
2015-02-27 02:56:13 -08:00
Lukas Reschke b048e7129a Add more HTTPS endpoints
The doc server can now finally speak SSL...
2015-02-27 11:37:30 +01:00
Thomas Müller 1c6857d92c Merge pull request #14529 from owncloud/intuitive-version-check
Make version check work on the lowest common version denominator
2015-02-27 02:16:23 -08:00
Lukas Reschke b58455241b Add notice about Travis Checks
Maybe it helps in the future so we won't forget it again 🙈
2015-02-27 10:23:20 +01:00
Thomas Müller f72f9e0159 Merge pull request #14530 from owncloud/revert-14403
Revert "Updating license headers"
2015-02-27 00:39:29 -08:00
Robin Appelman 5bb1a131e4 fix warning in gc 2015-02-26 16:42:41 +01:00
Lukas Reschke 9baf758150 Merge pull request #14503 from owncloud/quota-preventdatalossforfailedmove
Fix file move/copy when storage space is not enough
2015-02-26 16:35:13 +01:00
Morris Jobke 18d43f7469 Merge pull request #14474 from owncloud/move-utf-8-check-to-setup
Move UTF-8 check to setup
2015-02-26 16:00:31 +01:00
Morris Jobke 522469614b Merge pull request #14505 from owncloud/dav-copy-fix
Fixes WebDAV copy
2015-02-26 15:42:53 +01:00
Vincent Petry 232de3bdc0 Delete target file for unsuccessful copy/rename 2015-02-26 15:11:37 +01:00
Morris Jobke 0c1e6fad6c Merge pull request #14300 from owncloud/commandbus
Add async command system to handle asynchronous operations
2015-02-26 15:10:13 +01:00
Morris Jobke 27fde80ee6 fix exception message 2015-02-26 15:08:30 +01:00
Bernhard Posselt 876e8bcb55 add phpdoc 2015-02-26 11:49:51 +01:00
Bernhard Posselt 2987d4aec8 make version check work on the lowest common version denominator 2015-02-26 11:42:08 +01:00
Morris Jobke 06aef4e8b1 Revert "Updating license headers"
This reverts commit 6a1a4880f0.
2015-02-26 11:37:37 +01:00
Vincent Petry ae2f37ac06 Removed unused $node variable 2015-02-26 11:16:42 +01:00
Thomas Müller adc986f3e4 Merge pull request #14502 from owncloud/failing-mysql-master-tests
Failing mysql master tests
2015-02-26 01:48:37 -08:00
Bernhard Posselt 59bbf27253 remove IDb interface from core class usage 2015-02-25 22:21:24 +01:00
Thomas Müller c62eb9d652 owncloud -> ownCloud 2015-02-25 22:21:24 +01:00
Bernhard Posselt 4e29a4d867 deprecate getters for deprecated class 2015-02-25 22:21:24 +01:00
Bernhard Posselt fb84e7d282 migrate to IDBConnection 2015-02-25 22:21:24 +01:00
Lukas Reschke 0720cf0ad1 Merge pull request #14494 from owncloud/fix-oracle-master
using Doctrine\DBAL\Connection::executeUpdate()
2015-02-25 21:43:51 +01:00
Vincent Petry 64c333c44b Merge pull request #14508 from owncloud/tagmanager-nouser
Return null when requesting tags for null user
2015-02-25 20:53:59 +01:00
Clark Tomlinson e8c3e33154 Merge pull request #14490 from owncloud/remove-unused-deprecated-code
Remove unused and deprecated Code
2015-02-25 14:49:40 -05:00
Vincent Petry 9ee37169a6 Return null when requesting tags for null user
The TagManager->load() now returns null if the user is not authenticated
instead of failing with an error.
2015-02-25 17:20:26 +01:00
Vincent Petry f39fcbc250 Fixes WebDAV copy
- added existence check for source argument
- removed extra logic for folders, as $view->copy() already supports
  that internally
2015-02-25 16:35:13 +01:00
Vincent Petry 20738d287e Properly detect streamCopy errors
Now checking whether the written bytes match the number of read bytes.
2015-02-25 16:03:15 +01:00
Joas Schilling 6e9f3b2f7e Clear the local cache when we clear the backends 2015-02-25 16:03:12 +01:00
Robin Appelman f5befbeac6 Check if we have a proper fileinfo 2015-02-25 16:02:08 +01:00
Thomas Müller 14c592fe86 Merge pull request #14500 from owncloud/fileglobalgc-cleanup
Cleanup garbage collection for global file cache
2015-02-25 06:41:57 -08:00
Robin Appelman 3cf237df67 set max argument length to 4000 2015-02-25 15:09:41 +01:00
Robin Appelman bf65b1f18b Rename getAsyncCommandBus to getCommandBus 2015-02-25 15:09:41 +01:00
Robin Appelman a39c7bf464 Add FileAccess trait for commands 2015-02-25 15:09:41 +01:00
Robin Appelman 8213f8d67d Allow apps to determine which commands should be run synchronous based on traints 2015-02-25 15:09:41 +01:00
Robin Appelman c2a7fff4f6 throw an exception when trying to push a background job that wont fit in the table
otherwise it will lead to failures in json decode and unexpected and hard to debug issues when running the job
2015-02-25 15:08:40 +01:00
Robin Appelman 74ae7b8929 Add async command system to handle asynchronous operations 2015-02-25 15:08:40 +01:00
Robin McCorkell 695f43a1ed Merge pull request #10735 from owncloud/use_remote_addr
Use getRemoteAddress which supports reverse proxies
2015-02-25 13:24:39 +00:00
Robin Appelman a848a6b1dd Cleanup garbage collection for global file cache 2015-02-25 14:13:58 +01:00
Lukas Reschke afe087a371 Remove hacky Substring support for MSSQL
Substring() is not required for the core functionality and this allows us to get rid of a huge hack...
2015-02-25 14:00:54 +01:00
Thomas Müller e9d25e4fdb using Doctrine\DBAL\Connection::executeUpdate() 2015-02-25 13:43:26 +01:00
Lukas Reschke de44a2b2ab Remove unused and deprecated Code
Function is not used anymore anywhere in the code base: https://github.com/search?q=user%3Aowncloud+secureRNGAvailable&type=Code&utf8=%E2%9C%93
2015-02-25 12:11:14 +01:00
Thomas Müller bcf3704645 Merge pull request #14458 from owncloud/revive/11157
Get the real protocol behind several proxies
2015-02-25 02:51:46 -08:00
Thomas Müller 799e144b04 Merge pull request #14151 from owncloud/update-sabre2.1
Sabre Update to 2.1
2015-02-25 02:21:55 -08:00
Thomas Müller b3de86d851 Remove locks plugin.
Reasoning:
- a WebDAV server is not required to implement locking support
- WebDAV Locking is know to break the sync algorithm
- the current lock implementation is known to be broken (locks are not moved if a file is moved, locks on shared files don't work)
2015-02-25 10:30:47 +01:00
Vincent Petry fb87b746f0 Merge pull request #14213 from AW-UC/naturalsort_defaultcollator-patch-file-sorting
Update naturalsort_defaultcollator.php. Fixes #13982
2015-02-25 10:30:14 +01:00
Lukas Reschke 06cf93e6ee Move UTF-8 check to setup
Nobody reads the warnings anyways and so we should enforce it at installation time... Also allows us to get rid of some duplicated code.

To test change the `default_charset` to something other than `utf-8` or `UTF-8`, both should work fine with that change here. An error should then get shown.

We already set those default charsets in the shipped .user.ini and .htaccess
2015-02-24 23:51:36 +01:00
AW-UC d57f5c70e9 Fix sorting for files that only differ in case. 2015-02-24 23:50:38 +01:00
Olivier Paroz f49805eea5 Add support for font previews 2015-02-24 22:00:54 +01:00
Lukas Reschke d43d34c93f Merge pull request #14195 from owncloud/activity-manager-performance-improvements
Activity manager performance improvements
2015-02-24 15:19:15 +01:00
Thomas Müller 7325414481 Merge pull request #14282 from owncloud/disable-non-shipped-apps-master
3rd-party apps are disabled on upgrade
2015-02-24 14:39:45 +01:00
Joas Schilling 88cfe46906 Merge pull request #11555 from goodkiller/patch-1
Update group.php
2015-02-24 13:58:41 +01:00
Lukas Reschke 276824299c Merge pull request #13340 from owncloud/use-http-only
Use "HTTPOnly" for cookies when logging out
2015-02-24 13:50:49 +01:00
Lukas Reschke 9adcd15cb3 Use [0] instead of current as HHVM might have problems with that 2015-02-24 13:37:34 +01:00
Bernhard Posselt fd3663f563 Dont break code which relies on the cursor being open after insert/update/delete 2015-02-24 12:58:36 +01:00
Thomas Müller 80cafe29a8 3rd-party apps are only disabled in case core is upgraded 2015-02-24 12:51:55 +01:00
Lukas Reschke 1c6eae9017 Get the real protocol behind several proxies
X-Forwarded-Proto contains a list of protocols if ownCloud is behind multiple reverse proxies.

This is a revival of https://github.com/owncloud/core/pull/11157 using the new IRequest public API.
2015-02-24 12:24:55 +01:00
Thomas Müller fe7e7677e9 shipped and 3rd-party apps of type authentication and session will remain enabled during update 2015-02-24 12:02:37 +01:00
Thomas Müller bbf7f56f94 3rd-party apps are disabled on upgrade - refs #14026 2015-02-24 12:02:36 +01:00
Lukas Reschke 165afb004b Use getRemoteAddress which supports reverse proxies
Breaking change for 8.1 wiki (Security > Administrators):

The log format for failed logins has changed and uses now the remote address and is considering reverse proxies for such scenarios when configured correctly.
2015-02-24 11:49:40 +01:00
Thomas Müller da8e34cf7f Merge pull request #14009 from owncloud/installing-installed-apps-is-stupid
don't allow installation of already installed apps - fixes #14004
2015-02-24 10:34:06 +01:00
Lukas Reschke 8bd3d55517 Merge pull request #14442 from owncloud/fix-oracle-ci-master
Close the cursor after the affected count has been extracted.
2015-02-24 09:20:59 +01:00
Thomas Müller b40d4c9cbc app store can be used with any edition 2015-02-23 23:16:28 +01:00
Thomas Müller 39d8406933 don't allow installation of already installed apps - fixes #14004 2015-02-23 23:16:28 +01:00
Thomas Müller e87ada86d1 Merge pull request #14416 from owncloud/setup-command
Setup command
2015-02-23 22:41:10 +01:00
Lukas Reschke 432d7be8cc Show a empty response for GET on non-files instead of the Browser Plugin 2015-02-23 22:27:23 +01:00
Vincent Petry 9f6dcb9d3e Sabre Update to 2.1
- VObject fixes for Sabre\VObject 3.3
- Remove VObject property workarounds
- Added prefetching for tags in sabre tags plugin
- Moved oc_properties logic to separate PropertyStorage backend (WIP)
- Fixed Sabre connector namespaces
- Improved files plugin to handle props on-demand
- Moved allowed props from server class to files plugin
- Fixed tags caching for files that are known to have no tags
  (less queries)
- Added/fixed unit tests for Sabre FilesPlugin, TagsPlugin
- Replace OC\Connector\Sabre\Request with direct call to
  httpRequest->setUrl()
- Fix exception detection in DAV client when using Sabre\DAV\Client
- Added setETag() on Node instead of using the static FileSystem
- Also preload tags/props when depth is infinity
2015-02-23 22:27:23 +01:00
Thomas Müller 0a9b8242ee properly initialize OC::$WEBROOT and host name 2015-02-23 21:49:35 +01:00
Thomas Müller c350da1a28 Merge pull request #14119 from owncloud/dbal251
Update doctrine/dbal to 2.5.1 #13537
2015-02-23 20:59:51 +01:00
Thomas Müller 5bdf42a925 Close the cursor after the affected count has been extracted. 2015-02-23 17:17:20 +01:00
Thomas Müller 1fd1b355e4 Fix namespace of OC_Setup -> \OC\Setup 2015-02-23 16:44:40 +01:00
Vincent Petry 4290e1990e Merge pull request #13829 from owncloud/appmanager-list
Better caching for enabled apps
2015-02-23 16:03:32 +01:00
Bernhard Posselt 8176032176 Merge pull request #14427 from owncloud/fix-some-php-docs
Fix some PHPDocs
2015-02-23 14:04:35 +01:00
Thomas Müller df3c73de72 Merge pull request #14403 from owncloud/update-license-headers
Update license headers
2015-02-23 13:53:16 +01:00
Lukas Reschke c06a94ecc2 Fix some PHPDocs 2015-02-23 12:19:52 +01:00
Jenkins for ownCloud 6a1a4880f0 Updating license headers 2015-02-23 12:13:59 +01:00
Joas Schilling b180724cd0 Extract the remote host from user input in share dropdown
Fix #13678
2015-02-23 11:28:41 +01:00
Thomas Müller f693d439e2 Merge pull request #14422 from owncloud/use-off-and-off
Use "off" and "off" instead of true booleans
2015-02-23 11:12:53 +01:00
Lukas Reschke 9a08c7ecb9 Merge pull request #14275 from chris-se/master
DAV authentication: use Owncloud's internal user instead of HTTP auth one
2015-02-23 10:25:13 +01:00
Lukas Reschke 43641d917b Use "off" and "off" instead of true booleans
Apparently a boolean in php.ini is according to the documentation "on" or "off"…

Fixes itself.
2015-02-23 09:40:15 +01:00
Lukas Reschke 2f0f38761d Add helper to check for `ini` values in `OC_Util::checkServer`
This allows to check for specific values in the PHP.ini that ownCloud requires for full compatibility.

`mbstring.func_overload`: https://github.com/owncloud/core/issues/14372
`output_buffering`: http://doc.owncloud.org/server/8.0/admin_manual/configuration/big_file_upload_configuration.html#configuring-php

Fixes https://github.com/owncloud/core/issues/14372 and https://github.com/owncloud/core/issues/14412
2015-02-21 12:12:34 +01:00
Lukas Reschke fcc5f5a4f4 Merge pull request #13777 from owncloud/close-cursor
Close cursor for appframework and manipulation queries if applicable
2015-02-20 20:15:22 +01:00
Thomas Müller 3a6b11d018 Merge pull request #13767 from owncloud/issue/13764-mimetype-racecondition
Use insertIfNotExists() and reload mimetypes after inserting one
2015-02-20 17:39:17 +01:00
Lukas Reschke 50208308e3 Merge pull request #14359 from owncloud/add-satisfy-all
Add `Satisfy All`
2015-02-20 14:55:43 +01:00
AW-UC bc668600cd Add constructor to inject collator
Adding the possibility for instantiating \OC\NaturalSort with an
injected collator. This makes the use of a specific collator enforcable.
2015-02-20 14:03:34 +01:00
Joas Schilling ae60108692 Revert "Correctly fallback to english, if the plural case is not translated"
This reverts commit cbad5c998b.
2015-02-20 11:51:36 +01:00
Arthur Schiwon 7ada41259c Port of #14041 to master
on ownCloud upgrade: upgrade all apps in order, load important ones

Fix "other" app update stack
2015-02-19 14:38:22 +01:00
Thomas Müller 84eb00e428 Merge pull request #14342 from owncloud/disallow-path-traversals-in-file-view
Disallow path traversals in file view
2015-02-19 10:27:04 +01:00
Lukas Reschke 4decbc2efa Add `Satisfy All`
Fixes https://github.com/owncloud/core/issues/14356
2015-02-19 02:16:44 +01:00
Thomas Müller b32d31a2f1 Merge pull request #13836 from owncloud/part-no-cache-update
Dont update the cache when working with part files
2015-02-19 00:08:10 +01:00
Lukas Reschke 46ca0fa481 Add some basic PHPDoc to functions 2015-02-18 18:17:33 +01:00
Lukas Reschke 41e5850450 Prevent directory traversals in ctr of \OC\Files\View
This prevents a misusage of \OC\Files\View by calling it with user-supplied input. In such cases an exception is now thrown.
2015-02-18 18:17:33 +01:00
Clark Tomlinson 8d09cc3b91 Merge pull request #13989 from owncloud/enhancment/security/11857
Allow AppFramework applications to specify a custom CSP header
2015-02-18 10:27:29 -05:00
AW-UC 097d455213 provide case-insensitive natural sorting
This makes OC's naturalsort_defaultcollator case-insensitive
2015-02-18 15:49:03 +01:00
Lukas Reschke e4bf3fcb53 Merge pull request #14330 from owncloud/revert-13879-add_debug_log_for_memcache_instantiation
Revert "add debug log for memcache instantiation"
2015-02-18 15:45:38 +01:00
Robin Appelman 5542fafd36 allow overwriting the appmanager in oc_util by subclassing 2015-02-18 14:24:50 +01:00
Joas Schilling eaccd2a72a Remove unnecessary backslashes from translations 2015-02-18 14:17:53 +01:00
Lukas Reschke cd4c064ebf Revert "add debug log for memcache instantiation" 2015-02-18 14:16:14 +01:00
Lukas Reschke a666f804c7 Use the untrusted domain in the installer 2015-02-18 13:59:37 +01:00
Thomas Müller 2b1f39cd6b Merge pull request #14308 from owncloud/fix-14247
Add mapping for a broken varchar type.
2015-02-18 10:05:33 +01:00
Lukas Reschke ceaa193df2 Merge pull request #14273 from owncloud/require-at-least-apcu-4-0-6
Use APCu only if available in version 4.0.6 and higher
2015-02-18 01:07:54 +01:00
Morris Jobke 5d7d2adcbf Merge pull request #14207 from owncloud/propfind-optimize
Optimize quota calculation for propfind
2015-02-18 00:18:47 +01:00
Victor Dubiniuk 090db867d5 Add mapping for a broken varchar type. Fixes #14247 2015-02-17 23:22:57 +03:00
Robin Appelman e672f8cc8f Use appmanager in OC_App::enable/disable 2015-02-17 15:05:29 +01:00
Robin Appelman 04628cf368 better name for getAppsEnabledForUser 2015-02-17 15:05:29 +01:00
Robin Appelman 434835b326 also set user in UserSession when doing OC_User::setUserId 2015-02-17 15:05:29 +01:00
Robin Appelman 409453bc60 better user group caching 2015-02-17 15:05:29 +01:00
Robin Appelman 5c68c81d00 Update cache when enabling/disabling apps 2015-02-17 15:05:25 +01:00
Lukas Reschke b701bbd8c5 Use APCu only if available in version 4.0.6 and higher
APCu before 4.0.6 is unbelievable buggy and tend to segfault the PHP process (i.e. the whole webserver)

This potentially fixes https://github.com/owncloud/core/issues/14175

Requires a backport to stable8
2015-02-17 13:28:02 +01:00
Christian Seiler 535757bc42 DAV authentication: also use Owncloud's internal user for short-circuit
It still works otherwise, but without this, the performance optimization
of #13416 is defeated in these situations.
2015-02-16 23:47:39 +01:00
Christian Seiler 1377ebc7e9 DAV authentication: use Owncloud's internal user instead of HTTP-supplied one
Fixes: #14048, #14104, calendar#712
2015-02-16 23:34:49 +01:00
Lukas Reschke cebf9f6a5a Incorporate review changes 2015-02-16 22:13:03 +01:00
Lukas Reschke 992164446c Add blackmagic due to cyclic dependency 🙈 2015-02-16 22:13:01 +01:00
Lukas Reschke 9f91d64918 Make scrutinizer happy 2015-02-16 22:13:00 +01:00
Lukas Reschke 886bda5f81 Refactor OC_Request into TrustedDomainHelper and IRequest
This changeset removes the static class `OC_Request` and moves the functions either into `IRequest` which is accessible via `\OC::$server::->getRequest()` or into a separated `TrustedDomainHelper` class for some helper methods which should not be publicly exposed.

This changes only internal methods and nothing on the public API. Some public functions in `util.php` have been deprecated though in favour of the new non-static functions.

Unfortunately some part of this code uses things like `__DIR__` and thus is not completely unit-testable. Where tests where possible they ahve been added though.

Fixes https://github.com/owncloud/core/issues/13976 which was requested in https://github.com/owncloud/core/pull/13973#issuecomment-73492969
2015-02-16 22:13:00 +01:00
Victor Dubiniuk bdfc9b57bd Skip primary index if the table has one 2015-02-16 20:30:28 +01:00
Jörn Friedrich Dreyer 87db136508 add debug log for memcache instantiation 2015-02-16 18:05:43 +01:00
Morris Jobke 5a5d6bf4db Merge pull request #14128 from owncloud/drop-unused-methods
Remove unused function and correct PHPDoc
2015-02-16 17:37:36 +01:00
Thomas Müller 9271059195 Merge pull request #13750 from owncloud/enhanced-code-checker
Implement php code checker to detect usage of not allowed private ...
2015-02-16 16:55:57 +01:00
Joas Schilling 8eb804b1f6 Merge pull request #13269 from owncloud/issue/13211-cache-array-implementation
Add an array implementation of cache and use it if we are not debugging
2015-02-16 15:35:20 +01:00
Robin Appelman 23ab25e93a Use the app manager from oc_app 2015-02-16 15:16:13 +01:00
Robin Appelman 2b58e8489f Add getInstalledApps and getAppsForUser to the app manager 2015-02-16 15:15:35 +01:00
Thomas Müller 9c47ab91f2 Merge pull request #14194 from owncloud/url-encode-logout-attribute
URLEncode logout attribute
2015-02-16 15:04:20 +01:00
Joas Schilling 8848b5f067 Add an array implementation of cache and use it if we are not debugging 2015-02-16 14:55:50 +01:00
Lukas Reschke c6705ab574 Merge pull request #13890 from owncloud/add-no-referrer
Add `rel="noreferrer"` where possible and switch to HTTPS
2015-02-16 14:36:44 +01:00
Lukas Reschke 7e45f5d27b Remove unused function and correct PHPDoc 2015-02-16 13:46:45 +01:00
Lukas Reschke 8791f1992e Add noreferrer to footer URI 2015-02-16 13:37:54 +01:00
Thomas Müller 78febb2ee5 Merge pull request #14201 from owncloud/propagator-dont-decrease-mtime
Dont lower the mtime of a folder when propagating changes
2015-02-16 11:32:17 +01:00
Lukas Reschke b20174bdad Allow AppFramework applications to specify a custom CSP header
This change allows AppFramework applications to specify a custom CSP header for example when the default policy is too strict. Furthermore this allows us to partially migrate away from CSS and allowed eval() in our JavaScript components.

Legacy ownCloud components will still use the previous policy. Application developers can use this as following in their controllers:
```php
$response = new TemplateResponse('activity', 'list', []);
$cspHelper = new ContentSecurityPolicyHelper();
$cspHelper->addAllowedScriptDomain('www.owncloud.org');
$response->addHeader('Content-Security-Policy', $cspHelper->getPolicy());
return $response;
```

Fixes https://github.com/owncloud/core/issues/11857 which is a pre-requisite for https://github.com/owncloud/core/issues/13458 and https://github.com/owncloud/core/issues/11925
2015-02-16 11:00:41 +01:00
Thomas Müller d5ca5c7bcc Merge pull request #14138 from owncloud/fix-image-flip-php53
Don't flip image in PHP 5.4
2015-02-16 10:26:56 +01:00
Robin Appelman 9abaa0cc61 pass fileinfo to getStorageInfo 2015-02-13 17:59:58 +01:00
Robin Appelman fb2a3284df Cache quota info for directories 2015-02-13 17:50:53 +01:00
Robin Appelman 134243d3e5 Dont lower the mtime of a folder when propagating changes 2015-02-13 14:30:05 +01:00
Lukas Reschke 276bfe5f33 Merge pull request #14197 from owncloud/ensure-that-passed-file-path-is-always-a-string
Ensure that passed argument is always a string
2015-02-13 13:30:54 +01:00
Lukas Reschke 95860d8113 Merge pull request #14086 from hlop/master
App install behind a Proxy
2015-02-13 12:56:01 +01:00
Lukas Reschke 9904b30070 Ensure that passed argument is always a string
Some code paths called the `normalizePath` functionality with types other than a string which resulted in unexpected behaviour.

Thus the function is now manually casting the type to a string and I corrected the usage in list.php as well.
2015-02-13 12:49:34 +01:00
Lukas Reschke 025110821f URLEncode logout attribute
Otherwise logout can fail if the requesttoken contains a +
2015-02-13 12:08:23 +01:00
Joas Schilling 6c349c00bb Order methods to by grouped by their task 2015-02-13 11:55:06 +01:00
Joas Schilling be63e18b0a Check whether filter is valid, before doing stuff for it 2015-02-13 11:50:55 +01:00
Joas Schilling c02de748e5 Cache some values from the extensions 2015-02-13 11:36:34 +01:00
Lukas Reschke 8e8acad550 Merge pull request #14145 from owncloud/no-whitespace-from-themes-master
catch any whitespaces which might get written to the output buffer while...
2015-02-12 17:23:28 +01:00
Thomas Müller fc7f279d90 catch any whitespaces which might get written to the output buffer while loading a theme 2015-02-12 16:42:17 +01:00
Lukas Reschke 2f80be45b0 Remove internal annotation
PHPStorm complained about those functions being declared as Internal. I doubt that this is actually the case since they are even in the public API.
2015-02-12 16:35:47 +01:00
Björn Schießle 780024e252 Merge pull request #14071 from owncloud/add_timeout_for_post_requests
add timeout to curl request
2015-02-12 11:38:35 +01:00
Morris Jobke f4182d2dc9 Merge pull request #10993 from owncloud/scanner-reuse-fileid
Reuse known fileids and cache data in the scanner
2015-02-12 10:53:00 +01:00
Bjoern Schiessle 4155252379 add timeout to curl request 2015-02-12 10:51:39 +01:00
Morris Jobke a496c34aea Check if imageflip is available
* imageflip() isn't available in PHP < 5.5
* fixes #14130
2015-02-12 10:21:20 +01:00
Lukas Reschke 86139fcce8 Deprecate `OC_JSON` and `OCP\JSON`
This deprecates – but not removes – those two classes and all functions in it. There is no reason that new developments should use those methods as with the AppFramework there is a replacement that allows testable code.

With the `@deprecated` annotation IDEs like PHPStorm will point out to the developer that a functionality is deprecated and that there is a better suited replacement.
2015-02-12 00:56:13 +01:00
Thomas Müller 9ecb36e81f integrate code checker in the installer 2015-02-11 23:37:51 +01:00
dratini0 10e13b172a Extending the X-accel redirect functionality with a more scalable approach. 2015-02-11 22:19:22 +01:00
dratini0 b1594ad1df Revert "Fix: X-Accel-Redirect did not support custom data dir and local mounts"
This reverts commit f2075f803f.
2015-02-11 22:19:22 +01:00
dratini0 80032ec301 Revert "removed a little duplication"
This reverts commit 31970ee740.
2015-02-11 22:19:22 +01:00
Thomas Müller 99a97649f2 Merge pull request #14097 from yanntech/fix/utf8-check
in some case charset can be in lower case.
2015-02-11 18:04:54 +01:00
Vincent Petry fbbb9fe0fd Merge pull request #13979 from owncloud/group-share-collition-wrong-type-in-post-hook
Do not overwrite the shareType so the post hook is still correct
2015-02-11 15:23:13 +01:00
Robin Appelman 9df18ffe75 only read permissions once 2015-02-11 13:11:31 +01:00
Robin Appelman 9bbfeada6b Only try to scan the children of directories 2015-02-11 13:11:31 +01:00
Robin Appelman dc6468c2aa Cast mtimes and size to int 2015-02-11 13:11:28 +01:00
Robin Appelman 4242dd0d9d Reuse cache data of existing files during scan 2015-02-11 13:08:28 +01:00
Yann VERRY 1fcea6f1bd in some case charset can be in lower case.
Add strtoupper() in UTF-8 check to avoid error message
2015-02-11 11:59:33 +01:00
Witali Rott 531c89a610 App install behind a Proxy 2015-02-11 07:47:50 +01:00
Thomas Müller 45dcca2fcb Merge pull request #13861 from owncloud/remove-disabled-files-repair-step
Revert "enabled disabled files app in repair step"
2015-02-10 22:46:53 +01:00
Morris Jobke 11283c57d9 Merge pull request #11056 from AdamWill/9885-opcode
add function to invalidate one opcache file, use it if possible #9885
2015-02-10 17:21:15 +01:00
Thomas Müller d74662df7d implement php code checker to detect usage of not allowed private APIs - including console command to check local code to be used by developers 2015-02-10 11:51:24 +01:00
Morris Jobke 1bb6de7c1b Merge pull request #13425 from owncloud/phpdoc_cleanup
Cleanup of PHPDoc return types
2015-02-10 01:14:00 +01:00
Morris Jobke 068f6107c6 Merge pull request #13842 from owncloud/is_file_2_is_readable
check if cache files are readable
2015-02-09 23:45:32 +01:00
Lukas Reschke 74de345c7f Merge pull request #13511 from owncloud/naturalsort_speeeeeed
NaturalSort performance improvements
2015-02-09 18:39:52 +01:00
Vincent Petry c4d9ae8af4 Merge pull request #13928 from owncloud/prevent_ghost_files_master
prevent creation of ghost directories
2015-02-09 18:15:45 +01:00
Vincent Petry 5296767393 Merge pull request #13921 from owncloud/ocs-af
Add a controller and reponse for ocs
2015-02-09 18:11:47 +01:00
Vincent Petry 605e2357a1 Merge pull request #13852 from owncloud/cache-app-versions
Cache app versions
2015-02-09 18:03:19 +01:00
Vincent Petry c7fcd42edb Merge pull request #13870 from owncloud/drop-oc-preferences-2
drop OC\Preferences
2015-02-09 17:49:05 +01:00
Vincent Petry b7b8c0c2e5 Merge pull request #13869 from owncloud/drop-oc-preferences
drop OC_Preferences
2015-02-09 17:48:36 +01:00
Lukas Reschke 47c7eb4e70 Merge pull request #13973 from owncloud/enhancement/security/13366
Respect `mod_unique_id` and refactor `OC_Request::getRequestId`
2015-02-09 17:35:19 +01:00
Robin McCorkell a79757bc37 Store FileInfo::getType() result for future use 2015-02-09 16:34:11 +00:00
Robin McCorkell 44c330aa5d Performance improvements for NaturalSort
A combination of using isset() instead of count() or strlen(), caching the
chunkify function, and replacing is_numeric() with some comparisons
2015-02-09 16:32:43 +00:00
Vincent Petry 5d8f1a1de3 Merge pull request #13854 from owncloud/avatar-exists
Add a better way to check if an avatar exists for the user
2015-02-09 17:06:24 +01:00
Joas Schilling 31b93ac19a Do not overwrite the shareType so the post hook is still correct 2015-02-09 12:59:29 +01:00
Robin Appelman 45e3cbefc9 Check directory handle before we use it 2015-02-09 12:36:18 +01:00
Lukas Reschke 770fa761b8 Respect `mod_unique_id` and refactor `OC_Request::getRequestId`
When `mod_unique_id` is enabled the ID generated by it will be used for logging. This allows for correlation of the Apache logs and the ownCloud logs.

Testplan:

- [ ] When `mod_unique_id` is enabled the request ID equals the one generated by `mod_unique_id`.
- [ ] When `mod_unique_id` is not available the request ID is a 20 character long random string
- [ ] The generated Id is stable over the lifespan of one request

Changeset looks a little bit larger since I had to adjust every unit test using the HTTP\Request class for proper DI.

Fixes https://github.com/owncloud/core/issues/13366
2015-02-09 11:53:11 +01:00
Lukas Reschke 0e604aa875 Merge pull request #13948 from owncloud/cache-move-transaction
Use transactions when renaming directory contents
2015-02-08 19:08:52 +01:00
Morris Jobke 90556cb70b Merge pull request #12283 from oparoz/sfnt-fonts
Updated the media type of some font types
2015-02-07 13:33:49 +01:00
Morris Jobke 11ded92a73 Merge pull request #13830 from owncloud/fix-redirect-404
Don't encode url unecessary twice
2015-02-07 13:24:47 +01:00
Robin Appelman 6c00521e8b Use transactions when renaming directory contents 2015-02-06 15:20:53 +01:00
Thomas Müller bc56fef619 Merge pull request #13932 from owncloud/revert-sabredav-etag-master
Revert "adding OC-ETag header"
2015-02-06 12:05:32 +01:00
Lukas Reschke 4d91fa4c93 Normalize before processing 2015-02-06 15:03:29 +01:00
Vincent Petry 8210200770 Revert "adding OC-ETag header"
This reverts commit 96a931929e.
2015-02-05 20:43:37 +01:00
Bjoern Schiessle 1448f281b7 for password protected link shares the password is stored in shareWith, so we need to set this manually to null for the hooks 2015-02-05 17:23:59 +01:00
Bernhard Posselt fdc64e370c add a controller and reponse for ocs 2015-02-05 14:02:17 +01:00
Robin Appelman adf9a4e4eb Dont bother updating the cache when working with part files 2015-02-05 13:59:50 +01:00
Robin Appelman 842d0e227c Dont update the cache after fopen 2015-02-05 13:47:32 +01:00
Robin Appelman 2e34db2bb3 Dont create exclude list for generating the share target 2015-02-04 17:08:03 +01:00
Robin Appelman 4a9c64e96b Only make sure the cache directory exists when we use it 2015-02-04 16:52:50 +01:00
Björn Schießle 486f49ed72 Merge pull request #13881 from owncloud/upload_to_root_of_mountpoint
detect root of mountpoint also if the trailing slash is missed
2015-02-04 14:44:02 +01:00
Bjoern Schiessle 21c45925fe detect root of mountpoint also if the trailing slash is missed 2015-02-04 12:47:04 +01:00
Morris Jobke 4df7c0a1ed drop OC\Preferences 2015-02-04 00:31:09 +01:00
Morris Jobke 909a53e087 drop OC_Preferences 2015-02-04 00:06:29 +01:00
Morris Jobke b168c191bc Revert "enabled disabled files app in repair step"
This reverts commit d70160c607.
2015-02-03 17:06:57 +01:00
Thomas Müller 23c6a0cf99 Merge pull request #13843 from owncloud/fix-files-disabled
Fix disabled files app
2015-02-03 16:13:15 +01:00
Robin Appelman 6f118d7f8d clear app version cache on upgrade 2015-02-03 15:23:51 +01:00
Robin Appelman c644ed89a7 Add a better way to check if an avatar exists for the user 2015-02-03 14:54:06 +01:00
Robin Appelman 70fd3a267f Cache app versions 2015-02-03 14:13:44 +01:00
Morris Jobke d70160c607 enabled disabled files app in repair step 2015-02-03 14:03:43 +01:00
Thomas Müller 9e222ec841 Merge pull request #13791 from owncloud/extstorage-fixdavexceptions
Fix DAV exceptions, some will still return false now
2015-02-03 13:31:32 +01:00
Jörn Friedrich Dreyer 86935fab17 readd is_file 2015-02-03 10:13:25 +01:00
Morris Jobke a7eedf0149 Disallow disabling of files app 2015-02-03 00:39:01 +01:00
Arthur Schiwon ded8cc47cf 🐫case 2015-02-02 23:47:59 +01:00
Jörn Friedrich Dreyer 2d8f57a1ea check if cache files are readable 2015-02-02 23:19:54 +01:00
Lukas Reschke 2bd1c17345 Don't encode url unecessary twice
The URL was previously encoded twice which leads to getting redirected to a 404 page when the password has been entered incorrect at least once.

Testplan:

- [ ] Opening `http://localhost/core/index.php?redirect_url=%2Fcore%2Findex.php%2Fsettings%2Fadmin` redirects to the admin page when providing the correct credentials
- [ ] Opening `http://localhost/core/index.php?redirect_url=%2Fcore%2Findex.php%2Fsettings%2Fadmin` redirects to the admin page when providing the invalid credentials and then providing valid ones.
- [ ] Logging in as admin then going to the admin page and clearing the cookies and refreshing will show the login and when repeating the above test steps you're redirected correctly.

Fixes https://github.com/owncloud/core/issues/9804
2015-02-02 15:09:59 +01:00
Thomas Müller 92bc1b44d5 Merge pull request #13822 from owncloud/include-core-version-in-js-version-tag
include core version into js/css version tag
2015-02-02 15:02:11 +01:00
Joas Schilling a575dcf78f Use insertIfNotExists() and reload mimetypes after inserting one 2015-02-02 13:20:16 +01:00
Thomas Müller 24daee836a include core version into js/css version tag - fixes #13702 2015-02-02 13:02:11 +01:00
Thomas Müller 82b271855c add libs which have no version number 2015-02-02 10:49:46 +01:00
Morris Jobke e7900ba255 Merge pull request #13508 from owncloud/failed-delete-cache
Dont remove a file from cache if the delete operation failed
2015-01-30 14:08:44 +01:00
Vincent Petry 5ade2854ee Fix DAV exceptions, some will still return false now
Since the Storage interface isn't ready to work directly with exceptions
like Forbidden and NotFound, the DAV storage has been adapted to still
return false when expected.
2015-01-30 12:02:23 +01:00
Vincent Petry 790622e9fd Merge pull request #13772 from owncloud/closecursor-allconfig
Close cursor after checking for existing config values
2015-01-29 19:31:21 +01:00
Bernhard Posselt 37e8969d34 ignore cursorclosing 2015-01-29 19:16:28 +01:00
Morris Jobke b1d8d88df8 Merge pull request #13760 from owncloud/create_enc_key_for_remote_shares
make sure that we always create a public share key for remote shares
2015-01-29 17:54:04 +01:00
Robin Appelman ce0aa02aac Dont do a cache rename if we cant delete the source file 2015-01-29 15:52:40 +01:00
Robin Appelman 2124540d1d Dont remove a file from cache if the delete operation failed 2015-01-29 15:39:56 +01:00
Lukas Reschke 65ec950b27 Merge pull request #13757 from owncloud/issue/13686-scroll-to-file-when-using-searchotherplaces
Scroll to file in folder, when using "search in other places" link
2015-01-29 15:36:25 +01:00
Björn Schießle 2c1bacadca Merge pull request #13762 from owncloud/ignore_trailing_slash
ignore trailing slash for remote URL
2015-01-29 15:00:44 +01:00
Morris Jobke acf0582029 Merge pull request #13752 from owncloud/closecursor1
Close cursor early in calculateFolderSize
2015-01-29 14:23:16 +01:00
Bjoern Schiessle c78e3c4a7f make sure that we always create a public share key for remote shares 2015-01-29 14:23:14 +01:00
Bjoern Schiessle 82de50d5b9 remove trailing slash 2015-01-29 14:03:09 +01:00
Robin Appelman 05035ef4af Fix webdav put for single file webdav shares 2015-01-29 12:47:12 +01:00
Robin Appelman ddee63fa00 Fix resolving paths for views rooted in a file 2015-01-29 12:47:11 +01:00
Joas Schilling 54303484eb Scroll to file in folder, when using "search in other places" link 2015-01-29 12:21:20 +01:00
Robin Appelman 41382ef7fc Merge pull request #13667 from owncloud/rename-always-update-cache
Update the cache when renaming even if we dont emit hooks
2015-01-28 17:15:11 +01:00
Martin 21e3cd38ae Write the parameter 'logtimezone' into config.php during setup 2015-01-28 13:45:13 +01:00
Robin Appelman 8c9f1a982c Update the cache when renaming even if we dont emit hooks 2015-01-28 13:44:39 +01:00
Lukas Reschke 20199dd168 Reference module with `.c`
Fixes https://github.com/owncloud/core/issues/13657
2015-01-28 13:15:32 +01:00
Morris Jobke 1efb1fee11 Merge pull request #13700 from owncloud/dav-objecttree-required-a-collection
let init() take a ICollection or an INode - fixes PHP message
2015-01-28 01:14:47 +01:00
Morris Jobke 752b94d363 Merge pull request #13717 from owncloud/storage-donotwrapnullstorage
Prevent wrapping null storage
2015-01-28 01:00:20 +01:00
Morris Jobke 87b39e8f03 Merge pull request #13525 from owncloud/s2s-fixscanfileforbrokenstorage
Catch storage exception in scanner for remote shares
2015-01-28 00:31:37 +01:00
Vincent Petry 6d8985b671 Prevent wrapping null storage
Can happen when trying to instantiate external storages that have
incomplete config, where the constructor throws an exception (the
exception is caught in createStorage())
2015-01-27 17:40:08 +01:00
Bernhard Posselt 3fa6e0f4dc Merge pull request #13718 from owncloud/use-proper-namespace
Use proper namespace
2015-01-27 17:39:35 +01:00
Lukas Reschke bedf358b40 Use proper namespace
IAppManager lives in OCP\App and not in OCP.

Fixes https://github.com/owncloud/core/issues/13710
2015-01-27 17:34:25 +01:00
Vincent Petry acec40fe5a Merge pull request #13561 from owncloud/trash-finaldeletewhencrossstoragefix
Call final unlink in trash wrapper's storage
2015-01-27 17:05:38 +01:00
Morris Jobke 4d90fd933f Merge pull request #13699 from owncloud/check-if-file-exists
Use `file_exists` to verify that config file exists
2015-01-27 14:16:40 +01:00
Lukas Reschke 9771ead7dd Merge pull request #13701 from owncloud/disable-appcode-checker
disable the app code checker - some previous shipped apps cannot be inst...
2015-01-27 11:53:03 +01:00
Thomas Müller b7cf4d551e let init() take an INode - fixes PHP message 2015-01-27 11:31:37 +01:00
Thomas Müller 956de27e94 Merge pull request #13676 from owncloud/fix-node-iface
Fix node interface
2015-01-27 09:34:59 +01:00
Thomas Müller 9a75304b02 disable the app code checker - some previous shipped apps cannot be installed from the appstore now 👊 2015-01-27 09:27:38 +01:00
Thomas Müller f248ee013b Merge pull request #13694 from owncloud/little-bit-more-descriptive-htaccess-error
Make error more descriptive
2015-01-27 09:15:57 +01:00
Lukas Reschke 17f2cfbb9c Use `file_exists` to verify that config file exists
There might be the case that `fopen($file, 'r')` returns false and thus ownCloud might believe that the config file is empty and thus potentially leading to an overwrite of the config file.

This changeset introduces `file_exists` again which was used in ownCloud 5 where no such problems where reported and should not be affected by such problems.

Ref https://github.com/owncloud/core/issues/12785#issuecomment-71548720
2015-01-27 00:50:14 +01:00
Lukas Reschke d8559dc78f Make error more descriptive
Ref https://github.com/owncloud/core/issues/13693#issuecomment-71546767
2015-01-26 23:00:15 +01:00
Bjoern Schiessle 5ba19ba7fc certificate manager should always use a \OC\Files\View otherwise we will get problems for different primary storages 2015-01-26 16:58:52 +01:00
Bjoern Schiessle 67da1f7e5a certificate manager only needs the user-id, no need to pass on the complete user object 2015-01-26 16:58:52 +01:00
Bernhard Posselt b8769802df fix node interface 2015-01-26 15:58:41 +01:00
Vincent Petry 87ce64c24e Replace OC_Log::ERROR with OCP\Util::ERROR 2015-01-26 15:51:31 +01:00
Vincent Petry f6e644b43f Catch storage exception in scanner for remote shares
Whenever an exception occurs during scan of a remote share, the share is
checked for availability. If the storage is gone, it will be removed
automatically.

Also, getDirectoryContent() will now skip unavailable storages.
2015-01-26 13:59:49 +01:00
Thomas Müller 5da4071c45 Merge pull request #13621 from owncloud/system-config-multiset
Add a method to set/unset multiple config values with one write
2015-01-26 13:36:22 +01:00
Thomas Müller 9ad9d7bfbb naming fixes while reviewing 2015-01-26 12:59:25 +01:00
Olivier Paroz 7fbf1a20d7 Updated the media type of some font types
TTF and TTF have now the same media type
Official since 2013 and supported by Firefox and Chrome
https://www.iana.org/assignments/media-types/application/font-sfnt

Introducing support for Type1 fonts
2015-01-24 01:49:13 +01:00
Clark Tomlinson f8b1fde2c0 Merge pull request #13626 from owncloud/check-for-hhvm
Don't check for `always_populate_raw_post_data` on HHVM
2015-01-23 10:28:47 -05:00
Robin Appelman 87a1b2bdc4 Preserve mtime when doing cross storage move 2015-01-23 15:11:27 +01:00
Vincent Petry 8fa3e7a6bf Do not retrieve shares through group if user has no group 2015-01-23 15:11:06 +01:00
Joas Schilling 039397bd31 Use setConfigs() instead of calling setConfig() multiple times 2015-01-23 14:52:21 +01:00
Lukas Reschke 30a5758a95 Don't check for `always_populate_raw_post_data` on HHVM
HHVM seems to have problems with this at the moment (even setting those values in the php.ini of HHVM doesn't have helped much) and thus the unit test execution failed.

So it's better if we disable this check for now for HHVM.
2015-01-23 13:54:34 +01:00
Robin Appelman 960ff4f136 Apply wrappers to existing mounts before registering it 2015-01-23 13:48:35 +01:00
Vincent Petry 5fb8a4715d removeStorageWrapper to unregister a storage wrapper 2015-01-23 12:20:54 +01:00
Joas Schilling c61e9f3912 Add a method to set/unset multiple config values in one call
This reduces the number of file writes we do for config.php and therefor
hopefully helps lowering the chances for empty config.php files
2015-01-23 11:00:53 +01:00
Morris Jobke 7e4afa3f25 Merge pull request #13593 from owncloud/add-check-for-raw-post-data
Add check for `HTTP_RAW_POST_DATA` setting for >= 5.6
2015-01-22 23:59:52 +01:00
Morris Jobke 254a1fa12a Merge pull request #13314 from owncloud/login-hook-logout
Return false if the login is canceled in a hook
2015-01-22 23:34:19 +01:00
Thomas Müller 5776bfec05 Merge pull request #13449 from owncloud/image_preview_limit
add config-option for an image's maximum filesize when generating previews
2015-01-22 23:02:38 +01:00
Georg Ehrke 3af8bde949 add config-option for an image's maximum filesize when generating previews 2015-01-22 20:21:37 +01:00
Georg Ehrke 6b33481652 remove insane debug-log from OC_Image 2015-01-22 20:17:25 +01:00
Thomas Müller 8f06bf7bc6 Merge pull request #13598 from owncloud/fix-undefined-offset
Fix undefined offset 1 for wrong user mail address
2015-01-22 17:16:23 +01:00
Vincent Petry 6fb553e92c Do not call wrapStorage if storate with same name added twice 2015-01-22 16:24:24 +01:00
Morris Jobke 3d42ecea37 Fix undefined offset 1 for wrong user mail address
* fixes Undefined offset: 1 at lib/private/mail.php#143
2015-01-22 16:23:50 +01:00
Thomas Müller f4a9164660 Merge pull request #13600 from owncloud/server-warning
Get rid of log warning when using servercontainer
2015-01-22 16:03:54 +01:00
Bernhard Posselt 9df297324f get rid of log warning when using servercontainer 2015-01-22 15:33:09 +01:00
Morris Jobke 55c28608c9 translate error messages 2015-01-22 14:52:47 +01:00
Robin Appelman 8eda661761 Throw an exception when login is canceled by an app 2015-01-22 14:13:17 +01:00
Robin Appelman 8a9acc5083 Allow custom error messages for the login page 2015-01-22 14:13:02 +01:00
Lukas Reschke bb80cf4eca Add check for `HTTP_RAW_POST_DATA` setting for >= 5.6
PHP 5.6 otherwise throws notices for perfectly valid code which results in broken endpoints.

Fixes https://github.com/owncloud/core/issues/13592
2015-01-22 13:50:38 +01:00
Morris Jobke b5b491d1bb Merge pull request #13509 from owncloud/share-deletechildrenwhenunsharefromgroup
Fix reshare permission change to not impair other deletion code
2015-01-22 10:40:29 +01:00
Vincent Petry 9f137ac259 Fix reshare permission change to not impair other deletion code
A recent change that prevents reshare permission changes to delete group
share children had the side-effect of also preventing group share
children deletion when it needed to be done.

This fix adds an extra flag to isolate the "reshare permission change"
deletion case and keep the other ones as they were before, not only to
fix the regression but also fix other potential regressions in code that
uses this method.

Also updated the comment because now Helper::delete() is no longer
limited to reshares but also applies to group share children.
2015-01-22 10:12:47 +01:00
Thomas Müller c13bf8d820 Merge pull request #13552 from owncloud/request-uri-double-slash
Remove duplicated slashes from the requested url
2015-01-21 21:56:09 +01:00
Joas Schilling d4657aa592 Set the debugoutput channel to error_log instead of echoing it 2015-01-21 15:32:31 +01:00
Robin Appelman 04075eba6b Remove duplicated slashes from the requested url 2015-01-21 15:04:18 +01:00
Thomas Müller 84bb4cc2e9 Merge pull request #13499 from owncloud/issue/13451-redis-json-encode
Issue/13451 redis json encode
2015-01-20 14:53:33 +01:00
Joas Schilling e25998df0f Json_(en|de)code values on redis to be able to cache arrays 2015-01-20 10:51:27 +01:00
Lukas Reschke 476579b9c6 Fix WebDAV auth for session authentication only
\Sabre\DAV\Auth\Backend\AbstractBasic::authenticate was only calling \OC_Connector_Sabre_Auth::validateUserPass when the response of \Sabre\HTTP\BasicAuth::getUserPass was not null.

However, there is a case where the value can be null and the user could be authenticated anyways: The authentication via ownCloud web-interface and then accessing WebDAV resources. This was not possible anymore with this patch because it never reached the code path in this scenario.

This patchs allows authenticating with a session without isDavAuthenticated value stored (this is for ugly WebDAV clients that send the cookie in any case) and thus the functionality should work again.

To test this go to the admin settings and test if the WebDAV check works fine. Furthermore all the usual stuff (WebDAV / Shibboleth / etc...) needs testing as well.
2015-01-20 10:03:14 +01:00
Morris Jobke 870bc429b2 Merge pull request #13416 from owncloud/reauthenticate-if-session-differs-from-basic-auth
Prioritise Basic Auth header over Cookie
2015-01-19 22:23:02 +01:00
Lukas Reschke cbffaff7a0 Merge pull request #13480 from owncloud/mysql-autocommit
set MySQL autocommit on connection setup
2015-01-19 19:39:26 +01:00
Thomas Müller baefefbbc8 set MySQL autocommit on connection setup 2015-01-19 17:20:49 +01:00
Vincent Petry ef8d38ca27 Fix chunked query for tags + unit test 2015-01-19 17:05:44 +01:00
Lukas Reschke 730460c9fa Close session properly 2015-01-19 16:25:44 +01:00
Thomas Müller 65041440de check is mimetype is set - fixed #13452 2015-01-19 15:04:53 +01:00
Morris Jobke a28d3b594b Fix exif orientation for flipped images
fixes #13363

Links:
 * http://www.daveperrett.com/articles/2012/07/28/exif-orientation-handling-is-a-ghetto/
 * Example data: https://github.com/recurser/exif-orientation-examples
2015-01-18 23:15:52 +01:00
Thomas Müller d2d6472e39 Merge pull request #13423 from owncloud/share-fixfindshareforuserwithmultiplegroups
Fix getItemSharedWithUser for groups
2015-01-19 12:34:28 +01:00
Thomas Müller 4fcfedb03c Merge pull request #13438 from owncloud/cache-the-array
Reuse the array key of mimetypes
2015-01-19 08:40:25 +01:00
Lukas Reschke 309cc9a6ca Reuse the array key of mimetypes
This function is called a lot of times and was really slow before due to not reusing the same array.

Previously when it was called 500'000 times it took about 2seconds, now we're down to 0.2 seconds on my local machine.

Ref https://github.com/owncloud/core/issues/13434
2015-01-18 14:50:34 +01:00
Lukas Reschke dfbc405a45 Prioritise Basic Auth header over Cookie
There are a lot of clients that support multiple WebDAV accounts in the same application. However, they resent all the cookies they received from one of the accounts also to the other one. In the case of ownCloud this means that we will always show the user from the session and not the user that is specified in the basic authentication header.

This patch adds a workaround the following way:

1. If the user authenticates via the Sabre Auth Connector add a hint to the session that this was authorized via Basic Auth (this is to prevent logout CSRF)
2. If the request contains this hint and the username specified in the basic auth header differs from the one in the session relogin the user using basic auth

Fixes https://github.com/owncloud/core/issues/11400 and https://github.com/owncloud/core/issues/13245 and probably some other issues as well.

This requires proper testing also considering LDAP / Shibboleth and whatever instances.
2015-01-17 13:29:07 +01:00
Lukas Reschke 744cf713f7 Merge pull request #13319 from owncloud/replace-line-breaks-in-app-description
replace line breaks in the app description by spaces - fixes #13315
2015-01-17 01:03:41 +01:00
Robin McCorkell 2b99fc76ec Cleanup of PHPDoc return types 2015-01-16 20:30:43 +00:00
Vincent Petry 40931a8b0d Fix getItemSharedWithUser for groups
Fixed SQL query for whenever a user has more than one group.
Added missing $owner where clause for group lookup.
Added unit tests for the group cases.
2015-01-16 18:11:13 +01:00
Morris Jobke 0f0204ee35 Merge pull request #13160 from owncloud/extstorage-ocbackendnopartfile
Disable part files for OC ext storage backend + s2s backend
2015-01-16 13:38:59 +01:00
Lukas Reschke a1e92d61b3 Fix PHPDoc 2015-01-15 22:50:42 +01:00
Robin Appelman 2248e465af Remove children from the cache in one query 2015-01-15 17:26:12 +01:00
Bernhard Posselt bb0c88a577 always set url parameters when they are available in the app dispatch
prefer url parameters passed into the main method. If they are not present, use the containers urlParameters

add space
2015-01-15 15:22:52 +01:00
Thomas Müller 337c43ce92 Merge pull request #13317 from owncloud/partfile-fileinfo
Return valid fileinfo objects for part files
2015-01-14 22:39:19 +01:00
Morris Jobke 64d7463ca3 Merge pull request #13344 from owncloud/issue/13334-cleanup-tags-repairstep
Add a repair step to clean up orphan tags and tag entries
2015-01-14 20:43:23 +01:00
Morris Jobke 455ad005a0 Merge pull request #13350 from owncloud/autoload-translations
Autoload app's js translations
2015-01-14 18:12:05 +01:00
Joas Schilling a22068cce3 Add a repair step to clean up orphan tags and tag entries 2015-01-14 16:49:25 +01:00
Bernhard Posselt 6737dd111d ignore core 2015-01-14 15:27:37 +01:00
Bernhard Posselt 4ec4914bb4 move check into addTranslation method 2015-01-14 14:57:56 +01:00
Bernhard Posselt 1cce1f0e6b dont load core scritps 2015-01-14 14:43:11 +01:00
Morris Jobke 520d8ec53b OC_App::parseAppInfo
* replace line breaks (on non empty lines) in the app description by spaces
* fixes #13315
* includes unit tests
2015-01-14 13:58:31 +01:00
Bernhard Posselt d6f1ff7993 only load translsations for apps 2015-01-14 13:48:21 +01:00
Bernhard Posselt 8cb60b2366 make translation lookup faster (O(n) -> O(1)) 2015-01-14 13:39:29 +01:00
Bernhard Posselt 717e3acd9b autoload app's js translations 2015-01-14 13:34:52 +01:00
Joas Schilling 4b3a3dc0bb Check new and old ways of required oC version for app compatibility 2015-01-14 13:02:02 +01:00
Björn Schießle 5745b68fa9 Merge pull request #13311 from owncloud/fix_restore_keys
adapt decrypt all to the new folder structure
2015-01-14 11:40:22 +01:00
Lukas Reschke a2e355a7fe Use "HTTPOnly" for cookies when logging out
This has no other reason than preventing some insane automated scanners from reporting this as security bug (which it obviously isn't as the cookie contains nothing of value)

Thus it generally results in an happier Lukas and hopefully less reports to our support and security mail addresses...
2015-01-14 11:20:53 +01:00
Morris Jobke c8fa85451c Merge pull request #13320 from owncloud/fix-php-doc-for-files-view
Fix annotations in file view
2015-01-13 18:05:00 +01:00
Morris Jobke 0a400b4577 drop unused parameter 2015-01-13 18:04:20 +01:00
Lukas Reschke d66facc762 Fix annotations in file view 2015-01-13 14:53:00 +01:00
Robin Appelman 96dff341e2 Return valid fileinfo objects for part files 2015-01-13 13:59:28 +01:00
Morris Jobke 7746ac519f drop dead code - ref #13301 2015-01-13 13:52:25 +01:00
Thomas Müller 543fa0d45b Merge pull request #13291 from owncloud/node-searchcommonbasepathfix
Fix searchCommon to properly match path name
2015-01-13 13:25:51 +01:00
Robin Appelman 857695ec87 Return false if the login is canceled in a hook 2015-01-13 13:25:20 +01:00
Bjoern Schiessle 89f17ef6fe adapt decrypt all and restore/delete key backups to the new folder structure for encryption key introduced with OC8 2015-01-13 12:45:33 +01:00
Vincent Petry a2a7a60293 Merge pull request #13301 from owncloud/drop-etag-message
drop useless "!!! No reuse of etag" - fixes #13187
2015-01-13 12:24:24 +01:00
Robin McCorkell 79804166f1 Merge pull request #13305 from owncloud/remove-stray-minus-and-use-json-encode
Use json_encode on string
2015-01-13 10:39:14 +00:00
Lukas Reschke f0ac8a278a Use json_encode on string
It's better to encode the string to prevent possible (yet unknown) bugs in combination with PHP's type juggling.

Previously the boolean statements evaluated to either an empty string (false) or a not empty one (true, then it was 1). Not it always evaluates to false or true.

This also removes a stray - that was not intended there but shouldn't have produced any bugs. Just to increase readability.

Thanks @nickvergessen for spotting.

Addresses https://github.com/owncloud/core/pull/13235/files#r22852319
2015-01-13 11:08:18 +01:00
Morris Jobke dc86cbd1e2 Merge pull request #13271 from owncloud/fix-table-prefix-oracle-master
Use a special filter expression for Oracle to filter the prefix - fixes ...
2015-01-13 10:31:04 +01:00
Morris Jobke 9b49b52fc6 drop useless "!!! No reuse of etag" - fixes #13187 2015-01-13 09:54:48 +01:00
Thomas Müller 7966eee007 Adding repair step to fix missing etags - fixes #12172 2015-01-12 20:20:19 +01:00
Vincent Petry fcc3b3d5f7 Fix searchCommon to properly match path name
The internal path was matched without the last "/" which caused
"files_trashbin" to also match when the internal path was "files".

This adds the missing slash for the comparison.
2015-01-12 19:33:00 +01:00
Thomas Müller 1d2bef0a01 Use a special filter expression for Oracle to filter the prefix - fixes #13220 2015-01-12 16:28:11 +01:00
Morris Jobke c91d47e5b3 Merge pull request #13224 from owncloud/simplify-is-valid-path-and-add-unit-tests
Simplify isValidPath and add unit tests
2015-01-10 17:35:40 +01:00
Morris Jobke c259733b88 Merge pull request #13223 from owncloud/optimize-normalize-unicode
Verify whether value is already normalized
2015-01-10 16:33:54 +01:00
Morris Jobke 8057bc6646 Merge pull request #13236 from owncloud/use-isset-for-performance
Use isset() instead of strlen()
2015-01-10 16:32:50 +01:00
Lukas Reschke e80ece9a2b Verify whether value is already normalized
Apparently `normalizer_normalize` is not verifying itself whether the string needs to be converted or not. Or does it at least not very performantly.

This simple change leads to a 4% performance gain on the processing of normalizeUnicode. Since this method is called quite often (i.e. for every file path) this has actually a measurable impact. For examples searches are now 200ms faster on my machine. Still not perfect but way to go.

Part of https://github.com/owncloud/core/issues/13221
2015-01-10 12:12:40 +01:00
Lukas Reschke 310424db5d Use isset() instead of strlen()
Isset is a native language construct and thus A LOT faster than using strlen()

On my local machine this leads to a 1s performance gain for about 1 million paths. Considering that this function will be called a lot for every file operation this makes a noticable difference.
2015-01-10 12:06:51 +01:00
Lukas Reschke 7e11ca06f6 Cache results of `normalizePath`
`normalizePath` is a rather expensive operation and called multiple times for a single path for every file related operation.

In my development installation with about 9GB of data and 60k files this leads to a performance boost of 24% - in seconds that are 1.86s (!) - for simple searches. With more files the impact will be even more noticeable. Obviously this affects every operation that has in any regard something to do with using OC\Files\Filesystem.

Part of https://github.com/owncloud/core/issues/13221
2015-01-10 11:10:38 +01:00
Lukas Reschke 05615bfd47 Simplify isValidPath and add unit tests
The check for invalid paths is actually over-complicated and performed twice resulting in a performance penalty. Additionally, I decided to add unit-tests to that function.

Part of https://github.com/owncloud/core/issues/13221
2015-01-10 00:40:21 +01:00
Lukas Reschke b8b4df5425 Cache responses from the AppStore server
Otherwise every time the AppStore was opened a lot of connections to the AppStore server were made which resulted in a terrible performance.

This changeset will cache the response for a sensible time so that only the first request will be somewhat slow.

Performance changes:
- Loading a category took previously more than 3 seconds on my machine. Now for every follow-up request it takes less than 200ms, resulting in a performance gain of 1950%
- Loading the category list took previously about 750ms - now it takes 154ms, a total performance gain of 395%
2015-01-09 19:49:59 +01:00
Thomas Müller d4355cafc6 Merge pull request #13192 from owncloud/cache_binary_path
Use memcache for findBinaryPath
2015-01-09 17:46:36 +01:00
Robin McCorkell 631d6571fd Merge pull request #13181 from owncloud/filecache-preventleadingslash
Trim leading or trailing slashes in file cache paths
2015-01-09 13:54:17 +00:00
Morris Jobke 800738f51a Merge pull request #12011 from owncloud/reuse-etag-default
Default to reusing etags in the scanner
2015-01-09 14:38:45 +01:00
Robin McCorkell c291383116 Memcache binary executable searching
It's slow, this makes it fast!
2015-01-09 13:18:00 +00:00
Robin McCorkell 17dd5d0816 Add Null memcacher 2015-01-09 13:18:00 +00:00
Thomas Müller 1f1643b35f Merge pull request #12995 from owncloud/tbelau666-master
Use Doctrines filter by table name
2015-01-09 14:17:14 +01:00
Vincent Petry 888ce4d4f9 Fix cache jail to not duplicate slashes 2015-01-09 10:18:32 +01:00
Lukas Reschke 6c59253978 Merge pull request #13179 from owncloud/fix-fatal-php-error-for-not-existing-files
Verify whether type is correct
2015-01-09 02:27:51 +01:00
Morris Jobke 6a5f12beca Merge pull request #12988 from owncloud/logfile_download
Logfile download
2015-01-09 00:33:22 +01:00
Vincent Petry aa821ecc00 Trim leading or trailing slashes in file cache paths 2015-01-08 19:43:02 +01:00
Lukas Reschke ceaaab6295 Verify whether type is correct
`$this->info` can very well contain an empty array or possibly other values. This means that when this code path is called a PHP Fatal error might get thrown which is not what we want.
2015-01-08 18:38:17 +01:00
Lukas Reschke 7fbb7f4dc4 Add version to .htaccess
Currently if a user does not replace the .htaccess file with the new update this can lead to serious problems in case Apache is used as webserver.

This commit adds the version to the .htaccess file and the update routine fails in case not the newest version is specified in there. This obviously means that every release has to update the version specified in .htaccess as well. But I see no better solution for it.

Conflicts:
	lib/private/updater.php
2015-01-08 12:49:02 +01:00
Thomas Müller 5f171618fd remove unused variable and fix undefined variable 2015-01-08 09:46:40 +01:00
Thomas Müller 296a852063 check for working htaccess will result in a dead lock because the server is blocking the request to itself - fixes #13153 2015-01-08 09:13:18 +01:00
Vincent Petry 2e57fe93e4 Disable part files for OC ext storage backend + s2s backend
When uploading files to an OC ext storage backend or when using server
to server sharing storage, part files aren't needed because the backend
already has its own part files and takes care of the final atomic rename
operation.

This also fixes issues when using two encrypted ownCloud instances where
one mounts the other either as external storage (ownCloud backend) or
through server to server sharing.
2015-01-07 21:21:51 +01:00
Morris Jobke bfb6e350d5 Merge pull request #13016 from owncloud/sharing_fixes
don't delete share table entries for the unique name if re-share permission was removed
2015-01-07 18:14:53 +01:00
Bjoern Schiessle b6f63e9b3d don't delete share table entries for the unique name if re-share permission was removed 2015-01-07 16:36:13 +01:00
Georg Ehrke f579f2bd94 add Download logfile button to admin settings
add logSettingsController

add download logfile button

move getEntries to LogSettingsController

move set log level to logsettingscontroller.php

add warning if logfile is bigger than 100MB

add unit test for set log level

fix typecasting, add new line at EoF

show log and logfile download only if log_type is set to owncloud

add unit test for getFilenameForDownload
2015-01-07 14:55:53 +01:00
Morris Jobke fd57820708 Merge pull request #13132 from aptivate/improve_debug_logging_messages
Improve debugging for ServiceUnavailable exceptions
2015-01-07 10:36:27 +01:00
Thomas Müller 4628e98cfc Merge pull request #13063 from AdamWill/assets-relocate
allow css/js asset directory to be relocated ('assetdirectory')
2015-01-07 09:36:26 +01:00
Morris Jobke a8d82b7091 Merge pull request #13131 from owncloud/db-connect-stacktrace
Prevent leaking db connection info in the stacktrace
2015-01-07 01:17:27 +01:00
Lukas Reschke 7528a1a475 Merge pull request #13130 from owncloud/getstoragestats-error-handling
Add error handling to getstoragestats.php
2015-01-06 18:35:09 +01:00
Chris Wilson 402a3ed146 Improve debugging for ServiceUnavailable exceptions
I was getting a lot of these in my logs for no apparent reason, and file
uploads were failing:

	{"app":"webdav","message":"Sabre\\DAV\\Exception\\ServiceUnavailable: ","level":4,"time":"2015-01-06T15:33:39+00:00"}

In order to debug it, I had to add unique messages to all the places where
this exception was thrown, to identify which one it was, and that made the
logs much more useful:

	{"app":"webdav","message":"Sabre\\DAV\\Exception\\ServiceUnavailable: Encryption is disabled","level":4,"time":"2015-01-06T15:36:47+00:00"}
2015-01-06 15:59:38 +00:00
Robin Appelman 3356308594 Prevent leaking db connection info in the stacktrace 2015-01-06 16:54:41 +01:00
Morris Jobke fe4592937a Merge pull request #12653 from owncloud/full_content_search_results
Full content width search results
2015-01-06 16:44:58 +01:00
Robin Appelman 64e3ebae74 Add error handling to getstoragestats.php 2015-01-06 15:56:06 +01:00
Thomas Müller 68efeba343 Merge pull request #13125 from owncloud/lower-deprecation-warning-level
degraded logging policy for server container in AppFramework
2015-01-06 14:38:50 +01:00
Thomas Müller 20886d8151 Merge pull request #13116 from owncloud/fix_assets
Fix JS asset generation
2015-01-06 14:36:51 +01:00
Morris Jobke 4ffe7ddb75 degraded logging policy for server container in AppFramework 2015-01-06 13:43:40 +01:00
Adam Williamson bb79aac78a allow css/js asset directory to be relocated (#13053)
This allows the directory where CSS/JS asset collections are
written to be changed, in case SERVERROOT is not writeable. Note
it does *not* allow the expected URL to be changed: whatever
directory is used, the server must be configured to serve it
at WEBROOT/assets. It may be possible to add another config
parameter to allow the admin to specify a custom asset URL,
but I thought I'd keep the first implementation simple.
2015-01-05 15:24:23 -08:00
Thomas Müller c0ad6e818b Merge pull request #13101 from owncloud/variable-is-undefined-please-use-a-proper-ide-in-the-future-whoever-did-that
Fix undefined variable and write unit tests for OC_Principal connector
2015-01-05 20:09:10 +01:00
Robin McCorkell 2c44bc1768 Fix JS asset generation
At some point SeparatorFilter should be included upstream
(kriswallsmith/assetic), then lib/private/assetic/separatorfilter.php can be
removed and the `use` in lib/private/templatelayout.php rewritten.

SeparatorFilter inserts a separator between assets, preventing issues when
files are incorrectly terminated. For JS this is a semicolon.
2015-01-05 15:48:04 +00:00
Lukas Reschke 8689605999 Use info instead of warning log level
Otherwise the log is flooded as can be seen at https://github.com/owncloud/core/issues/13106

Fixes https://github.com/owncloud/core/issues/13106
2015-01-05 11:18:54 +01:00
Lukas Reschke 0ed00bca43 Use namespace 2015-01-05 09:54:14 +01:00
Lukas Reschke 556c9b6f46 Write unit-tests and use DI 2015-01-05 09:54:12 +01:00
Lukas Reschke f2ddd565e8 Fix code-style 2015-01-05 09:53:01 +01:00
derkostka deedfad050 fix "app":"PHP","message":"Undefined variable: user at/principal.php#66"
changed variable #user to #name
2015-01-04 17:07:33 +01:00
Jörn Friedrich Dreyer 606f802b7b move search results below filelist, show hint when results are off screen, use js plugin mechanism 2015-01-02 10:28:41 +01:00
Jörn Friedrich Dreyer 0e9b05b701 ajax paging, some js cleanups 2015-01-02 10:28:41 +01:00
Jörn Friedrich Dreyer c738359a11 add paged provider 2015-01-02 10:28:41 +01:00
Jörn Friedrich Dreyer d3662722f6 new OC.Search, add search result formatters and handlers, use full content width for results 2015-01-02 10:28:41 +01:00
dratini0 31970ee740 removed a little duplication 2014-12-30 22:36:13 +01:00
dratini0 f2075f803f Fix: X-Accel-Redirect did not support custom data dir and local mounts 2014-12-30 22:07:04 +01:00
Thomas Müller 81243b0f5d adding getDirectDownload() to Wrapper 2014-12-28 17:17:14 +01:00
Thomas Müller 5b00bc1d6e Adding basement for the direct download url 2014-12-28 17:17:14 +01:00
Thomas Müller aec79b0c0e Merge pull request #13043 from owncloud/check-for-hash
Check for hash
2014-12-28 14:12:57 +01:00
Lukas Reschke 222e4a0762 Check for hash
See https://github.com/owncloud/core/pull/13042
2014-12-28 13:23:34 +01:00
Frank Karlitschek 4a40e5699c remove Edition 2014-12-25 11:36:41 +01:00
Frank Karlitschek 3dea2b95c6 Automatically detect the edition based on the enterprise_key app. 2014-12-25 09:48:15 +01:00
Morris Jobke 95374e1404 add default for dbtableprefix 2014-12-23 13:32:25 +01:00
Bernhard Posselt f195123765 Intelligent container
* resolves dependencies by type hint or variable name
* simpler route.php
* implementation of https://github.com/owncloud/core/issues/12829

Generates and injects parameters automatically. You can now build full classes like

    $c->query('MyClassName')

without having to register it as a service. The resolved object's instance will be saved by using registerService. If a constructor parameter is not type hinted, the parameter name will be taken.

Therefore the following two implementations are identical:

    class Class1 { function __construct(MyClassName $class)
    class Class1 { function __construct($MyClassName)

This makes it possible to also inject primitive values such as strings, arrays etc.

In addition if the query could not be resolved, a `QueryException` is now thrown

Routes can now be returned as an array from `routes.php` and an `appinfo/application.php` is optional

Old commit messages:

make it possible to return the routes instead of having to intialize the application
try to get the controller by convention
add first implementation of automatic resolve
add another test just to be sure
store the resolved object
more tests
add phpdoc to public app.php method
use the same variable for the public app.php method
deprecate old methods and add services for public interfaces
deprecated getServer method
disallow private api injection for apps other than core or settings (settings should be an app goddamnit :D)
register userid because its such an often used variable
fix indention and leading slash
use test namespace
add deprecation reasons, remove private api usage checks and remove deprecation from getServer()
add additional public interfaces
add public interface for rootfolder
fix syntax error
remove deprecation from methods where no alternative is there yet
remove deprecated from method which has no alternative
add timezone public service for #12881
add another deprecation hint
move deprecation into separate branch
remove dead comment
first try to get the namespace from the info.xml, if it does not exist, just uppercase the first letter
also trim the namespace name
add an interface for timefactory
move timefactory to public and add icontrollermethodreflector
keep core interface
fix copyright date in headers
2014-12-23 09:50:42 +01:00
Morris Jobke dbc465de97 use injected config object and fix typos 2014-12-22 10:55:52 +01:00
Morris Jobke de25084def inject \OCP\IConfig instance in migrator 2014-12-22 10:47:10 +01:00
tbelau666 ad8d55c327 Use Doctrines filter by table name
Doctrine's SchemaManager can filter table names by regular expression.
On this way it picks up only ownClouds's tables in a database.

by tbelau666
2014-12-22 10:45:32 +01:00
Morris Jobke 5d296aa6b1 Merge pull request #12969 from owncloud/clarify-docs
Clarify return values
2014-12-22 10:01:39 +01:00
Morris Jobke c17b9ec068 Merge pull request #12983 from owncloud/root-iface
Add an interface for the root folder so apps have an interface to deal with storage
2014-12-22 09:05:23 +01:00
Bernhard Posselt 8e37214346 add an interface for the root folder so apps have an interface to deal with storage
fix comments and newline

add newline
2014-12-21 20:52:34 +01:00
Thomas Müller dc12f5d9af Merge pull request #12978 from owncloud/fix-support-claim
Change support message to be more explicit about the enterprise edition
2014-12-21 20:30:43 +01:00
Thomas Müller c3544bd27e Merge pull request #12982 from owncloud/timefac-iface
Add an interface for the timefactory class
2014-12-21 20:27:53 +01:00
Bernhard Posselt ba03b0b843 add an interface for the timefactory class
fix indention
2014-12-20 15:53:31 +01:00
Morris Jobke 5383d83f9e Change support message to be more explicit about the enterprise edition 2014-12-20 11:57:15 +01:00
derkostka 1c22b1f626 Fix Undefined variable: result at tags.php#231
Fix app":"PHP","message":"Undefined variable: result at \/var\/www\/owncloud\/lib\/private\/tags.php#231" by moving the function call into the respective loop

Adjust indentation

Do it right - indentation

sorry, this is my first one
2014-12-19 19:44:43 +01:00
Björn Schießle 8164415b45 Merge pull request #12749 from owncloud/server2server-sharing-ng
server to server sharing next generation
2014-12-19 19:04:44 +01:00
blizzz ad6814f920 Merge pull request #12101 from owncloud/ldap_split_mapping
Ldap split mapping from Access superclass
2014-12-19 18:52:30 +01:00
Arthur Schiwon ec0f80fee9 Split mapping from Access and Helper classes into it's own. Fully test them, too.
remove unused methods

split mapping methods off from Access class

fix DB query handling

move 'clear mapping' methods from static helper to new mapping class

add tests

test directly with DB

finishing tests and fix return value from setDNbyUUID

add corresponding class for groups and make abstract test class neutral. helper tests is now obsolete as the tested functions were moved to the new mapper class.

add missing info to PHPDoc

add unmap method

fix namespaces

fix test inheritance

PHPDoc and a small code restructure for scrutinizer, no effective changes

PostgreSQL does not accept LIMIT in DELETE queries

phpdoc fixes, no code changes
2014-12-19 18:26:12 +01:00
Bjoern Schiessle 24993280ed Next step in server-to-server sharing next generation, see #12285
Beside some small improvements and bug fixes this will probably the final state for OC8.

To test this you need to set up two ownCloud instances. Let's say:

URL: myPC/firstOwnCloud user: user1
URL: myPC/secondOwnCloud user: user2
Now user1 can share a file with user2 by entering the username and the URL to the second ownCloud to the share-drop-down, in this case "user2@myPC/secondOwnCloud".

The next time user2 login he will get a notification that he received a server-to-server share with the option to accept/decline it. If he accept it the share will be mounted. In both cases a event will be send back to user1 and add a notification to the activity stream that the share was accepted/declined.

If user1 decides to unshare the file again from user2 the share will automatically be removed from the second ownCloud server and user2 will see a notification in his activity stream that user1@myPC/firstOwnCloud has unshared the file/folder from him.
2014-12-19 15:20:24 +01:00
Lukas Reschke f671b232cc Merge pull request #12923 from owncloud/ultra-slim-version-of-incognito-mode
Add ultra-slim hack for incognito mode
2014-12-19 14:54:11 +01:00
Lukas Reschke dbbf568192 Fix typo 2014-12-19 14:36:00 +01:00
Lukas Reschke a022e65285 Clarify return values
This function returns `null` when no user is logged-in.
2014-12-19 14:17:40 +01:00
Thomas Müller 2d64797320 Merge pull request #12956 from owncloud/jenkins-user-backend-names
[jenkins only] introduce names for user backends - IUserBackend
2014-12-19 13:15:50 +01:00
Lukas Reschke 157ff1219a Merge pull request #12954 from owncloud/hhvm-apc-clear
HHVM: In APC cache clear, only request the cache key in APCIterator.
2014-12-19 10:46:20 +01:00
Morris Jobke 6b3600d2bf Merge pull request #12918 from owncloud/use-uid-instead-of-login-name
Return UID instead of login name
2014-12-19 10:24:52 +01:00
Morris Jobke 6da33e1ea7 introduce names for user backends - IUserBackend
* LDAP with multiple servers also proved backendName
2014-12-19 10:17:17 +01:00
Morris Jobke 39d6ddd38a Merge pull request #12865 from owncloud/files-tags-webdav
Returns tags through WebDAV
2014-12-19 09:33:28 +01:00
Andreas Fischer 0ba5c182f0 HHVM: In APC cache clear, only request the cache key in APCIterator.
The default value of the $format parameter of the APCIterator constructur is
APC_ITER_ALL which instructs the iterator to provide all available information
on cache values being iterated over. Only the key value is necessary for
matching and deletion via apc_delete(), though.

This prevents a "Format values FILENAME, DEVICE, INODE, MD5, NUM_HITS, MTIME,
CTIME, DTIME, ATIME, REFCOUNT not supported yet." notice on HHVM.
2014-12-19 03:24:00 +01:00
Morris Jobke 114a6464e8 Merge pull request #12748 from owncloud/redis_cache
Add Redis cache implementation, prefer over memcached, tests & config sample doc
2014-12-19 00:26:25 +01:00
Morris Jobke 75e8b39826 Merge pull request #12879 from owncloud/mountconfig
Add mount specific options
2014-12-18 23:38:14 +01:00
Jörn Friedrich Dreyer 891474b0d6 Merge pull request #12759 from owncloud/core-reduce-js-and-css
make sure styles and scripts are only loaded once
2014-12-18 23:18:37 +01:00
Morris Jobke 609e10238f Merge pull request #12945 from owncloud/hhvm-image
HHVM: Do not call filesize(null), this function expects a string.
2014-12-18 22:20:56 +01:00
Andreas Fischer 3ebb69944b Do not call filesize(null), this function expects a string.
filesize(null) yields an int on HHVM and thus exif_imagetype(null) is called.
2014-12-18 20:57:19 +01:00
Morris Jobke 85301c8b85 Merge pull request #12940 from drarko/master
Fix extra quotes in custom tags in header
2014-12-18 18:44:44 +01:00
Vincent Petry 6224e29f25 Fix code style issues for tags plugin 2014-12-18 16:43:00 +01:00
drarko faaa1a89cb Fix extra quotes in custom tags in header
Fix #12939
2014-12-18 12:40:08 -03:00
Robin Appelman 1ef01de402 Merge pull request #12907 from owncloud/delete-invalid-external-share
Fix deleting invalid s2s shares
2014-12-18 16:38:13 +01:00
Vincent Petry 3c67900421 Remove obsolete method 2014-12-18 16:04:36 +01:00
Robin McCorkell 619dcae7af Merge pull request #12901 from owncloud/move-ldap-check-to-manager
Move the Null-Byte LDAP check to the user manager
2014-12-18 00:28:00 +00:00
Robin McCorkell d83fdd7f9d Merge pull request #12913 from owncloud/hhvm-memcached-clear
HHVM: Add workaround for missing Memcached::deleteMulti()
2014-12-18 00:27:07 +00:00
Morris Jobke 232d4385f4 Merge pull request #12917 from owncloud/fix-ocs-12915-api
Move basic auth login out of `isLoggedIn`
2014-12-18 00:57:22 +01:00
Lukas Reschke e3230b5bc2 Add ultra-slim hack for incognito mode
As discussed at https://github.com/owncloud/core/pull/12912#issuecomment-67391155
2014-12-17 21:53:43 +01:00
Morris Jobke 3d006207d1 Merge pull request #12892 from owncloud/is-addmin
Add isAdmin and isInGroup methods for the group manager
2014-12-17 21:40:26 +01:00
Lukas Reschke 9031d79597 Return UID instead of login name
Without this OCS on LDAP is broken for API requests coming via Basic Authentication...
2014-12-17 20:33:22 +01:00
Lukas Reschke a02b00445e Store result of authentication 2014-12-17 20:22:51 +01:00
Lukas Reschke b91a435ed4 Move basic auth login out of `isLoggedIn`
Potentially fixes https://github.com/owncloud/core/issues/12915 and opens the door for potential other bugs...

Please test very carefully, this includes:

- Testing from OCS via cURL (as in #12915)
- Testing from OCS via browser (Open the "Von Dir geteilt" shares overview)
- WebDAV
- CalDAV
- CardDAV
2014-12-17 20:12:14 +01:00
Andreas Fischer fcf3c5197f HHVM: Add workaround for missing Memcached::deleteMulti() 2014-12-17 18:10:11 +01:00
Bernhard Posselt 6779bf113d add isAdmin and isInGroup methods for the group manager 2014-12-17 17:41:57 +01:00
Bernhard Posselt 236632702c add a isLoggedIn method to the usersession and deprecate the isLoggedIn method on the api 2014-12-17 17:40:52 +01:00
Andreas Fischer 8c509c3437 HHVM: Call libxml_use_internal_errors() instead of surpressing errors.
In contrast to the previous solution, this also works on HHVM.
2014-12-17 17:00:10 +01:00
Vincent Petry 0b3f0716fc Returns and update tags through WebDAV PROPFIND and PROPPATCH
Added oc:tags and oc:favorites in PROPFIND response.
It is possible to update them with PROPPATCH.
These properties are optional which means they need to be requested
explicitly
2014-12-17 16:50:35 +01:00
Robin Appelman 9ddd5033d4 Movable mountpoints are always deletable 2014-12-17 16:09:28 +01:00
Robin Appelman 2eab0f2121 Allow disabling previews per mount 2014-12-17 14:03:50 +01:00
Robin Appelman fd85424742 Add getMountPoint to FileInfo 2014-12-17 14:03:50 +01:00
Robin Appelman 95a145f67f Load mount specific options from the mount config 2014-12-17 14:03:50 +01:00
Lukas Reschke f6820406b6 Move the Null-Byte LDAP check to the user manager
The existing method is deprecated and just a wrapper around the manager method. Since in the future other code paths might call this function instead we need to perform that check here.

Related to http://owncloud.org/security/advisory/?id=oc-sa-2014-020
2014-12-17 12:47:00 +01:00
Thomas Müller 77c4c2856a Merge pull request #12889 from owncloud/deprecation-time
Deprecate old and replaced appframework apis
2014-12-17 11:28:01 +01:00
Bernhard Posselt d59c4e832f first round of deprecation 2014-12-16 19:50:31 +01:00
Thomas Müller 775f6a1354 make sure styles and scripts are only loaded once 2014-12-16 18:26:43 +01:00
Joas Schilling 26100a6dfb Move timezone logic out of server.php 2014-12-16 16:16:22 +01:00
Lukas Reschke be3d4fd303 Merge pull request #12360 from owncloud/files-tags
Add favorites to files app
2014-12-15 19:55:18 +01:00
Jörn Friedrich Dreyer 6602d3ac77 Merge pull request #12555 from owncloud/app_specific_search
introduce inApps[] filter for search via ajax query
2014-12-15 16:14:40 +01:00
Morris Jobke d367d1b06a Merge pull request #12839 from oparoz/ControllerMethodReflector
\OCP\AppFramework\Utility\IControllerMethodReflector
2014-12-15 14:20:26 +01:00
Bernhard Posselt be45366013 Merge pull request #12625 from owncloud/app-dependencies-libs-and-commands
adding dependencies for command line tools and php libraries
2014-12-15 12:34:46 +01:00
Thomas Müller e58b9d3eb7 fixing owncloud version 2014-12-15 12:23:56 +01:00
Vincent Petry c6be491a89 Return file info from Node API 2014-12-15 12:10:54 +01:00
Olivier Paroz 469fd3b3a3 Olivier Paroz \OCP\AppFramework\Utility\IControllerMethodReflector 2014-12-14 23:54:31 +01:00
Philipp Knechtges 768aea57d3 make regex in controllermethodreflector.php compatible with PCRE 6.x
The syntax ?<...> seems to be only supported from PCRE 7.0 on. For
backwards-compability ?P<...> is used.
2014-12-14 10:52:21 +01:00
Morris Jobke 5b3971f002 Merge pull request #12639 from owncloud/bad_mtime_format
Fix formatting of bad dates from external storages
2014-12-13 10:07:10 +01:00
Morris Jobke efb495b09f Merge pull request #12726 from owncloud/add-filter-for-backend-to-rest-index
Add filter for backend to rest index
2014-12-13 08:50:15 +01:00
Robin McCorkell fdbb68a3c3 Return ? if mtime is 0 or -1
Tooltip contains 'Unable to determine date'. Fixes #6395
2014-12-12 23:54:18 +00:00
Vincent Petry 4b57892c4e Merge pull request #12778 from owncloud/searchbytags2
Added searchByTags to view, storage and cache
2014-12-12 14:27:19 +01:00
Joas Schilling 4f92e4a233 Merge pull request #12808 from owncloud/add-special-parameterlist-to-manager
Add special parameterlist to manager
2014-12-12 13:03:26 +01:00
Thomas Müller dcb88e395b rework api of DependencyAnalyzer 2014-12-12 12:34:53 +01:00
Vincent Petry b1bef5cc15 Merge pull request #12587 from owncloud/dav-logerrors
Log exceptions in DAV storage
2014-12-12 11:58:04 +01:00
Vincent Petry 3878c3782f Added searchByTag in cache jail wrapper 2014-12-12 11:48:42 +01:00
Vincent Petry 15ecb28d50 Make $userId mandatory for searchByTags
$userId is now a mandatory parameter for searchByTags.

Also fixed some places in the code where the argument was missing (Node
API and View)
2014-12-12 11:18:35 +01:00
Joas Schilling 811f9251d6 Correctly inject the language into the subcall 2014-12-12 11:00:07 +01:00
Morris Jobke e969fe6b12 Merge pull request #12698 from owncloud/handle_readonly_shared_files
Handle readonly shared files
2014-12-12 08:34:28 +01:00
Morris Jobke c56fa64801 Merge pull request #12786 from owncloud/userfolder-setup
Ensure user mountpoints are setup when using getUserFolder
2014-12-11 23:51:49 +01:00
Vincent Petry 25dde7e93b Added searchByTags to view, storage and cache 2014-12-11 17:38:50 +01:00
Thomas Müller d94c1731d7 check app dependencies on installation as well 2014-12-11 17:02:07 +01:00
Thomas Müller 6566dc83e7 single dependencies will not be represented as an array + fix unit tests 2014-12-11 15:37:45 +01:00
Joas Schilling 1b18554aa7 Allow extensions to specify the list of special parameters 2014-12-11 14:56:46 +01:00
Robin Appelman 802c1b0b3a Ensure user mountpoints are setup when using getUserFolder 2014-12-11 14:34:30 +01:00
Morris Jobke 8fd90e04b6 Merge pull request #12781 from owncloud/jenkins-curl-open-basedir
[Jenkins only] curl open basedir
2014-12-11 14:15:24 +01:00
Joas Schilling cbad5c998b Correctly fallback to english, if the plural case is not translated 2014-12-11 12:42:21 +01:00
Lukas Reschke d0716d2c7d Use public interface 2014-12-11 12:29:58 +01:00
Vincent Petry 745d8706b9 Add user parameter to tag manager 2014-12-11 12:22:28 +01:00
Thomas Müller 5a03e0a5cf adding dependency to owncloud version - with fallback to requiremin and requiremax 2014-12-11 12:02:12 +01:00
Thomas Müller ee46548f57 adding dependencies for supported platforms 2014-12-11 12:02:12 +01:00
Thomas Müller 770f987659 adding supported libraries - including min and max version 2014-12-11 12:02:11 +01:00
Thomas Müller 08f1db4451 adding dependencies for command line tools 2014-12-11 12:02:11 +01:00
Thomas Müller c5e279e416 year go -> year ago 2014-12-11 11:30:00 +01:00
Lukas Reschke 9ea205dc3d Check if open_basedir is set
The file:// protocol does not work with curl when an open_basedir is set.

This fixes https://github.com/owncloud/core/issues/12016
2014-12-11 00:09:55 +01:00
Lukas Reschke d84a1f6f3a Add IniGetWrapper to public interface 2014-12-11 00:09:55 +01:00
Morris Jobke e2c51308df Merge pull request #12758 from owncloud/fix-config-doc-block
Add type of the variables to the docs
2014-12-10 17:22:36 +01:00
Thomas Müller 80ae311329 Merge pull request #11892 from owncloud/remove_triggerupdate
Remove triggerupdate.php & add quiet option for CLI scanner
2014-12-10 16:17:29 +01:00
Jörn Friedrich Dreyer 1d490b559c introduce inApps[] filter for search via ajax query, make file results show up in files app only
use more flexible return type

check array with !empty instead of count
2014-12-10 15:51:59 +01:00
Joas Schilling bef7392c4c Add type of the variables to the docs 2014-12-10 15:18:06 +01:00
Robin Appelman 3898fbc0d2 Merge pull request #12750 from owncloud/cache-numericstorageidfix
Fix numeric storage id for cache wrapper
2014-12-10 15:03:41 +01:00
Joas Schilling fd2599cfc2 Merge pull request #12485 from owncloud/jenkins-12383
New DateTimeFormatter class for dates in other timezones and languages
2014-12-10 14:48:59 +01:00
Vincent Petry ebba54d490 Fix numeric storage id for cache wrapper 2014-12-10 13:05:31 +01:00
Jörn Friedrich Dreyer 363e9667ec Add Redis cache implementation, prefer over memcached, tests & config sample 2014-12-10 12:24:20 +01:00
Lukas Reschke 5dc6406b70 Add filter for 'backend' to user REST route
This adds a "backend" type filter to the index REST route which is a pre-requisite for https://github.com/owncloud/core/issues/12620

For example when calling `index.php/settings/users/users?offset=0&limit=10&gid=&pattern=&backend=OC_User_Database` only users within the backend `OC_User_Database` would be shown. (requires sending a CSRF token as well)

Depends upon https://github.com/owncloud/core/pull/12711
2014-12-10 12:07:34 +01:00
Joas Schilling 67335ccddf Require the interface and return a string instead of private classes 2014-12-10 11:58:56 +01:00
Joas Schilling 4d232e536e Deprecate Util::formatDate()
Make DateTimeFormatter a service and adjust tests that have been inaccurate
2014-12-10 11:58:56 +01:00
Lukas Reschke 5398bbdc00 Merge pull request #12711 from owncloud/add-backend-to-rest-index
Expose backend type via REST API
2014-12-10 11:56:45 +01:00
Jörn Friedrich Dreyer 0f17486c1d make path absolute 2014-12-10 11:04:17 +01:00
Thomas Müller 7028c7150d Merge pull request #12664 from owncloud/fix-12164
Use httphelper and cache response even when it is empty
2014-12-10 05:42:08 +01:00
Victor Dubiniuk c9fd3c9d29 Inject config 2014-12-10 01:13:38 +03:00
Morris Jobke 263e008d7b Merge pull request #12695 from owncloud/db-drop-table
Add dropTable to IDBConnection
2014-12-09 18:40:56 +01:00
Robin Appelman 6984fa8a19 Quote identifiers for oracle 2014-12-09 17:26:53 +01:00
Robin Appelman 778d8dbafd Add tableExists to public db api 2014-12-09 17:26:53 +01:00
Robin Appelman 8af3991d0c Add dropTable to IDBConnection 2014-12-09 17:26:53 +01:00
Joas Schilling d69ea30097 Add a DateTimeFormatter class which allows overwriting the language and timezone
Fix #12227
2014-12-09 16:10:24 +01:00
Joas Schilling f53f25eafe Merge pull request #12409 from owncloud/tags-getTagsForObjectIds
Add getTagsForObjects in ITags
2014-12-09 13:27:38 +01:00
Joas Schilling 26861a98c5 Merge pull request #12568 from owncloud/autoload-encryption-classes
Fix namespaces of encryption classes and encryption tests
2014-12-09 12:56:57 +01:00
Lukas Reschke 4c13918bd8 Expose backend type via REST API
This change will expose the user backend via the REST API which is a pre-requisite for https://github.com/owncloud/core/issues/12620.

For example:
````json
[{"name":"9707A09E-CA9A-4ABE-A66A-3F632F16C409","displayname":"Document Conversion User Account","groups":[],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/9707A09E-CA9A-4ABE-A66A-3F632F16C409","lastLogin":0,"backend":"OCA\\user_ldap\\USER_LDAP"},{"name":"ED86733E-745C-4E4D-90CB-278A9737DB3C","displayname":"Hacker","groups":[],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/ED86733E-745C-4E4D-90CB-278A9737DB3C","lastLogin":0,"backend":"OCA\\user_ldap\\USER_LDAP"},{"name":"71CDF45B-E125-450D-983C-D9192F36EC88","displayname":"admin","groups":[],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/71CDF45B-E125-450D-983C-D9192F36EC88","lastLogin":0,"backend":"OCA\\user_ldap\\USER_LDAP"},{"name":"admin","displayname":"admin","groups":["admin"],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/admin","lastLogin":"1418057287","backend":"OC_User_Database"},{"name":"test","displayname":"test","groups":[],"subadmin":[],"quota":"default","storageLocation":"\/Users\/lreschke\/Programming\/core\/data\/test","lastLogin":0,"backend":"OC_User_Database"}]
```
2014-12-09 12:04:19 +01:00
Thomas Müller 5609d421cd Merge pull request #12672 from LEDfan/cm-per-unit
Fix Contactsmanager permission + unit test
2014-12-09 10:57:22 +01:00
Joas Schilling 78a307995c Fix namespace of Files_Encryption outside of the app 2014-12-09 09:47:26 +01:00
Thomas Müller c36bac3abd Merge pull request #12406 from owncloud/drop-getApps-getUsers
Config cleanup - OC_Preferences refactoring
2014-12-09 09:36:38 +01:00
Lukas Reschke 25a87d4058 Merge pull request #12577 from owncloud/public-mount-api
Add a public api for apps to add mounts
2014-12-08 22:57:33 +01:00
Morris Jobke 9a7362dd0d drop unused isDebugMode and setDebugMode of OC_Config 2014-12-08 22:42:44 +01:00
Morris Jobke 0d4f0ab871 reduce OC_Preferences, OC_Config and \OCP\Config usage
* files_encryption
* files_versions
* files_trashbin
* tests
* status.php
* core
* server container
2014-12-08 22:42:37 +01:00
Morris Jobke 2d5fc9c1a6 Workaround to fix the too early init dilemma
* this needs to be properly fixed by a proper organisation of the base.php
* introduced fixDIInit() in AllConfig that moves the injection
  of DatabaseConnection to a later point in time
* problems mostly because of the autoconfig setup
2014-12-08 22:33:36 +01:00
Morris Jobke af91ee97c9 introduce preCondition for setUserValue to provide atomic check-and-update 2014-12-08 22:33:36 +01:00
Morris Jobke f0b10324ca Refactoring of OC_Preferences to AllConfig
* keep old static methods - mapped to new ones and deprecated
* removed deleteApp, getUsers, getApps because they are unused
* make AllConfig unit tests more robust against not cleaned up environments
2014-12-08 22:33:29 +01:00
Morris Jobke a9e411e076 migrate \OC\AllConfig to \OCP\IConfig 2014-12-08 22:29:43 +01:00
Morris Jobke 719008836d introduce deleteAllUserValues 2014-12-08 22:29:42 +01:00
Morris Jobke 985b15f770 introduce proper interface for deleteAppValue 2014-12-08 22:29:42 +01:00
Morris Jobke b01c59b224 use old methods and redirect in deprecated methods 2014-12-08 22:29:42 +01:00
Morris Jobke 50c2a819a0 Extract interaction with config.php into SystemConfig
* introduce SystemConfig to avoid DI circle (used by database connection which is itself needed by AllConfig that itself contains the methods to access the config.php which then would need the database connection - did you get it? ;))
* use DI container and use that method in legacy code paths (for easier refactoring later)
* create and use getSystemConfig instead of query() in DI container
2014-12-08 22:29:42 +01:00
Vincent Petry cae600722e Add getTagsForObjects in ITags
Returns the list of tags that are set on the given object ids.
2014-12-08 22:02:00 +01:00
Lukas Reschke f219f5a7a6 Merge pull request #12618 from owncloud/initial-work-migrate-to-appframework
Add REST route for managing groups and users
2014-12-08 21:37:41 +01:00
Victor Dubiniuk 81d5712419 Fix tests. Add two more test cases 2014-12-08 22:16:47 +03:00
Jörn Friedrich Dreyer 85176ec072 return correct result 2014-12-08 15:25:21 +01:00
Morris Jobke 1362c0b67a Merge pull request #12452 from owncloud/server2server-ng-ocs
OCS API for server-to-server sharing
2014-12-08 14:12:03 +01:00
Lukas Reschke fe7d9a7ca0 Add REST route for user & group management
First step of a somewhat testable user management. - I know, the JSON returns are in an ugly format but the JS expects it that way. So let's keep it that way until we have time to fix the JS in the future.
2014-12-08 12:11:01 +01:00
Olivier Paroz 7917d3b068 Remove changes which were inadvertently pushed to master 2014-12-08 04:03:02 +01:00
Olivier Paroz d9c0be8785 Dump Arrays, Objects and Exceptions to the log
This is a first draft. It has only been tested with the ownlcloud logger.
Some internal fields are JSON encoded several times which makes it harder to read.

Most of the normalizer is borrowed from Monolog
https://github.com/Seldaek/monolog/blob/master/src/Monolog/Formatter/NormalizerFormatter.php
2014-12-08 03:53:07 +01:00
Victor Dubiniuk 303fce44f4 Use httphelper and cache response even when it empty 2014-12-06 20:17:47 +03:00
LEDfan b412e59c26 Fix permissions 2014-12-06 13:58:10 +01:00
Lukas Reschke ddcf2b84ec Remove checks for safe mode and magic quotes
Both are removed from 5.4.0

Safe Mode: http://php.net/manual/en/features.safe-mode.php
> This feature has been DEPRECATED as of PHP 5.3.0 and REMOVED as of PHP 5.4.0.

Magic Quotes: http://php.net/manual/en/security.magicquotes.php
> This feature has been DEPRECATED as of PHP 5.3.0 and REMOVED as of PHP 5.4.0.
2014-12-05 19:14:47 +01:00
Morris Jobke 5f66cb3250 Merge pull request #12561 from oparoz/vectoricon
Improve the bitmap and vector mime icons
2014-12-05 14:51:03 +01:00
Morris Jobke 4ec1da3014 Merge pull request #12583 from owncloud/trim-port
Trim port from domain
2014-12-05 11:27:20 +01:00
Robin Appelman f4701d7721 Add public api for mount configurations 2014-12-04 16:47:27 +01:00
Morris Jobke f3213571bb Merge pull request #12616 from owncloud/node-fileinfo
make \OC\Files\Node\Node implement the FileInfo interface
2014-12-04 16:34:30 +01:00
Clark Tomlinson b8a2fdaa21 Merge pull request #12607 from owncloud/this-is-an-awesome-day
PHP 5.4 is now required for master
2014-12-04 10:33:04 -05:00
Thomas Müller e9f0b30023 Merge pull request #12609 from owncloud/remove-53-fixme
Remove workaround for 5.3
2014-12-04 14:25:47 +01:00
Jörn Friedrich Dreyer 7ef6df04da remove triggerupdate, ref #11872 2014-12-04 13:44:30 +01:00
Robin Appelman 672495a1a3 make \OC\Files\Node\Node implement the FileInfo interface 2014-12-04 13:27:08 +01:00
Bjoern Schiessle 698ecbf308 OCS API for server-to-server sharing 2014-12-04 13:18:13 +01:00
Thomas Müller b55ac514ac no nested xml tags on dependencies 2014-12-04 11:40:33 +01:00
Thomas Müller eb81c52b95 fix an issue where the types tag holds an empty string 2014-12-04 11:40:33 +01:00
Thomas Müller b028a6afac adjust dependency analyzer to use attributes properly 2014-12-04 11:40:33 +01:00
Thomas Müller c80ec91f28 switch to different parsing implementation to get xml attributes properly handled 2014-12-04 11:40:33 +01:00
Thomas Müller ba52c996cf adding supported databases 2014-12-04 11:40:33 +01:00
Thomas Müller b469e9f6fb introduce dependency analyzer to take care of app dependencies
some more unit tests on xml info parser
2014-12-04 11:40:33 +01:00
Thomas Müller 40e03ba314 adding default key value pair for 'types' 2014-12-04 11:40:33 +01:00
Thomas Müller 1354cee18e translate labels properly 2014-12-04 11:40:33 +01:00
Lukas Reschke ee1f8b0242 Remove workaround for 5.3
Function is natively available with 5.4
2014-12-04 11:17:33 +01:00
Lukas Reschke 1b0bc2e099 PHP 5.4 is now required for master
🍻
2014-12-04 10:46:38 +01:00
Vincent Petry bc12d28f23 Log exceptions in DAV storage
In some cases a "NotFound" might be expected, so just return false as
before. But for other exceptions, the exception is now logged.
2014-12-03 22:20:00 +01:00
Lukas Reschke b3515a98e9 Add workaround for older instances
To be removed with oCAdd workaround for older instances

To be removed with oC99
2014-12-03 21:13:27 +01:00
Lukas Reschke 69f5f6649e Trim port from domain
Depending on the used environment the port might be appended to the host header resulting in an inaccessible instance when initially setting up on a system with a different HTTP or HTTPS port. (for example test:500)

To test this setup ownCloud under a different port with and without this patch. (heads-up: localhost is always white-listed, so use a different domain)
2014-12-03 19:59:50 +01:00
Joas Schilling 69a5a0c1a0 Stop flooding the log, when previews are disabled 2014-12-03 12:52:42 +01:00
Robin Appelman 2bbb11fb63 Merge pull request #10881 from owncloud/touch-statcache
Clear statcache before getting the mtime from local storage backends
2014-12-02 23:29:24 +01:00
Olivier Paroz 5990293331 Improve the bitmap and vector mime icons
* Vector files such as Illustrator files currently show the "image"
icon. I propose to add a new type to mimetypeIcon() called
"image/vector" and which would be used by SVG as well
* We can use the current image-svg+xml icon, but would simply rename it
to image-vector
* The black and white "image" icon looks too much like a settings icon.
A simple picture representation pasted over the file icon should work
2014-12-02 21:11:56 +01:00
Robin Appelman 1bbb18fe87 also clear statcache in mapped local 2014-12-02 16:39:03 +01:00
Morris Jobke a16d1a85ef Merge pull request #11975 from owncloud/Combustible-combustible_dev
Check imagecreate*() return before using and use logger in \OC_Image
2014-12-02 16:18:00 +01:00
Robin Appelman db3f7238dd Clear statcache before getting the mtime from local storage backends 2014-12-02 14:25:49 +01:00
Thomas Müller e9029f94cb Merge pull request #12310 from kampka/master
Implement a logger to log to error_log
2014-12-02 09:19:12 +01:00
Christian Kampka 553ce946d3 Implement a logger to log to error_log 2014-12-01 21:20:57 +01:00
Thomas Müller 0769556989 Merge pull request #12419 from owncloud/read-only-config
Allow read-only configuration
2014-12-01 16:37:29 +01:00
Thomas Müller b2175f0e25 Use \OCP\ILogger 2014-12-01 16:21:54 +01:00
Byron Marohn fa9b36b726 Added error check to lib/private/image.php
This checks that imagecreatetruecolor actually creates an image, rather than returning FALSE.
Without this check, subsequent loop might create billions of ERROR-level log messages.

Signed-off-by: Byron Marohn <combustible@live.com>
2014-12-01 16:20:17 +01:00
Vincent Petry 8db4dd7585 Merge pull request #12469 from owncloud/issue/12460-port-local-changes2mapped
Issue/12460 port local changes2mapped
2014-12-01 10:42:39 +01:00
Morris Jobke 6fa748621f Merge pull request #12398 from oparoz/patch-5
You can only change the oritentation of a JPEG
2014-11-30 10:32:51 +01:00
Lukas Reschke ebb243344a Merge pull request #12499 from owncloud/disableMSSQL
Disable MSSQL and OCI for new CE installations
2014-11-28 18:38:34 +01:00
Lukas Reschke f0e6876f2e Merge pull request #12488 from owncloud/activity_group_multiple_conditions
activitymanager: concatenate queries with 'or'
2014-11-28 17:35:05 +01:00
Lukas Reschke 9a8dc4a832 Disable OCI as it is unsupported by most CE apps 2014-11-28 16:23:03 +01:00
Lukas Reschke f3e75c085c Disable MSSQL for new CE installations
Since automatic schema migrations are not yet possible let's disable this for now.
2014-11-28 16:08:38 +01:00
Vincent Petry 219a129cd6 Close cursor after checking for existing config values 2014-11-28 15:33:21 +01:00
Bjoern Schiessle bf2c9be066 concatenate queries with 'or' 2014-11-28 14:46:27 +01:00
Lukas Reschke b3afc98f82 Merge pull request #12483 from owncloud/issue/6101-preview-providers
Issue/6101 Autoload preview providers
2014-11-28 13:43:41 +01:00
Morris Jobke b188710af3 Merge pull request #12472 from owncloud/modifyCookies
Add functions to modify cookies to response class
2014-11-28 10:16:22 +01:00
Morris Jobke 7a9af8c40c Merge pull request #12443 from owncloud/issue/6101-all-classes-autoloadable
Issue/6101 Make all interfaces/classes autoloadable
2014-11-28 09:40:27 +01:00
Vincent Petry 35ab770b11 Close cursor early in calculateFolderSize
This method triggers additional queries in $this->update() so to avoid
potential database locks or delays, we close the cursor as soon as it is not needed any more
2014-11-28 09:35:31 +01:00
Joas Schilling ec7b55f5be Split bitmap providers into one per file 2014-11-28 09:28:33 +01:00
Joas Schilling 3ec42ad598 Split office providers into one class per file 2014-11-28 09:28:30 +01:00
Joas Schilling 9cb54e3809 Fix intendation and doc blocks of preview providers 2014-11-28 09:28:28 +01:00
Richard Clarkson 0d98329cac Limit blacklist to php files
During performance optimization I have discovered that the installer scans all files for the blacklisted words. This greatly impacts speed on lower end devices such as the raspberry pie. This commit limits it to PHP files which seems to achieve the desired effect. 

I have used the --include option to achieve this, see http://stackoverflow.com/questions/1987926/how-do-i-grep-recursively

This contribution is MIT licensed
2014-11-27 20:26:45 +01:00
Joas Schilling fca9d32545 Move registration of core preview providers to preview
So the class files only have class code and don't execute code
2014-11-27 19:40:23 +01:00
Joas Schilling 7bbc27708a Move NaturalSort_DefaultCollator to its own file 2014-11-27 17:47:21 +01:00
Robin Appelman 05a069c101 Merge pull request #12426 from owncloud/jail-mask-wrappers
Add Jail and PermissionsMask storage wrappers
2014-11-27 16:00:14 +01:00
Robin Appelman 33b64868d7 Add storage and cache wrappers to apply a permissions mask to a storage 2014-11-27 15:25:57 +01:00
Robin Appelman abb6e89c5d Add storage and cache wrappers to jail a storage to a subfolder 2014-11-27 15:25:53 +01:00
Lukas Reschke af56429a9a Merge pull request #12470 from owncloud/jenkins-12447
Jenkins 12447
2014-11-27 15:16:14 +01:00
Joas Schilling 7761f0288e Also clearstatcache() in MappedLocal before using the stats
Local change 283c10f010
2014-11-27 14:59:10 +01:00
Joas Schilling 50f85bfd1f Check whether file exists before trying to touch() it
Local changes from d069ee8a8b
and 258ad38fd3
2014-11-27 14:59:09 +01:00
Joas Schilling c5427da76d Check return of disk_free_space before returning it
Local changes copied from ed83597371
and 25370fcb82
2014-11-27 14:59:08 +01:00
Joas Schilling 1062f4fe44 Check file existance in MappedLocal in hasUpdated()
Only fixed in Local by eeee9eacea
2014-11-27 14:59:07 +01:00
Joas Schilling b886d3d645 Make MappedLocal::isLocal() true like for Local
Missed in 788c8540aa
2014-11-27 14:59:07 +01:00
Vincent Petry e733d32eec Merge pull request #12462 from owncloud/issue/12460-localstorage-buildpath
Introduce buildPath() in Storage\Local to reduce the difference to MappedLocal
2014-11-27 14:57:08 +01:00
Lukas Reschke e35feadac2 Pass \OC::$WEBROOT to the ctr 2014-11-27 14:50:14 +01:00
Lukas Reschke fef32e63dd Remove redundant code 2014-11-27 14:38:38 +01:00
Lukas Reschke d197f43475 Use server container 2014-11-27 14:36:11 +01:00
Lukas Reschke 048139074d Add functions to modify cookies to response class
Currently there is no AppFramework way to modify cookies, which makes it unusable for quite some use-cases or results in untestable code.

This PR adds some basic functionalities to add and invalidate cookies.

Usage:
```php
$response = new TemplateResponse(...);
$response->addCookie('foo', 'bar');
$response->invalidateCookie('foo');
$response->addCookie('bar', 'foo', new \DateTime('2015-01-01 00:00'));
```

Existing cookies can be accessed with the AppFramework using `$this->request->getCookie($name)`.
2014-11-27 14:19:00 +01:00
Joas Schilling 0ed86c0993 Move OC_USER_BACKEND_* constants to OC_User_Backend class 2014-11-27 13:47:32 +01:00
Joas Schilling 24511c6f00 Move OC_GROUP_BACKEND_* constants to OC_Group_Backend class 2014-11-27 13:47:30 +01:00
Joas Schilling a2172786a8 Merge pull request #12449 from owncloud/issue/12444-namespace-exceptions
Issue/12444 namespace exceptions
2014-11-27 12:14:06 +01:00
Morris Jobke f52ba9c73c Merge pull request #12418 from owncloud/delete_previews
delete old previews
2014-11-27 12:09:39 +01:00
Joas Schilling 4f1bbc4fd5 Remove unused 2nd parameter of buildPath() and rename to getSourcePath() 2014-11-27 11:19:20 +01:00
Joas Schilling 20237fba47 Introduce getSourcePath() in Storage\Local to reduce the difference to MappedLocal 2014-11-27 11:19:18 +01:00
Vincent Petry a74822279c Merge pull request #12464 from owncloud/cache-available-languages
Cache results of available languages
2014-11-27 11:12:18 +01:00
Joas Schilling ea3780f911 Replace exception with standard exception 2014-11-27 11:10:05 +01:00
Joas Schilling e1f3abf7a5 Correctly namespace and autoload DatabaseException 2014-11-27 11:10:04 +01:00
Vincent Petry 51190f711d Merge pull request #12451 from owncloud/issue/6101-remove-gettype-class
Move constants from GET_TYPE to OC\Files so they can be autoloaded
2014-11-27 11:03:55 +01:00
Lukas Reschke b20d698ebd Cache results of available languages
This function is about 8 times calles for every single page call, when caching this variable I was able to gain a small performance improvement from 20,512 µs to 630 µs profiled with xhprof

Surely, this is no gigantic gain but if we would do that for every function out there...
2014-11-27 00:01:55 +01:00
Thomas Müller 5097d4dc05 remove deprecated \OC:$session 2014-11-26 15:32:47 +01:00
Joas Schilling 8e28bf012c Move constants from GET_TYPE to OC\Files so they can be autoloaded 2014-11-26 12:56:54 +01:00
Joas Schilling 3338eede3c Correctly namespace DatabaseSetupException 2014-11-26 12:30:07 +01:00
Lukas Reschke c749570a06 Merge pull request #12411 from owncloud/unknown-command-windows
Replace some more "command -v" calls with the Helper method
2014-11-26 10:29:41 +01:00
Morris Jobke 1da46b1a58 Merge pull request #12438 from owncloud/jenkins-no-new-session-ocs-api
because OC_User::login will create a new session we shall only try to lo...
2014-11-26 10:22:16 +01:00
Morris Jobke 60e4aa120f Merge pull request #12350 from mprokop/link_expiration
fix calculation of expiration date if there is a default expiration date...
2014-11-26 10:19:12 +01:00
Thomas Müller 320a3c3784 because OC_User::login will create a new session we shall only try to login if user and pass are set
ensure to never destroy an existing session
2014-11-26 09:19:10 +01:00
Morris Jobke c5fa8f1bdc Merge pull request #12421 from owncloud/issue/6101-remove-namespace-permission-constants
Issue/6101 remove namespace permission constants
2014-11-26 08:31:23 +01:00
Morris Jobke e9696a8c9a Merge pull request #12420 from owncloud/sqlite-wal-2
adding new config parameter for sqlite to specify the journal mode
2014-11-26 00:47:22 +01:00
Joas Schilling 0274dcba57 Replace some more "command -v" calls with the Helper method 2014-11-25 18:10:03 +01:00
Joas Schilling 2c39aec8cb Replace deprecated constant with new class constant 2014-11-25 16:30:21 +01:00
Thomas Müller a6c088a1ef adding new config parameter for sqlite to specify the journal mode 2014-11-25 16:29:06 +01:00
Lukas Reschke fc116f563f Allow read-only configuration
Workaround required for IIS setups running ownCloud to prevent dataloss.

Long-term solution would be to move some configuration settings to the database
2014-11-25 16:26:47 +01:00
Thomas Müller 0f18274ca5 Merge pull request #12416 from owncloud/app-info-xml-parser-2
App info xml parser 2
2014-11-25 15:56:52 +01:00
Georg Ehrke 1a1b459ae8 delete old previews 2014-11-25 15:42:02 +01:00
Thomas Müller 5ce34fbaf6 handle invalid xml file 2014-11-25 11:53:28 +01:00
Thomas Müller d4f107d4dd simplify xml parser code 2014-11-25 11:53:28 +01:00
Thomas Müller c503ecd544 Introduce app info xml parser including basic unit test - necessary for #10777 2014-11-25 11:53:28 +01:00
Olivier Paroz 93a6cc17a5 The class name is Movie NOT Movies 2014-11-25 11:35:38 +01:00
Morris Jobke 53b2d85709 Merge pull request #12402 from owncloud/fix-phpdoc
Fix PHPDoc and deprecated code
2014-11-25 09:20:36 +01:00
Lukas Reschke eb1dcb87c1 Merge pull request #12380 from owncloud/remove-oc-migrate
Remove OC_Migrate
2014-11-25 00:25:37 +01:00
Lukas Reschke b947b65e5b Fix PHPDoc and deprecated code
Some PHPDocs were incorrect, also used this opportunity to replace some deprecated functions.
2014-11-24 23:09:49 +01:00
Olivier Paroz e2a9bd7838 You can only change the oritentation of a JPEG
TIFFs also have EXIF headers, but they're not supported by the Image class

PHP doc
http://php.net/manual/en/function.exif-read-data.php
2014-11-24 17:32:53 +01:00
Thomas Müller ddacd7f900 Merge pull request #12294 from owncloud/route-postfix
Add route postfix to allow url versioning when only the http method changed
2014-11-24 16:32:54 +01:00
Morris Jobke 168fce0b18 Merge pull request #12303 from owncloud/windows-unknown-command-command
Deduplicate findBinaryPath() and do not try "command -v" on windows
2014-11-24 14:03:07 +01:00
Morris Jobke 1b17429c1d Merge pull request #12142 from owncloud/DeprecateOldIAPICalls
Deprecate older API wrappers and calls
2014-11-24 14:01:49 +01:00
Morris Jobke 8782b2237c Merge pull request #12084 from owncloud/sharing_fix_shared_with_info
sharing: make sure that we only find the shares from a given owner
2014-11-24 11:44:43 +01:00
Lukas Reschke 216d617938 Remove OC_Migrate
This is unused legacy code. Let it die with ~~~honor~~ fire.

Fixes https://github.com/owncloud/core/issues/12346
2014-11-24 10:53:45 +01:00
Georg Ehrke 45d985f2d8 remove ugly hack and don't use OC\Preview\Image for tiffs and svgs 2014-11-23 19:11:03 +01:00
Bjoern Schiessle a7ebfe87c9 also check for the correct owner if it was submitted 2014-11-21 16:17:37 +01:00
Miguel Prokop 397f14ed86 Consolidate if statement, and update unit test 2014-11-21 13:31:56 +01:00
Miguel Prokop 1d4d308a6c fix calculation of expiration date if there is a default expiration date set (but not forced) and the user does not want the link to expire. 2014-11-21 11:01:39 +01:00
Morris Jobke 593ef76e36 Revert "drop OC_Preferences::getUsers and getApps"
This reverts commit 09fd34eed9.
2014-11-20 22:02:26 +01:00
Morris Jobke 09fd34eed9 drop OC_Preferences::getUsers and getApps 2014-11-20 17:56:05 +01:00
Morris Jobke 985f8c3f69 Merge pull request #12330 from owncloud/jenkins-eat-that
drop dependency of some commands on old config object
2014-11-20 17:11:08 +01:00
Thomas Müller 7fa4c6d0bc Merge pull request #12321 from owncloud/checkForXMLWriter
Check for XMLWriter class
2014-11-20 17:04:27 +01:00
Morris Jobke 8ae8eb4734 drop dependency of some commands on old config object 2014-11-20 15:03:16 +01:00
Thomas Müller cbb9caf030 Merge pull request #12226 from owncloud/remove-phpass
Remove phpass and migrate to new Hasher interface
2014-11-20 14:59:59 +01:00
Morris Jobke 46e6104795 Merge pull request #12297 from owncloud/issue/10991-all-testcase
Issue/10991 all testcase
2014-11-20 14:53:18 +01:00
Lukas Reschke 9a1673c79d Check for XMLWriter class
This is not installed by default in all cases and will break the DAV features of ownCloud. Lot's of reports such as https://github.com/owncloud/ios-issues/issues/167#issuecomment-63798507
2014-11-20 13:13:14 +01:00
Vincent Petry 6a08fca363 Merge pull request #12253 from owncloud/port-12154
Port 12154
2014-11-20 12:47:27 +01:00
Joas Schilling d15f1882f9 Simplify the binary finding code in the movie preview class 2014-11-20 12:41:55 +01:00
Joas Schilling 64421d76fd Deduplicate function by moving it to the OC_Helper 2014-11-20 12:37:59 +01:00
Joas Schilling bb540722cd Use base class to reset the file mapper 2014-11-19 14:52:07 +01:00
Bernhard Posselt 4e90c44301 add postfix
add postfix
2014-11-19 12:01:42 +01:00
Morris Jobke d40bdfb35e drop unneeded var_dump - fixes #9997 2014-11-18 22:36:42 +01:00
Morris Jobke 81d112fb42 Merge pull request #12261 from oparoz/patch-1
Replace deprecated switches
2014-11-18 18:59:34 +01:00
Björn Schießle 106d0f9c75 Merge pull request #12224 from owncloud/fix_12211
make sure that we don't find the wrong shares if a user and a group have the same ID
2014-11-18 17:26:02 +01:00
Olivier Paroz cb118ce371 Replace deprecated switches
Warning: -convert-to is deprecated.  Use --convert-to instead.
Warning: -outdir is deprecated.  Use --outdir instead.
2014-11-18 15:04:01 +01:00
Lukas Reschke 309788003d Merge pull request #12259 from owncloud/app-enabled-plugin-appmanager
Fix type hinting for app manager
2014-11-18 13:56:40 +01:00
Lukas Reschke 8d4e63dd7c Merge pull request #12242 from owncloud/fix-undefined-size
Check if the size field is available
2014-11-18 12:37:16 +01:00
Lukas Reschke 260a084d27 Add repair steps for legacy config files
Remove all ports from the trusted domains

Conflicts:
	lib/private/repair.php
	lib/repair/repairconfig.php
2014-11-18 12:36:03 +01:00
Lukas Reschke d0a30b0e55 Ignore port for trusted domains
This lead to a lot of confusion in the past and did not really offer any value. Let's remove the port check therefore. (it's anyways not really a part of the domain)

Fixes https://github.com/owncloud/core/issues/12150 and https://github.com/owncloud/core/issues/12123 and also a problem reported by @DeepDiver1975.

Conflicts:
	lib/private/request.php
2014-11-18 12:36:03 +01:00
Robin Appelman 0b630a37ab Fix type hinting for app manager 2014-11-18 12:22:13 +01:00
Bjoern Schiessle ea4eedd35a only users can have a display name different from the id 2014-11-18 11:46:28 +01:00
Bjoern Schiessle 367468ff1f make sure that we only find the shares from the correct share type if users and groups with the same ID exists 2014-11-18 11:11:49 +01:00
Bjoern Schiessle 5192641447 make sure that we don't find the wrong shares if a user and a group have the same ID 2014-11-18 11:03:08 +01:00
Morris Jobke 36ba935381 Merge pull request #12237 from owncloud/fix-12236
Make declaration compatible
2014-11-18 10:30:17 +01:00
Lukas Reschke 944cd327b1 Merge pull request #9962 from owncloud/app-group-enable-remote
Fix remote.php routes for apps that are enabled for specific groups
2014-11-18 10:08:20 +01:00
Lukas Reschke 6535540dcd Check if the size field is available
In some cases the 'size' field is not available resulting in some PHP errors such as:

```json
{"reqId":"03548fd9e3d3aca15a5796b3b35d7b9d","remoteAddr":"::1","app":"PHP","message":"Undefined index: size at \/Users\/lreschke\/Programming\/core\/lib\/private\/files\/fileinfo.php#125","level":3,"time":"2014-11-17T21:38:57+00:00"}
```

This can be experienced when creating a new empty file and deleting it right away, then when going to the trash bin this error is thrown.
2014-11-17 22:39:40 +01:00
Lukas Reschke e8f90133e0 Merge pull request #11727 from owncloud/moveCallCheckRegisterToSomeWhereElse
Move CSRF check
2014-11-17 18:34:55 +01:00
Lukas Reschke 0b9dffa828 Make declaration compatible
Fixes #12236
2014-11-17 18:30:17 +01:00
Vincent Petry af7688ec17 Merge pull request #11741 from owncloud/delete_all_children_preview_2
delete all children's previews when deleting a folder
2014-11-17 16:45:54 +01:00
Morris Jobke 146cb920c9 Merge pull request #12218 from owncloud/issue/10991-fixes
Issue/10991 Make unit tests pass on windows
2014-11-17 16:44:45 +01:00
Robin Appelman 7cb12d4bff Add sabredav plugin to check if a user has access to an app 2014-11-17 15:50:24 +01:00
Robin Appelman 36528c6ef6 Merge pull request #12031 from owncloud/app-manager
Add \OC\App\Manager to handle enabling/disabling apps
2014-11-17 15:49:15 +01:00
Lukas Reschke 07f0d76fc6 Move CSRF check
Because we're closing the session now before controllers are executed there are cases where we cannot write the session.
2014-11-17 15:10:53 +01:00
Lukas Reschke 8595b76df2 Remove phpass and migrate to new Hasher interface
This PR removes phpass and migrates to the new Hasher interface.

Please notice that due to https://github.com/owncloud/core/issues/10671 old hashes are not updated but the hashes are backwards compatible so this shouldn't hurt.
Once the sharing classes have a possibility to update the passwords of single shares those methods should be used within the newHash if block.
2014-11-17 13:39:13 +01:00
Joas Schilling 0ab973a3a6 Make it possible to cleanPath() absolute Windows paths 2014-11-17 10:48:15 +01:00
Joas Schilling 39ae569c5c Correctly close handle of directory when listing certificates 2014-11-17 10:48:14 +01:00
Morris Jobke b9e86b0951 Merge pull request #12186 from owncloud/fix-12182
eliminate OC_Template::printErrorPage in database classes, fixes #12182
2014-11-15 16:50:15 +01:00
Lukas Reschke cd5925036a Check if app is enabled for user
Fixes https://github.com/owncloud/core/issues/12188 for AppFramework apps
2014-11-15 11:13:55 +01:00
Arthur Schiwon 74ffda8261 do not output DB information, and do not set header 2014-11-14 17:43:22 +01:00
Arthur Schiwon 08205c63f9 errors are already logged 2014-11-14 16:59:54 +01:00
Arthur Schiwon 7ed678b04d eliminate OC_Template::printErrorPage in database classes, fixes #12182 2014-11-14 15:48:55 +01:00
Morris Jobke c0d63680ed Merge pull request #11479 from owncloud/cleanup-group-admin-on-deleteGroup
cleanup group admin(s) on deleteGroup
2014-11-13 22:39:40 +01:00
Morris Jobke e5d46d0d94 Merge pull request #11956 from owncloud/remove-check-for-allow_user_to_change_display_name
removal of wrong/double implemented check
2014-11-13 15:39:07 +01:00
michag86 7e70c4ee95 removal of wrong/double implemented check
Check already implemented in core/settings/ajax/changedisplayname.php
2014-11-13 13:02:02 +01:00
Lukas Reschke 5f8fb8d1ee Run preupdate before an update
The update routine tries to test the database migration before actually performing the update.

However, this will fail hard if the schema has changed (for example an unique key has been added). App developers can convert the DB in preupdate.php, however it is not called before and therefore the update fails.

This actually breaks ownCloud updates from ownCloud 6 to ownCloud 7 when the files_antivirus app is enabled.
2014-11-13 12:07:49 +01:00
Morris Jobke 97a8fa418d Merge pull request #12141 from owncloud/kill-dav-client
OC_DAVClient is not longer used - no need to carry it around anymore
2014-11-12 21:20:52 +01:00
Lukas Reschke 4302a78b27 Deprecate older API wrappers and calls
Those old classes have now non-static pendants and can be deprecated IMHO.
2014-11-12 17:39:25 +01:00
Thomas Müller 6e3a841652 Merge pull request #12139 from owncloud/DoNotTouchMe
Try to read the file only instead of trying to touch
2014-11-12 17:29:56 +01:00
Thomas Müller fede6b93e5 OC_DAVClient is not longer used - no need to carry it around anymore 2014-11-12 17:07:34 +01:00
Jan-Christoph Borchardt d5796bbaf9 Merge pull request #12128 from owncloud/drop-formfactor
Drop form_factor that is appended to JS, CSS and template filenames
2014-11-12 16:23:19 +01:00
Lukas Reschke 49ddaf9489 Try to read the file only instead of trying to touch
The permissions are already catched properly on the installation so we just have to check whether the file is readable to prevent fatal errors from happening.

Fixes https://github.com/owncloud/core/issues/12135
2014-11-12 15:57:19 +01:00
Morris Jobke 952abdc51a Drop form_factor that is appended to JS, CSS and template filenames 2014-11-12 13:07:23 +01:00
Lukas Reschke da31177a8f Remove debug statement
Either we throw an exception or we ignore it. But we should certainly not print this to the end-user...
2014-11-12 11:32:48 +01:00
Thomas Müller c998f620d0 Merge pull request #12105 from owncloud/dav-fixcleanpath
Fix root path handling for WebDAV ext storage
2014-11-12 09:16:55 +01:00
Thomas Müller 9aef0421cf Merge pull request #12107 from owncloud/dav-propfindmimetype
Return real mime type on PROPFIND
2014-11-12 09:16:26 +01:00
Bernhard Posselt 6d5a239abf Fix Pimple unset 2014-11-11 22:04:46 +01:00
Vincent Petry 0b2c24081f Return real mime type on PROPFIND
Return the real (insecure) mime type on PROPFIND
2014-11-11 15:42:50 +01:00
Vincent Petry 4b943a4810 Fix root path handling for WebDAV ext storage
Added missing cleanPath() call that converts "/" to "" when calling
SabreDAV. This is needed because SabreDAV will discard its base URL when
passing "/".
2014-11-11 15:20:36 +01:00
Robin Appelman 43eb375ace Add \OC\App\Manager to handle enabling/disabling apps 2014-11-10 13:52:52 +01:00
Vincent Petry 9b99c1d6f0 Merge pull request #12072 from owncloud/sabre-convertstoragenotavailableexception-secondtry
Convert StorageNotAvailableException to SabreDAV exception
2014-11-10 12:52:52 +01:00
Vincent Petry 676b911b22 Merge pull request #12027 from owncloud/cleanup_exceptions
[encryption] clean up encryption exceptions
2014-11-10 12:46:53 +01:00
Vincent Petry cccedf6f30 Convert StorageNotAvailableException to SabreDAV exception
Convert \OCP\Files\StorageNotAvailableException to
\Sabre\DAV\Exception\ServiceUnavailable for every file/directory
operation happening inside of SabreDAV.

This is necessary to avoid having the exception bubble up to remote.php
which would return an exception page instead of an appropriate response.
2014-11-10 12:01:24 +01:00
Craig Morrissey 541344d880 logging changes 2014-11-07 12:45:42 -05:00
Bjoern Schiessle f27b6b0ab8 don't scan part files 2014-11-07 15:20:51 +01:00
Bjoern Schiessle a10ae2816e clean up encryption exceptions 2014-11-07 13:48:31 +01:00
Robin Appelman d26a427f92 Also propagate etag changes when the watcher finds a changed file 2014-11-07 12:56:09 +01:00
Lukas Reschke e345697cab Merge pull request #11954 from owncloud/enc_stop_uploading_if_private_key_is_missing
Enc stop uploading if private key is missing
2014-11-07 11:19:04 +01:00
Thomas Müller 88c329b394 Merge pull request #12019 from owncloud/fix-template-shortcuts
second parameter in template shortcuts script() and style() is optional
2014-11-07 11:01:10 +01:00
Adam Williamson 013feb8da0 writeData(): correct variable name for config file path
It changed since we wrote this patch.
2014-11-06 18:10:43 -08:00
Adam Williamson 8b2b0aae31 deleteFromOpcodeCache: make parameter mandatory, document parameter
Both pointed out in submission review by @bantu, thanks.
2014-11-06 18:05:20 -08:00
Adam Williamson 3b4823d89c add function to invalidate one opcache file, use it if possible #9885
Issue #9885 appears to be triggered by ownCloud invalidating the entire
PHP opcache. Testing indicates it can be avoided by only invalidating the
single file that was written from the opcache, instead of clearing the
whole thing. In general it is more efficient to invalidate only the single
file that was changed, rather than the whole cache.

This adds a deleteFromOpcodeCache() function which invalidates a single
file from the opcache if possible, returning true if the underlying
function returns true (which may mean 'success', or 'file does not exist',
or 'file exists but is not in opcache', all of which are OK to treat as
good for our purposes). It also changes writeData() in config.php to try
using deleteFromOpcodeCache() and only fall back on clearOpcodeCache() if
that fails.
2014-11-06 17:58:58 -08:00
Lukas Reschke d383c45c13 Merge pull request #12003 from owncloud/password-migration
Use new hashing API for OC_User_Database
2014-11-06 22:43:57 +01:00
Morris Jobke 81e6329c04 second parameter in template shortcuts script() and style() is optional 2014-11-06 21:26:50 +01:00
Morris Jobke e53354bfd7 Merge pull request #12009 from owncloud/make-optional
Make second argument optional
2014-11-06 19:43:11 +01:00
Robin Appelman 0c230fb57e Merge pull request #11945 from owncloud/share-setup-other-user
Setup shared mounts for the correct user when setting up the filesystem
2014-11-06 19:24:24 +01:00
Robin Appelman 16b0d52031 Default to reusing etags in the scanner 2014-11-06 18:34:10 +01:00
Robin Appelman c21d1da01a Support displaynames for dummy user backend 2014-11-06 18:31:40 +01:00
Lukas Reschke 20cd9a134f Make second argument optional
Equivalent to addVendorScript und addScript from OC_Util
2014-11-06 18:17:21 +01:00
Lukas Reschke c4d7483a0a Use new hashing API for OC_User_Database
This will use the new Hashing API for OC_User_Database and migrate old passwords upon initial login of the user.
2014-11-06 15:42:06 +01:00
Lukas Reschke 24ca2d858f Add OCP\Security\IHasher
Public interface for hashing which also works with legacy ownCloud hashes and supports updating the legacy hash via a passed reference.

Follow-up of https://github.com/owncloud/core/pull/10219#issuecomment-61624662
Requires https://github.com/owncloud/3rdparty/pull/136
2014-11-06 15:16:14 +01:00
Lukas Reschke f73d653036 Merge pull request #11972 from owncloud/usermanager-remove-delete
Remove confusingly names \OC\User\Manager::delete and fix the automatic ...
2014-11-06 13:52:25 +01:00
Robin Appelman 1eefc21329 Remove confusingly names \OC\User\Manager::delete and fix the automatic cache cleanup instead 2014-11-05 15:45:58 +01:00
Thomas Müller 06267fec8f Merge pull request #11928 from owncloud/support-HTML-in-logo
Support HTML in logo
2014-11-05 13:54:29 +01:00
Bjoern Schiessle c2a45c1238 throw exception if private key is missing 2014-11-05 13:05:46 +01:00
Morris Jobke 7f4e447a5f fix shortcuts - underline instead of camelCase 2014-11-04 13:57:38 +01:00
Morris Jobke fde8ef0655 Merge pull request #11916 from owncloud/introduce-bower
Introduce bower dependency managment for frontend libraries
2014-11-04 11:59:33 +01:00
Morris Jobke 7f1d974796 Merge pull request #11924 from owncloud/firstCheckIfItIsDefaultConfig
First check whether it is the default config before touching
2014-11-03 21:20:42 +01:00
Lukas Reschke be5ae6c44f Support HTML in logo claim 2014-11-03 21:14:27 +01:00
Morris Jobke d763b32048 ability to add bower resources
* add addVendorScript & addVendorStyle
* refactoring of addScript and addStyle
* add shortcuts vendorScript and vendorStyle
2014-11-03 20:54:40 +01:00
Thomas Müller 994768d99f Update Pimple to V3.0 2014-11-03 16:57:16 +01:00
Lukas Reschke 9790801268 First check whether it is the default config before touchign
Potentially fixes https://github.com/owncloud/core/issues/11678
2014-11-03 16:37:04 +01:00
Morris Jobke 56cf1d9d27 fix odd behaviour 2014-10-31 18:46:47 +01:00
Vincent Petry fd4b97d758 Merge pull request #9044 from owncloud/add-missing-email-principal
adding missing email address for principal
2014-10-31 13:24:42 +01:00
Vincent Petry 55658e7bb2 Merge pull request #11539 from owncloud/mount-setup-once
Only mount the storages for the user once
2014-10-31 10:42:29 +01:00
Morris Jobke 1c7f1a8787 Merge pull request #11877 from owncloud/fix-11875-master
prevent PHP notice
2014-10-30 21:43:38 +01:00
Vincent Petry bed81ea854 Merge pull request #11080 from owncloud/addheader-text-2
Fix the addHeader tag attributes text methods to not ignore the text parameter
2014-10-30 18:13:46 +01:00
Thomas Müller 99921489cf prevent PHP notice 2014-10-30 17:24:25 +01:00
Georg Ehrke 33186957c8 delete all children's previews when deleting a folder
add phpdoc
2014-10-30 17:15:42 +01:00
Thomas Müller 9b293537a6 Merge pull request #11740 from owncloud/update-archive-tar
Update pear/archive_tar to 1.3.13
2014-10-30 17:14:07 +01:00
Lukas Reschke 6db69c5d05 Merge pull request #11864 from owncloud/clear-session-after-logout
Clear session after logout
2014-10-30 16:47:46 +01:00
Morris Jobke 90e523ead0 Merge pull request #11858 from owncloud/fix-11064
Allow any outgoing XHR connections
2014-10-30 16:19:39 +01:00
Thomas Müller 08b46ccc17 Update pear/archive_tar to 1.3.13 2014-10-30 16:10:00 +01:00
Thomas Müller 18f7f582ac Merge pull request #11860 from owncloud/fix-stupid-error-because-im-a-moro
Fix stupid copy paste fail
2014-10-30 14:45:58 +01:00
Morris Jobke e2001c6d31 Merge pull request #11821 from owncloud/generic-response
Add a generic data response
2014-10-30 14:05:25 +01:00
Lukas Reschke 770c62c5d8 Clear session after logout
Fixes https://github.com/owncloud/core/issues/8420
2014-10-30 12:10:39 +01:00
Lukas Reschke e219d72619 Fix stupid copy paste fail
...
2014-10-30 10:37:59 +01:00
Lukas Reschke b3f881748d Allow any outgoing XHR connections
Quickfix for https://github.com/owncloud/core/issues/11064
2014-10-30 00:00:40 +01:00
Vincent Petry 106b9eb55c Merge pull request #11409 from owncloud/watcher-reuse
Pass the cached data to the filesystem watcher
2014-10-29 16:38:16 +01:00
Thomas Müller fb4f993336 Fix implementation of translation short cut 2014-10-29 10:58:10 +01:00
Vincent Petry c682b1f0c1 Fix language file detection 2014-10-29 10:13:51 +01:00
Thomas Müller 2f19de11e4 adding console command to generate javascript translation files based on existing php translation files
read server side translations from json files
2014-10-29 10:09:12 +01:00
Thomas Müller a589d61b78 in case a translation javascript is not found we no longer bail out
remove translation.php
2014-10-29 10:09:12 +01:00
Vincent Petry ec1a73fab9 Added OC.L10N namespace with translation functions
Added addTranslations and fixed de.js file

Fixed de.js to use OC.L10N.register() and use to correct expected
format.

Added JS unit tests for OC.L10N class

Include translations JS script for all apps
2014-10-29 10:09:12 +01:00
Bernhard Posselt 0696099bad add dataresponse
fix docstrings

adjust copyright date

another copyright date update

another header update

implement third headers argument, fix indention, fix docstrings

fix docstrings
2014-10-29 09:43:47 +01:00
Robin Appelman 2974d4d380 Reset the users setup after clearing mounts 2014-10-28 15:13:29 +01:00
Lukas Reschke 510d0b2cf3 Fix the "addHeader($tag, $attributes, $text)" methods to not ignore the $text parameter
Also support closing tags with no text content given

Conflicts:
	lib/private/template.php
2014-10-28 11:15:58 +01:00
Morris Jobke 4461e69873 Merge pull request #11791 from owncloud/webdav-getquotainfo-503-handling
Properly catch 503 storage not available in getQuotaInfo
2014-10-28 09:33:54 +01:00
Lukas Reschke d6380a5395 Merge pull request #11786 from owncloud/MakeSupportedDBsConfigurable
Make supported DBs configurable within config.php
2014-10-27 22:24:16 +01:00
Thomas Müller 79778d6a51 code cleanup during review 👍 2014-10-27 21:39:35 +01:00
Lukas Reschke 233c49f4b9 Make supported DBs configurable within config.php
This commit will make the supported DBs for installation configurable within config.php. By default the following databases are tested: "sqlite", "mysql", "pgsql". The reason behind this is that there might be instances where we want to prevent SQLite to be used by mistake.

To test this play around with the new configuration parameter "supportedDatabases".
2014-10-27 21:39:34 +01:00
Robin Appelman 3f63f4b6b1 Only mount the storages for the user once 2014-10-27 18:50:28 +01:00
Vincent Petry 21d825ed6c Properly catch 503 storage not available in getQuotaInfo
When doing a PROPFIND on the root and one of the mount points is not
available, the returned quota attributes will now be zero.

This fix prevents the expected exception to make the whole call fail.
2014-10-27 16:27:12 +01:00
Morris Jobke a00712aa65 Merge pull request #11783 from owncloud/allow_passing_driver_options
allow passing db driver options
2014-10-27 16:00:13 +01:00
Robin Appelman 8de287f2ef Merge pull request #11763 from owncloud/stable-etags
Generate stable etags for local files
2014-10-27 15:30:30 +01:00
Jörn Friedrich Dreyer e16a58220d allow passing driver options, fixes #11718 2014-10-27 12:30:29 +01:00
Vincent Petry aee1edf6b5 Merge pull request #11708 from owncloud/fix-momentjs
Setting moment locale based on user selection
2014-10-27 10:30:47 +01:00
Lukas Reschke acec1afe17 Merge pull request #11760 from owncloud/add-type-hints-where-sensible
Add type hinting to functions
2014-10-25 14:09:48 +02:00
Morris Jobke be32e562e3 drop unneeded hint 2014-10-25 12:00:56 +02:00
Morris Jobke 63f2b1f460 Merge pull request #11767 from danbartram/add_db_rollback
Add missing DB rollback functionality
2014-10-24 19:52:56 +02:00
Thomas Müller 9fa5483111 Merge pull request #11709 from owncloud/temp-handling
Cleanup handling of temporary files
2014-10-24 19:29:05 +02:00
Dan Bartram 9c1015b790 Add missing DB rollback functionality 2014-10-24 17:44:06 +01:00
Robin Appelman 283c10f010 Generate stable etags for local files 2014-10-24 16:47:58 +02:00
Lukas Reschke f901c5ff08 Fix PHPDoc and remove explicit type hint 2014-10-24 15:49:55 +02:00
Lukas Reschke b3a04840b5 Add type hinting to functions
It's only reasonable to have proper type hinting here which might even help us to catch bugs.
2014-10-24 14:13:40 +02:00
Robin Appelman 16cfca6a5f Better reuse of cache data for getFolderContents 2014-10-24 12:33:54 +02:00
Robin Appelman 0a3f57f832 Pass the cached data to the filesystem watcher 2014-10-24 12:32:55 +02:00
Lukas Reschke d060180140 Use function outside of loop
Otherwise the function is executed n times which is a lot of overhead
2014-10-24 12:27:53 +02:00
Robin Appelman 0b96297783 Use the TempManager to handle temporary files 2014-10-24 12:18:49 +02:00
Robin Appelman 83c74b80ad Add \OC\TempManager to handle creating and cleaning temporary files 2014-10-24 12:18:46 +02:00
Lukas Reschke 2d2a4741ce Make files non executable
There is not much sense in having these files marked executable, we should avoid that.
2014-10-24 11:14:51 +02:00
libasys cbd130bed0 adding missing email address for principal
* fix #8515
* add mail only if it exists
2014-10-24 11:12:23 +02:00
Morris Jobke 4b5a3876ac Merge pull request #7749 from owncloud/load_avatar_header_via_php
Load avatar in header via PHP
2014-10-24 01:27:25 +02:00
kondou 729dffed5e Load avatar in header via PHP
* fix #7484
* use UID, css, and div instead of span
2014-10-23 23:17:18 +02:00
Lukas Reschke c30b7f8197 Remove unreachable statement 2014-10-23 23:03:14 +02:00
Clark Tomlinson ca5abe5744 Setting moment locale based on user selection 2014-10-23 10:32:47 -04:00
Thomas Müller e26a16afea Merge pull request #11549 from owncloud/add-more-localizations-master
implement localizations based on punic
2014-10-23 16:09:47 +02:00
Thomas Müller 6c1871da06 Merge pull request #10985 from owncloud/db-cleanup
Cleanup database handling
2014-10-23 13:48:33 +02:00
Morris Jobke b82e44b448 Merge pull request #10689 from owncloud/load_classfile_once
make sure class file is loaded once
2014-10-23 11:41:00 +02:00
Lukas Reschke e9ec45ddd1 Merge pull request #11704 from owncloud/fix-type-for-query
Use mixed as type
2014-10-22 18:13:31 +02:00
blizzz 44a7a3690a Merge pull request #11702 from owncloud/fix-11637
setup filesystem by username, not login name, fixes #11637
2014-10-22 17:56:30 +02:00
Lukas Reschke be06937e65 Use mixed as type
Actually query() returns value of the type "mixed" (as is also stated in the interface) - this is purely there to make our IDEs and Scrutinizer happier.
2014-10-22 15:09:33 +02:00
Jörn Friedrich Dreyer b7fa644a54 Merge pull request #9586 from owncloud/enhanced-sql-script-generation-oracle-master
Special treatment for Oracle
2014-10-22 14:54:42 +02:00
Lukas Reschke 31e489b44d Merge pull request #11687 from owncloud/appframework-session-annotation
introduce SessionMiddleWare to control session handling via an annotatio...
2014-10-22 14:45:28 +02:00
Arthur Schiwon 993376fb6f better variable name 2014-10-22 13:36:57 +02:00
Arthur Schiwon e0342db47c set up FS by username, not login name\! 2014-10-22 13:28:08 +02:00
Thomas Müller 02c5933af8 introduce SessionMiddleWare to control session handling via an annotation 2014-10-22 12:44:19 +02:00
Robin Appelman d83b11d34a Use statements wrapper in \OCP\IDB 2014-10-22 12:29:53 +02:00
Robin Appelman e6f6cdd19f Bit more cleanup 2014-10-22 12:29:53 +02:00
Robin Appelman 2ae6a0d96d Move creating the database connection to the server container 2014-10-22 12:29:53 +02:00
Robin Appelman d4e929c37a Remove implicit prepared statement cache and get the connection from the server container in \OC_DB 2014-10-22 12:26:43 +02:00
Robin Appelman 72f99f5041 Remove \OC\DB\ConnectionWrapper, have \OC\DB\Connection implement \OCP\IDBConnection directly instead 2014-10-22 12:26:43 +02:00
Bjoern Schiessle b7718bc212 always use the correct share type 2014-10-22 11:48:29 +02:00
Morris Jobke e2ff180521 Merge pull request #11416 from owncloud/eventlogger
Allow apps to gather performance diagnistics
2014-10-22 11:18:26 +02:00
Lukas Reschke cb36666600 Merge pull request #11630 from owncloud/kill-some-legacy
remove legacy class OC_Updater
2014-10-21 14:01:49 +02:00
Lukas Reschke 8f8abdbaee Add unit tests for convertToRelativePath 2014-10-20 15:09:43 +02:00
Lukas Reschke 7b94c7f9c1 Refer to relative path instead of absolute path
There is no need to refer to the absolute path here if we can use the relative one.

Conflicts:
	lib/private/templatelayout.php
2014-10-20 15:09:43 +02:00
Thomas Müller c8e8945efb implement localizations based on punic 2014-10-20 15:04:42 +02:00
Thomas Müller 6af0e76a03 remove legacy class OC_Updater 2014-10-20 14:44:42 +02:00
Robin Appelman 9fd234f63f Log some additional events 2014-10-20 13:38:38 +02:00
Robin Appelman beb1c6ad74 Allow adding events that hapend before the event logger was loaded 2014-10-20 13:38:38 +02:00
Robin Appelman 4a8358bc50 Rename to NullQueryLogger 2014-10-20 13:38:38 +02:00
Robin Appelman 1e69f5e7ac Log some basic events 2014-10-20 13:38:38 +02:00
Robin Appelman 6e08014781 Rename namespace to Diagnostics 2014-10-20 13:38:38 +02:00
Robin Appelman 2790bda4f8 Activate the query logger on connect 2014-10-20 13:38:37 +02:00
Robin Appelman b71d1d3616 Add QueryLogger interface to allow apps to get a list of used queries 2014-10-20 13:38:37 +02:00
Robin Appelman d38050cf52 Add an EventLogger interface to allow apps to get a log of the request timeline 2014-10-20 13:38:37 +02:00
Jörn Friedrich Dreyer ca0e3fdfea throw exception in writeBack, the returned boolean is checked nowhere 2014-10-20 11:29:05 +02:00
Jörn Friedrich Dreyer 9b0f0df7f5 make skeleton compatible with objectstore
suspend encryption proxy when copying skeleton
2014-10-20 11:28:36 +02:00
Arthur Schiwon 4e8c7570d4 make performance less bad. Still far from good, but at least it works 2014-10-17 20:16:04 +02:00
Arthur Schiwon a7a532f58a with several backends, more than limit can be returned 2014-10-17 20:16:04 +02:00
Morris Jobke 7bf401e48a Merge pull request #11430 from owncloud/minify-js-css-master
adding cssmin and jssmin(minify)
2014-10-17 15:05:59 +02:00
Lukas Reschke 439b33ec38 Merge pull request #11634 from owncloud/loadapps-encapsulaterequire
Encapsulate require_once to avoid name space bleedind
2014-10-17 14:32:10 +02:00
Vincent Petry 27c22f071d Encapsulate require_once to avoid name space bleedind
The script required by require_once might use variable names like $app
which will conflict with the code that follows.

This fix encapsulates require_once into its own function to avoid such
issues.
2014-10-17 12:45:45 +02:00
Thomas Müller 93b0f1a3bf adding cssmin and jssmin(minify)
adding argument deleteSelf to rmdirr() - if false the directory itself will not be deleted only it's content

adding repair step to clean the asset cache after upgrade + coding style adjustments
2014-10-17 12:22:26 +02:00
blizzz 688a141586 Merge pull request #9104 from macjohnny/macjohnny-drastic-ldap-speedup
drastic ldap speedup (update)
2014-10-17 12:07:27 +02:00
Morris Jobke f1a5ebd59d Merge pull request #11611 from owncloud/fix-svg-master
Fix SVG icons
2014-10-17 12:01:27 +02:00
Lukas Reschke af335a39f1 Add PHPDoc about sanitization of "insertIfNotExist"
Let's document this potential pitfall properly.
2014-10-17 11:06:49 +02:00
Lukas Reschke 53e0cf2f74 Add a try catch block
This function might also be called before ownCloud is setup which results in a PHP fatal error. We therefore should gracefully catch errors in there.
2014-10-16 21:45:09 +02:00
Thomas Müller f7097faf82 Special treatment for Oracle 2014-10-16 17:02:15 +02:00
Lukas Reschke a37dcf94fd Merge pull request #11591 from owncloud/addAppVersionToCSSandJS
Add app version to JS and CSS
2014-10-16 15:54:57 +02:00
Lukas Reschke 5f3ddf5c80 Merge pull request #11383 from ockham/share-tags2
Share tags
2014-10-16 15:36:04 +02:00
Thomas Müller a04159090f include the apps' versions hash to invalidate the cached assets 2014-10-16 13:29:51 +02:00
Lukas Reschke 4deb57bfae Remove insane comment 2014-10-16 12:42:00 +02:00
Lukas Reschke 9cfbf7ed1c Fix SVG icons
FIXME: Ugly hack to prevent SVG of being returned if the SVG
provider is not enabled.
This is required because the preview system is designed in a
bad way and relies on opt-in with asterisks (i.e. image/*)
which will lead to the fact that a SVG will also match the image
provider.

Conflicts:
	lib/private/preview.php
2014-10-16 12:35:51 +02:00
blizzz 756f64d728 Merge pull request #11595 from owncloud/make_get_display_name_more_robust
strip whitespace from the beginning and end of the display name
2014-10-16 11:33:12 +02:00
Jörn Friedrich Dreyer 0254a3c406 make trashbin compatible with objectstore, replace glob with search in cache, make unknown free space work like unlimited free space 2014-10-16 10:15:43 +02:00
Lukas Reschke 63e0599218 Merge pull request #11565 from owncloud/fix-behaviourOnOSX
Add darwin to if block
2014-10-15 21:12:50 +02:00
Lukas Reschke f82b996f57 Merge pull request #11528 from owncloud/use-raw-url
Use `rawurlencode` since this seems to be expected by cURL
2014-10-15 19:58:27 +02:00
Jörn Friedrich Dreyer c27fd94ec8 in cli mode return true for isHtaccessWorking 2014-10-15 16:59:28 +02:00
Thomas Müller b091394a90 introduce new app page layout
filter installed and not-installed apps properly

kill unneeded file

load category 'Installed' on page load

adding documentation links

new apps mgmt: first style adjustment

apps mgmt: only show license and preview if they exist

adding buttons

new apps mgmt: fix for mobile

use app icon if available

new apps mgmt: position enable/disable toggle to the right

new apps mgmt: proper display of icons or previews

new apps mgmt: fix loading spinner

reenable group selection for apps

new apps mgmt: position enable button normally again

new apps mgmt: clarify wording from 'Installed' to 'Enabled'

reintroduce enable/disable

Move rating image path generation to client-side

Move expression outside of l10n

fix group handling

add buttons for 'More apps' and 'Add your app' again

disable changed date of app for now

adding recommended label

style 'Recommended' app tag

fixing php warning

sort by rating

adding meta-category 'Recommended'

 Only show existing documentation links

lacy loading of screenshots

making group based app activation work again

adding support to get the app icon not only by the app name but also simply by the fixed name 'app.svg'

adding app.svg for all core apps

query string '?installed' is not longer needed

update and uninstall is back + error feedback

remove unneeded parameter

fix alignment of 'recommended' label
2014-10-15 15:21:40 +02:00
Bjoern Schiessle 239bff5766 strip whitespace from the beginning and end of the display name to avoid empty display names 2014-10-15 14:54:35 +02:00
Vincent Petry 6824a5ce7f Merge pull request #11538 from owncloud/webdav-creatable-info
Use the cached fileinfo to get creatable permissions
2014-10-15 14:39:07 +02:00
Lukas Reschke 6ccda2ae98 Add app version to JS and CSS
This leads to the regeneration of the hash in case a single application is updated.

Fixes https://github.com/owncloud/core/issues/11374
2014-10-15 14:00:20 +02:00
Vincent Petry 6fa03870e9 Merge pull request #11541 from owncloud/usersession-activeuser-setsession
Unset the cached active user when using a different session object
2014-10-15 13:31:05 +02:00
Vincent Petry 4650101674 Merge pull request #11548 from owncloud/extstorage-ocfields
Allow specifying protocol in ext storage OC config
2014-10-15 13:27:23 +02:00
Lukas Reschke 1b3feb710d Use `rawurlencode` since this seems to be expected by cURL
Fixes https://github.com/owncloud/core/pull/11501#issuecomment-58794405
2014-10-14 13:16:23 +02:00
Lukas Reschke bf84cd4bcc Add darwin to if block
Otherwise it would fall into the 'win' else block because strpos($os, 'win') does also match 'darwin' what is the `php_uname` for OS X.
2014-10-14 12:58:00 +02:00
Joas Schilling 0407bc0978 Set overwritemailurl* configs on setup
Correctly use overwritemailurl value when generating absolute urls in CLI

Fix #11500

Rename the config to *cli

Add overwrite.cli.url to the sample config

Revert separator fix, fixes unit test
2014-10-14 05:07:09 +02:00
goodkiller 9f0b99cd17 Update group.php
Here is fox for my LDAP users OW 7.0.2
2014-10-14 01:18:45 +03:00
Bernhard Reiter b416f7d8ac PHPDoc fixes as suggested by @MorrisJobke. 2014-10-14 00:06:33 +02:00
Bernhard Reiter 1770179648 Add getTag() function for accessing of a single tag. 2014-10-14 00:06:33 +02:00
Bernhard Reiter bc265e8b52 Make loading of tags from DB more explicit. 2014-10-14 00:06:07 +02:00
Bernhard Reiter 226d7233e1 In Tags::rename($from, $to), check if there already is a tag named $to. 2014-10-14 00:06:07 +02:00
Bernhard Reiter 7e9baafc53 Add option to include tags for shared items. 2014-10-14 00:06:07 +02:00
Bernhard Reiter 7963125c41 Remove two obsolete try...catch blocks. 2014-10-14 00:06:07 +02:00
Bernhard Reiter 5471189fe6 Implement Tag and TagMapper classes.
Subclassed from \OCP\AppFramework\Db\Entity and Mapper,
respectively. This will allow us to also deal with shared tags.
2014-10-14 00:06:07 +02:00
Bernhard Reiter cf6fb2c2e4 Remove redundant null initializations. 2014-10-14 00:06:07 +02:00
Bernhard Reiter 3e5d725502 Test addMultiple() with $sync=true. 2014-10-14 00:06:07 +02:00
Vincent Petry e95372bf01 Merge pull request #11546 from owncloud/users-deletewithfilecache
Retrieve storage numeric id earlier when still available
2014-10-13 17:27:13 +02:00
Vincent Petry ab5149f5df Allow specifying protocol in ext storage OC config
Allow specifying a protocol in the host field when mounting another
ownCloud instance. Note that this was already possible with the WebDAV
config but this bug made it inconsistent.
2014-10-13 17:15:58 +02:00
Vincent Petry d485c0098d Retrieve storage numeric id earlier when still available
The numeric id is only available before the storage entry is deleted, so
get it at that time.
2014-10-13 15:52:48 +02:00
Bjoern Schiessle c6c9a51b11 distinguish between file dependent shares and other shares 2014-10-13 15:04:54 +02:00
Robin Appelman 912fbfab01 Unset the cached active user when using a different session object 2014-10-13 13:11:48 +02:00
Robin Appelman 19de425a50 Use the cached fileinfo to get creatable permissions 2014-10-13 13:09:05 +02:00
Lukas Reschke bf674487aa Merge pull request #11367 from owncloud/removeIsMimeSupported
Remove uneeded slicing of element
2014-10-12 19:45:00 +02:00
Björn Schießle 87899db204 Merge pull request #11380 from owncloud/fix_performance_issue_sharing
[sharing] fix performance issues
2014-10-10 15:56:30 +02:00
Bjoern Schiessle 3431d547a9 fix performance issues 2014-10-10 12:16:26 +02:00
Vincent Petry 660e9c4012 Merge pull request #11501 from Ansud/master
Urlencode file name before passing it to cURL
2014-10-10 10:57:59 +02:00
Vincent Petry 9dea79e341 Merge pull request #11305 from owncloud/ext-updateetagonmount
Update etag of parent dir when adding/removing ext storage mount points
2014-10-09 18:18:36 +02:00
Vincent Petry c82e310e20 Merge pull request #11495 from owncloud/apps-clearenableappscacheafterloadingauthapp
Clear enabled apps cache after loading authentication app
2014-10-09 17:20:05 +02:00
Lukas Reschke 16cd749065 Add support for keys in the info.xml
This allows to have links to different doc base URLs

a.
2014-10-09 15:48:30 +02:00
Tony Zelenoff 2d03019c91 Urlencode file name before passing it to cURL
Large file helper use cURL to determine file sizes. Thus filenames must be
urlencoded in case special symbols like '#' can cause BadRequest errors.

Signed-off-by: Tony Zelenoff <antonz@parallels.com>
2014-10-09 17:15:12 +04:00
Vincent Petry 36d22825e0 Clear enabled apps cache after loading authentication app
Since getEnabledApps() depends on an authentication app to be loaded,
especially in the case of LDAP, the cache from getEnabledApps() is now
cleared to make sure that subsequent calls will properly return apps
that were enabled for groups.
This is because getEnabledApps() uses the inGroups() function from the
group manager provided by LDAP or any other authentication app.
2014-10-09 14:34:41 +02:00
Jörn Friedrich Dreyer 3427976bb6 strict comparison 2014-10-08 18:49:55 +02:00
Jörn Friedrich Dreyer aa3ad898a9 fix amazon s3 issues
folder size and mtime is always unknown in s3

more s3 fixes

make rescanDelay of root dir configurable, add on the fly update of legacy storage ids, !isset -> empty when checking strings

reduce number of http calls on remove and rmdir

fix typo
2014-10-08 18:49:47 +02:00
Robin Appelman 12ac3a800d Expose getAppKeys trough \OCP\IConfig 2014-10-08 14:22:17 +02:00
Vincent Petry 6585eaa5df Added failing unit tests for mount config hooks 2014-10-08 14:22:17 +02:00
michag86 8abe441d4a cleanup group admin(s) on deleteGroup 2014-10-08 14:05:06 +02:00
michag86 ca58ac50a2 fix for issue #10880 2014-10-07 16:07:48 +02:00
Vincent Petry d7db006315 Revert "fix for issue #10880"
This reverts commit 0df070a8e4.
2014-10-07 15:54:25 +02:00
michag86 0df070a8e4 fix for issue #10880 2014-10-07 14:30:14 +02:00
Victor Dubiniuk b6087ea79b Add CssImportFilter. More elegant fix for documents#348 2014-10-06 19:39:02 +03:00
Morris Jobke a6293a38f2 Merge pull request #11390 from Nemesiz/master
Preview large TXT files fix
2014-10-06 14:25:27 +02:00
Olivier Paroz b0000800e1 New generic class for Imagemagick conversions 2014-10-04 17:50:12 +02:00
Nmz 83c2829ca8 Preview large TXT files fix
Limit the size of the string generating the preview image for TXT files
2014-10-02 12:47:39 +03:00
Lukas Reschke e762ff2bbd Merge pull request #11356 from owncloud/redirect-only-to-the-same-domain
Redirect only to absolute URL
2014-10-01 12:47:43 +02:00
Lukas Reschke cbecd62287 Merge pull request #11303 from owncloud/addFilelockToConfig
Add flock to config
2014-10-01 10:43:18 +02:00
Morris Jobke 5beeb923e6 Merge pull request #11365 from owncloud/fix-phpdoc
Fix PHPDoc
2014-09-30 16:15:37 +02:00
Lukas Reschke 68cf6681e5 Add flock to config
This adds a file lock to the config in hope that this prevents race conditions as reported in https://github.com/owncloud/core/issues/11070

Testplan:

- [ ] Delete config.php and make it read-only => Error is thrown that it is not writeable
- [ ] Installation still works
- [ ] Changing config settings works (i.e. using the SMTP config switches in the administration menu)
- [ ] Your PC didn't blow up
- [ ] Installing the news app and the "Disable AppCode checker" app did not destroy your installation

Only skip the main config

Otherwise read only additional configs might not be processed

Test on tmpdir
2014-09-30 15:53:27 +02:00
Lukas Reschke 96d9e0eb5b Remove uneeded slicing of element
The "*/*" provider has been removed. This is therefore not needed anymore and leads to unexpected bugs.

Please notice that this is only relevant for master.
2014-09-30 14:08:43 +02:00
Lukas Reschke 67f8875f47 Remove invalid PHPDoc
Despite the documentation this function does not read values from the cookie
2014-09-30 13:46:43 +02:00
Lukas Reschke b4944ffcc5 Fix PHPDoc 2014-09-30 13:34:50 +02:00
Lukas Reschke 8c8e5c168e Merge pull request #10107 from owncloud/sharing_group_shares
[sharing] group shares
2014-09-29 20:26:41 +02:00
Lukas Reschke 41374986d3 Remove dead code 2014-09-29 17:20:29 +02:00
Lukas Reschke 6e7365fc17 Redirect only to absolute URL
We do not want to redirect to other domains using the "?redirect_url=" feature. Please notice, that the ownCloud project does not consider open redirectors as security issue.
2014-09-29 17:07:43 +02:00
Bjoern Schiessle 6e7acb8ae0 some small fixed, suggested by scrutinizer 2014-09-29 11:23:18 +02:00
Bjoern Schiessle 2a4da7fe09 on unshare only unshare childrens if there is no other parent available 2014-09-26 16:58:47 +02:00
Lukas Reschke 53f6d74938 Merge pull request #11311 from owncloud/fixing-unhandled-exception-cleanTmp-master
catch and log exception in OC_Helper::cleanTmp()
2014-09-26 14:31:31 +02:00
Bjoern Schiessle e115a7043f only create a new share entry, if the user needs a different target name than the group share 2014-09-26 13:19:15 +02:00
Bjoern Schiessle ed85055d31 for group shares we don't need a extra db entry of groupTarget equals itemTarget 2014-09-26 13:10:31 +02:00
Bjoern Schiessle d242e518f9 for group shares only the parent has the up-to-date permission. Make sure that we always use this permission, except if the user permission is '0' because in this case the user unshared the group share from self 2014-09-26 13:01:54 +02:00
Thomas Müller 4c08215e66 catch and log exception in OC_Helper::cleanTmp() 2014-09-26 11:36:53 +02:00
Thomas Müller e5a111b80e Merge pull request #11285 from owncloud/dav-permissions-create
Fix dav permissions for folders
2014-09-26 09:21:32 +02:00
Robin Appelman 6365c57b04 Merge pull request #11282 from owncloud/scanner-memory-stable7
Don't keep the full info of all children in memory
2014-09-25 15:53:33 +02:00
Vincent Petry 9fc23e1967 Merge pull request #10934 from owncloud/datadir-write-setup
Don't complain about non-writable datadirs before we're installed
2014-09-25 14:32:32 +02:00
Bjoern Schiessle 52b6469b0c call \OCP\Share::getItemsSharedWithUser() to get exclude list, this way all checks are executed, e.g. to check if the share is really visible 2014-09-25 14:26:31 +02:00
Robin Appelman 10c350b895 Fix dav permissions for folders without create permissions 2014-09-25 14:01:19 +02:00
Robin Appelman ccb4475a8d Expose creatable permissions trough fileinfo 2014-09-25 14:00:13 +02:00
Bjoern Schiessle 968152113e always select permissions, used in getItems() 2014-09-25 12:35:11 +02:00
Bjoern Schiessle d5fc011c90 some small fixes 2014-09-25 11:29:57 +02:00
Lukas Reschke cb002c1f6b Clarify possible preview providers for type Office
a
2014-09-24 21:21:39 +02:00
Robin Appelman f88021dbbc Don't keep the full info of all children in memory 2014-09-24 15:44:56 +02:00
Lukas Reschke 3da6b3b533 Merge pull request #11229 from kofemann/for-upstream
user/backed: use pow of two for backed action constants
2014-09-24 15:19:11 +02:00
Bjoern Schiessle 07d43df713 only add a new row if it isn't a unique share, otherwise update the existing row 2014-09-24 14:02:02 +02:00
Bjoern Schiessle 9f7b15582a fix add user to group to work with grouped shares 2014-09-24 14:02:01 +02:00
Bjoern Schiessle bd268c35f5 generateTarget() will always find a unique target 2014-09-24 14:02:01 +02:00
Lukas Reschke 75e45ac786 Merge pull request #11019 from owncloud/do-not-show-exception-to-enduser
Do not show exception to the end-user - use a proper error page instead
2014-09-23 18:36:40 +02:00
Vincent Petry 89e02e89d4 Merge pull request #7051 from owncloud/postsetupajaxcheck
Moved WebDAV check to client side JS
2014-09-23 16:55:16 +02:00
Tigran Mkrtchyan 276f50a1ba user/backed: use pow of two for backed action constants
the current implementation limits number of possible backed actions
to 8 as it uses pow of 16 for constants. This change introduces pow
of two and allows up-to 32 actions to be defined.

The old values are preserved for backward compatibility.
2014-09-23 15:18:01 +02:00
Thomas Müller c587a4aaa2 Merge pull request #11222 from owncloud/store-users-timezone-master
send browsers timezone back tp the server on login
2014-09-23 13:45:21 +02:00
Thomas Müller 42fe0b9e08 Merge pull request #11241 from owncloud/use-lower-case
Use only lower-case letters
2014-09-23 12:16:58 +02:00
Lukas Reschke 5d977f97b0 Merge pull request #11032 from owncloud/harden-redirect
Do only follow HTTP and HTTPS redirects
2014-09-23 11:34:44 +02:00
Vincent Petry e65ceb08fc Moved WebDAV and internet checks to client side JS
- Added setup checks in JavaScript
- Moved isWebDAVWorking to JS using SetupChecks
- Moved internet connection checks to an ajax call that goes through the
  server
2014-09-23 11:16:14 +02:00
Vincent Petry fc42a64e6c Merge pull request #11226 from owncloud/kill-postsetupcheck-master
remove post setup check
2014-09-23 10:33:50 +02:00
Thomas Müller 37a5bff155 Merge pull request #11227 from owncloud/fix-windows-path
fixing directory seperators
2014-09-23 07:38:23 +02:00
Morris Jobke f970c81b1e Merge pull request #11215 from owncloud/dav-throwwhendeletefailed
WebDAV now throws 403 when deletion did not work
2014-09-23 00:49:30 +02:00
Morris Jobke 051ed93e24 Merge pull request #11211 from owncloud/previewProviderSwitch
Add a configuration switch for enabled preview mimetypes
2014-09-23 00:45:59 +02:00
Lukas Reschke 1565d82b81 Use only lower-case letters
Fixes https://github.com/owncloud/core/issues/11239
2014-09-22 21:29:03 +02:00
Lukas Reschke 6eeb905871 Do only follow HTTP and HTTPS redirects
We do not want to follow redirects to other protocols since they might allow an adversary to bypass network restrictions. (i.e. a redirect to ftp:// might be used to access files of a FTP server which might be in a secure zone and not be reachable from the net but from the ownCloud server)

Get final redirect manually using get_headers()

Migrate to HTTPHelper class and add unit tests
2014-09-22 20:02:32 +02:00
Thomas Müller 21412559df remove post setup check 2014-09-22 19:43:55 +02:00
Bjoern Schiessle 9105e17307 unit tests for grouping of shares pointing to the same source 2014-09-22 17:54:47 +02:00
Bjoern Schiessle 89c3b650e6 group shares and combine permissions 2014-09-22 17:25:15 +02:00
Morris Jobke 9e8d2907e2 Merge pull request #11204 from owncloud/fix_oc_stream_seek
Fix oc stream seek
2014-09-22 16:25:07 +02:00
Clark Tomlinson db72270acc fixing directory seperators 2014-09-22 10:13:46 -04:00
Lukas Reschke ca3447fcde Add a configuration switch for enabled preview mimetypes 2014-09-22 16:09:08 +02:00
Thomas Müller 814114ab8e enhance formatDate function to accept an optional argument containing the time zone 2014-09-22 15:03:28 +02:00
Morris Jobke 831d34f084 Merge pull request #11210 from owncloud/issue/11209
Also match routes without trailing slash for files app
2014-09-22 14:04:20 +02:00
Vincent Petry 470c25eff4 WebDAV now throws 403 when deletion did not work
Assume a permission issue whenever a file could not be deleted.

This is because some storages are not able to return permissions, so a
permission denied situation can only be triggered during direct
deletion.
2014-09-22 13:15:17 +02:00
blizzz b8a1340538 Merge pull request #9225 from voxsim/fix_displayNamesInGroup
fix in displayNamesInGroup
2014-09-22 12:13:15 +02:00
Jörn Friedrich Dreyer f83689e1be in quota wrapper use === instead of ! for better readability and as in other wrappers 2014-09-22 11:35:42 +02:00
Jörn Friedrich Dreyer 561a7e47cd return boolean in Ciose::stream_seek 2014-09-22 11:33:55 +02:00
Joas Schilling 71bec60b92 Also match routes without trailing slash
Fix #11209
2014-09-22 11:22:33 +02:00
Jörn Friedrich Dreyer b752cb98d8 return boolean in OC::stream_seek 2014-09-22 11:20:15 +02:00
Thomas Müller 8abf786af9 Merge pull request #10499 from owncloud/mkcol-headers-afterbind
Use afterBind to send fileId header for files and directories
2014-09-22 10:02:03 +02:00
Morris Jobke 154e848ce2 Merge pull request #11199 from owncloud/delete_bogus_previews
Delete bogus cached previews while updating
2014-09-21 22:48:21 +02:00
Georg Ehrke 071e4bfc06 make sure preview prop is instanceof OC_Image before using it in showPreview 2014-09-21 17:30:29 +02:00
Georg Ehrke ab2554e013 delete old previews 2014-09-21 17:16:21 +02:00
Thomas Müller 7537d405e3 adding 'smallint unsigned' to type mapping for sqlite 2014-09-20 20:06:44 +02:00
Morris Jobke 463dd44d6d Merge pull request #11178 from owncloud/throw-error-on-preview-instead-in-the-contructor
Throw error in showPreview instead the constructor
2014-09-19 21:39:30 +02:00
Lukas Reschke 4c6bad7f71 Merge pull request #11158 from owncloud/fix_basic_auth
Move BasicAuth check to isLoggedIn
2014-09-19 13:39:13 +02:00
Lukas Reschke 6869d2e82a Throw error in showPreview instead the constructor
This function is also used in a way such as:

```
	$preview = new \OC\Preview(\OC_User::getUser(), 'files');
	$info = \OC\Files\Filesystem::getFileInfo($file);
	if (!$always and !$preview->isAvailable($info)) {
		\OC_Response::setStatus(404);
	} else {
		$preview->setFile($file);
		$preview->setMaxX($maxX);
		$preview->setMaxY($maxY);
		$preview->setScalingUp($scalingUp);
		$preview->setKeepAspect($keepAspect);
	}
```

Which won't work anymore since `setFile` is used instead of passing the file in the constructor. Fixes a regression in master.
2014-09-19 13:26:41 +02:00
Vincent Petry 437f8c3cd5 Merge pull request #11119 from owncloud/removeOldUpgradeRoutines
Remove old upgrade routines
2014-09-19 12:23:42 +02:00
Vincent Petry f0186d99d2 Merge pull request #11163 from owncloud/check-for-updates-between-major-versions
Prevent updates between multiple major versions
2014-09-19 12:20:22 +02:00
Robin Appelman 33f7af9207 Merge pull request #10958 from owncloud/db-ilike
Introduce cross-db ILIKE
2014-09-19 12:07:56 +02:00
Lukas Reschke a71af58535 Prevent updates between multiple major versions
Ref https://github.com/owncloud/core/issues/11078
2014-09-18 17:56:06 +02:00
voxsim 7a14f94ae5 1. remove sizeof($filteredUsers) > 0 as condition
2. use count instead of sizeof. Latter is an alias to first one, practically we stick to count everywhere. Having it consistent helps with readability.
3. move whitespace so we have $groupUsers[] = $filteredUser; instead of $groupUsers []= $filteredUser;
2014-09-18 17:50:19 +02:00
Lukas Reschke d0d3b7457b Move BasicAuth check to "isLoggedIn()"
Ensures that Basic Auth works properly for APIs and removes the need for some even uglier lines of code.
2014-09-18 16:14:07 +02:00
Robin Appelman a85f0ae2da Fix ILIKE without wildcards for oracle 2014-09-18 15:09:57 +02:00
Robin Appelman c8dbdc29d0 Check for writable datadir during setup 2014-09-18 14:15:52 +02:00
Robin Appelman 23dd7cb51d Don't complain about non-writable datadirs before we're installed 2014-09-18 13:33:13 +02:00
Robin Appelman 6fa3280c2a Inject config into checkserver and cleanup tests 2014-09-18 13:33:13 +02:00
Lukas Reschke d07d5915c9 Remove unused and overflowing function
Resolves https://github.com/owncloud/core/issues/10991 failure 4
2014-09-18 10:21:28 +02:00
Morris Jobke c89c6ed21d Merge pull request #11143 from owncloud/improve-404
Make 404 page easier to understand
2014-09-18 09:10:16 +02:00
Lukas Reschke 8fc1a9f5a9 Make 404 page easier to understand
Fixes https://github.com/owncloud/core/issues/11133
2014-09-17 22:57:32 +02:00
Remco Brenninkmeijer f930b356e6 Error needs to push body-id for new guest layout 2014-09-17 18:02:18 +02:00
Lukas Reschke ef0a0f5f87 Merge pull request #9554 from owncloud/fix_preview_orientation
fix orientation in image-backend, not in preview system itself
2014-09-17 17:05:47 +02:00
Robin Appelman 0c03b2bdd5 Use ILIKE in cache search 2014-09-17 16:12:54 +02:00
Lukas Reschke c88d517e88 Merge pull request #10622 from owncloud/recursive-delete-forbidden
Fix isDeletable
2014-09-17 15:36:41 +02:00
Robin Appelman 67b1ec1faf Implement ILIKE for sqlite 2014-09-17 13:47:55 +02:00
Robin Appelman 60587e9dcd Make sqlite LIKE case sensitive on default 2014-09-17 13:47:33 +02:00
Morris Jobke c6eab9aaba fix error message template 2014-09-17 13:25:50 +02:00
Lukas Reschke 6d3757f864 Do not show exception to the end-user
Log the error instead of potentially leaking sensitive information
2014-09-17 13:17:52 +02:00
Morris Jobke b644e8a5e7 Merge pull request #10932 from owncloud/issue/10926
Add a method to get the absolute url for a route
2014-09-17 13:05:26 +02:00
Lukas Reschke 33c0d2f743 Fix mapping of relative paths 2014-09-17 11:38:10 +02:00
Robin Appelman 2f22e67570 Also check if the file itself is updatable 2014-09-17 11:35:16 +02:00
Robin Appelman d25a9a118f Check if a folder is deletable before we try to recursively delete it 2014-09-17 11:35:16 +02:00
Robin Appelman ab79caf29b Check if the parent is writable to check if a file is deletable 2014-09-17 11:35:16 +02:00
Lukas Reschke 0d37e16499 Merge pull request #11092 from owncloud/conceal_sabredav_version
Conceal or display SabreDAV version number.
2014-09-17 10:35:50 +02:00
Lukas Reschke 2cfa07049f Remove old upgrade routines
We do not support updates from 6 to 8 directly, therefore we can remove those upgrade routines.
2014-09-16 20:27:52 +02:00
Lukas Reschke 368391e401 Merge pull request #11009 from owncloud/tobiasKaminsky-route
REST API for thumbnails
2014-09-16 19:31:51 +02:00
Lukas Reschke 4ebc11aa8d Merge pull request #11102 from owncloud/visit1985-issue_108
mysql setup: if dbuser exists try a different one (owncloud/core#108)
2014-09-16 18:54:37 +02:00
Lukas Reschke d2743e6ad6 Merge pull request #7254 from owncloud/core-sortalgo
Fixed JS sort comparator to be consistent between JS and PHP
2014-09-16 17:29:03 +02:00
Thomas Müller ba445e85b2 Merge pull request #11082 from owncloud/deduplicateDependencyCheck
Deduplicate dependency checks
2014-09-16 16:33:02 +02:00
Lukas Reschke 2f10b60c9e Merge pull request #10754 from cetra3/master
Refactor internal session handler to write directly to $_SESSION
2014-09-16 15:48:19 +02:00
Thomas Müller ca35d86c5a adding ILIKE to AdapterSQLSrv 2014-09-16 15:44:21 +02:00
Robin Appelman 1771bfc2f2 Introduce cross-db ILIKE 2014-09-16 15:32:34 +02:00
tobiasKaminsky e62d5b7e55 Route for thumbnail generation
Thumbnail generation

Removed Log

Added requested changes

Added requested changes.

- Fix code style
- Add exception if file does not exist
- Switch route styling

Replaces https://github.com/owncloud/core/pull/10805

Fix codestyle

Fix codestyle

Migrate to appframework

Fix typo
2014-09-16 15:00:58 +02:00
Lukas Reschke 261d07c95c Merge pull request #11084 from owncloud/no-migration-for-mssql-master
Disable database migrations for MSSQL - scripts have to be applied manua...
2014-09-16 14:00:24 +02:00
scolebrook f31e4066de Conceal or display SabreDAV version number in browser and http response headers. 2014-09-16 13:25:44 +02:00
Lukas Reschke 5813cf32dc Deduplicate dependency checks
Some code that I also used for https://github.com/owncloud/administration/pull/11
2014-09-16 13:07:47 +02:00
Michael Göhler e6609d0970 simplify mysql user creation flow
if dbuser exists try a different one, owncloud/core#108

changed outdated comment

corrected length calculation

changed indentation for else clauses
2014-09-16 11:53:54 +02:00
Morris Jobke dd70d1b88c Merge pull request #11090 from owncloud/fix-undefined-class-and-phpdoc
Fix unexisting class and PHPDoc
2014-09-16 10:29:01 +02:00
Morris Jobke af52ffc5d5 Merge pull request #10639 from owncloud/fix_naming_schema_preview_with_aspect
add y to with-aspect naming schema
2014-09-16 08:36:33 +02:00
Morris Jobke 245a0e2ad8 Merge pull request #10362 from owncloud/preserve_transparency_on_fileload
Preserve transparency when loading from a file
2014-09-16 08:33:56 +02:00
voxsim 1366133d2b add more logic in displayNamesInGroup for big user bases 2014-09-15 18:37:54 +02:00
Lukas Reschke 4f0f7e35ca Fix unexisting class and PHPDoc
You can't add int here as hint...
2014-09-15 17:08:56 +02:00
Morris Jobke 06eb3b62c6 Merge pull request #10109 from owncloud/issue_#9793_guestlayout
Step one, open guest layout for different styles.
2014-09-15 15:15:41 +02:00
Georg Ehrke cf76933b76 add phpdoc 2014-09-15 15:10:03 +02:00
Georg Ehrke 3157d307f7 add y to with-aspect naming schema 2014-09-15 15:10:03 +02:00
Thomas Müller d824d03fe1 Disable database migrations for MSSQL - scripts have to be applied manually 2014-09-15 15:00:32 +02:00
Lukas Reschke 07b14bcd4f Merge pull request #10960 from owncloud/use-intl-module-master
use intl's native normalizer_normalize() in case the module is available
2014-09-15 14:13:30 +02:00
Raghu Nayyar 1145529584 Merge pull request #11041 from owncloud/no-size-check-on-lock-master
content size checks are not valid for LOCK
2014-09-13 00:48:52 +05:30
Lukas Reschke 5ff999d69d Return false in case one of the values is null 2014-09-12 13:34:45 +02:00
Thomas Müller 27cd30aa94 content size checks are not valid for LOCK 2014-09-12 09:42:32 +02:00
Thomas Müller 4878f7a416 Merge pull request #11006 from owncloud/addCustomHex2BinImplementationBecauseSupporting53IsSomethingReallyReallyCoolAndWeAreObviouslySomeOfTheCoolGuys
Add custom hex2bin implementation for 5.3
2014-09-11 15:05:36 +02:00
Lukas Reschke 7d2c521b46 Step one, open guest layout for different styles.
Conflicts:
	core/templates/layout.guest.php

Step one, open guest layout for different styles.
2014-09-11 11:41:02 +02:00
Thomas Müller 59209e0f2b use intl's native normalizer_normalize() in case the module is available 2014-09-11 10:24:31 +02:00
Lukas Reschke bfebbe47de Merge pull request #10962 from owncloud/repair_search_lucene
repair search lucene before installing
2014-09-11 10:09:43 +02:00
Lukas Reschke 1973275adc Add custom hex2bin implementation for 5.3
Fixes https://github.com/owncloud/core/issues/11004
2014-09-11 09:51:45 +02:00
kondou 18ef7bf1ed Preserve transparency when loading from a file
Fix #7148 - again :)
2014-09-10 23:49:21 +02:00
Thomas Müller 2a382a87d5 Merge pull request #10988 from owncloud/usetransactions-wrong-name
Fix method name useTransactions
2014-09-10 17:27:23 +02:00
Robin Appelman fa2b385d33 Fix method name 2014-09-10 15:59:24 +02:00
Vincent Petry 70ebe86e60 Merge pull request #10929 from owncloud/issue/10514
Set overwritewebroot when installing owncloud to avoid problems
2014-09-10 15:07:57 +02:00
Jörn Friedrich Dreyer 8e2acb1482 repair search lucene before installing 2014-09-10 10:22:40 +02:00
Bernhard Posselt ba698a4942 Merge pull request #10972 from ppaysant/routes-defaults
Allow default values for route parameters.
2014-09-09 23:40:46 +02:00
Lukas Reschke c3d90b96c8 Merge pull request #10922 from owncloud/explicit-scan-transactions
Use bigger transactions when doing explicit file system scans
2014-09-09 23:32:32 +02:00
Patrick Paysant cb5416b798 Allow default values for route parameters. 2014-09-09 23:00:29 +02:00
Bernhard Posselt 023e066971 more sugar for including lists of templates 2014-09-09 15:47:42 +02:00
Bernhard Posselt d02f6c7ebe Merge pull request #10947 from owncloud/html-imports
add template functions for html imports
2014-09-09 14:07:46 +02:00
Jörn Friedrich Dreyer 3d4f77c8f1 Merge pull request #10949 from owncloud/allow_prefilling_login
allow prefilling login
2014-09-09 11:42:14 +02:00
Lukas Reschke 353155b516 Merge pull request #7323 from owncloud/Jonny007-MKD-master
Update adapter.php
2014-09-09 11:31:50 +02:00
Jörn Friedrich Dreyer ed2414fd0d Merge pull request #10886 from owncloud/keep_fileid_on_move_in_objectstore
Keep fileid on move in objectstore, fixes #10848
2014-09-09 10:25:10 +02:00
VicDeo efd485acda Merge pull request #10858 from owncloud/issue/10847
Use correct language package so the subject is correctly translated
2014-09-09 01:11:34 +03:00
Jörn Friedrich Dreyer 0aad7fa1b1 allow prefilling login 2014-09-08 21:44:13 +02:00
Bernhard Posselt f685d03674 append .html since componets always use html files 2014-09-08 21:37:18 +02:00
Bernhard Posselt 4aff85cd0c add template functions for html imports 2014-09-08 21:19:44 +02:00
Lukas Reschke 70abce0482 Merge pull request #10739 from owncloud/eventsource-public
Add EventSource to the public API
2014-09-08 18:46:27 +02:00
Lukas Reschke c79c894dbb Merge pull request #10755 from owncloud/shorter_sharing_links
Shorter sharing links
2014-09-08 17:26:20 +02:00
Lukas Reschke 2d847934ed Merge pull request #10938 from owncloud/useSecureMimetype
Use secure mimetype for content delivery
2014-09-08 17:13:54 +02:00
Lukas Reschke 5de404eb92 Merge pull request #10827 from oparoz/patch-2
Libreoffice config folder needs to be set
2014-09-08 16:41:26 +02:00
Lukas Reschke fa718d2e2c Fix typo 2014-09-08 16:34:03 +02:00
Lukas Reschke 0cdfe4f8c2 Merge pull request #10911 from owncloud/template-funcs
Add template shortcut functions for style and script
2014-09-08 16:32:05 +02:00
Lukas Reschke 312ed18d15 Use secure mimetype for content delivery
Adds some hardening against potential CSP bypassed.
2014-09-08 15:57:39 +02:00
Joas Schilling c5b5378558 Add a method to get the absolute url for a route
Fix #10926
2014-09-08 14:43:14 +02:00
Joas Schilling 249558966e Set overwritewebroot when installing owncloud to avoid problems
Fix #10514
2014-09-08 14:30:13 +02:00
Robin Appelman 644755df66 Use bigger transactions when doing explicit file system scans 2014-09-08 14:15:41 +02:00
Vincent Petry 637cff68ac Merge pull request #10862 from chli1/master
fix BadRequest error if CONTENT_LENGTH not set
2014-09-08 10:00:15 +02:00
cetra3 459ead69f6 Merge branch 'master' of https://github.com/owncloud/core 2014-09-08 15:05:49 +09:30
Bernhard Posselt 7e4d244200 add shortcut functions for style and script 2014-09-06 14:25:28 +02:00
Jörn Friedrich Dreyer 8488be4d03 Keep fileid on move in objectstore, fixes #10848 2014-09-05 13:25:59 +02:00
Robin Appelman e29b7e9335 Remove explicit propagate calls 2014-09-05 11:53:24 +02:00
Robin Appelman d0e83a71aa Update cache before post hooks 2014-09-05 11:53:24 +02:00
Robin Appelman 1d8a88dd1b Fix warning in homecache 2014-09-05 11:53:23 +02:00
Robin Appelman 850542c5d6 Refactor Cache\Updater to work outside of the users home 2014-09-05 11:53:23 +02:00
kondou ecc9b42e41 Match \OC_Helper::linkToPublic() to new links and fit unittests 2014-09-04 20:44:50 +02:00
kondou a10411d2bc Readd TOKEN_LENGTH 2014-09-04 19:09:26 +02:00
Jesus Macias Portela 523680cef2 Merge pull request #10840 from owncloud/issue_10674
Solve bug with touch always return true on /lib/private/files/view.php
2014-09-04 17:29:08 +02:00
kondou 226b203e20 Use base62 and remove configuration options for link length 2014-09-04 16:20:20 +02:00
kondou c2d8eabd71 Change config.sample entry and use MediumSecurity 2014-09-04 15:52:23 +02:00
kondou 3bf725d7e0 Adapt token size to new generation and add an option for free length specification
Minimum size is 3 = 46656 tokens, maximum size is 64, which is what our DB allows.
2014-09-04 15:24:33 +02:00
kondou 2a4c51389c Use a route instead of s.php and convert tokens asap 2014-09-04 15:23:55 +02:00
kondou 0f2ad9862e Initial work on shorter links 2014-09-04 15:23:53 +02:00
Lukas Reschke 1a7df33233 Merge pull request #10818 from owncloud/enableappforgroupfix
Fix upgrade process when apps enabled for specific groups
2014-09-04 13:56:41 +02:00
chli1 712487c861 fix BadRequest error if CONTENT_LENGTH not set
If client does not send content length header on webdav upload (e.g. because the content comes from a stream and its length is not predictable) the put() method should not try to compare the content length value with the actually amount of received data, because this will always fail and results in a BadRequest exception. So the check will only be performed if $_SERVER['CONTENT_LENGTH'] is set.
2014-09-04 13:49:15 +02:00
Robin Appelman fa3393674c Better phpdoc and method naming 2014-09-04 13:26:51 +02:00
Robin Appelman 8605e2e6a5 Explicitly cast id and validate type 2014-09-04 13:26:47 +02:00
Olivier Paroz bbc2d7cf4f Typ in whichOpenOffice test 2014-09-04 12:54:20 +02:00
Joas Schilling a0e8e88bc6 Use correct language package so the subject is correctly translated
Fix #10847
2014-09-04 11:23:23 +02:00
Lukas Reschke 8fec19a872 Merge pull request #10790 from cbhp/master
added missing User-Agents
2014-09-03 22:40:12 +02:00
Jesus Macias 91c8174013 Fix code with previous comments 2014-09-03 18:21:24 +02:00
Jesus Macias 883649b69c Reset changes on 3rdparty submodule 2014-09-03 18:20:09 +02:00
cbhp c00450b2c7 always use a user-agent constant
Some providers block connections with missing user-agents. Also
user-agents are useful for analyzing requests. I've added a USER_AGENT
constant that is used in cURL and in file_get_contents.
2014-09-03 18:00:05 +02:00
Lukas Reschke 63a90a129b Use proper RNG generator
OC_Util::generateRandomBytes() only returns lowercase alphanumeric values.
We should use the new RNG which has a broader characterset.
2014-09-03 17:46:48 +02:00
Lukas Reschke 26f337d523 Only return lowercase letters and digits for backwards compatbility 2014-09-03 17:18:00 +02:00
Thomas Müller 954925eaa0 Merge pull request #10667 from pmjdebruijn/itunes-appid
defaults: add customizable defaultiTunesAppId
2014-09-03 16:26:20 +02:00
Olivier Paroz eaab067716 env:UserInstallation was already there in master
My changes were made against stable7 and I merged them to the file in master, so this version is now the properly merged file for master.
I'm just adding `owncloud-<instanceid>` to the path where temp files are stored.
2014-09-03 16:08:40 +02:00
Lukas Reschke 373d1c5e9f Merge pull request #10642 from owncloud/securityutils
Add some security utilities
2014-09-03 15:28:42 +02:00
Clark Tomlinson d64cacec43 Merge pull request #10826 from oparoz/master
Adding TIFF support to the files app
2014-09-03 09:14:35 -04:00
Clark Tomlinson 0400f7845c Merge pull request #10723 from owncloud/webdav-folder-size
adding new webdav property containing the folder size
2014-09-03 09:07:23 -04:00
Robin Appelman 65608d7c92 Use the public api to get event sources 2014-09-03 13:36:15 +02:00
Robin Appelman dad53180bc Add event source to the public api 2014-09-03 13:36:15 +02:00
Robin Appelman 54c918fe48 Initialize an event source when we start using it, not in the constructor 2014-09-03 13:35:04 +02:00
Olivier Paroz 3bf155e138 This is not a PDF, there are no pages 2014-09-03 12:32:59 +02:00
Thomas Müller 6cdb1d89ae Merge pull request #10761 from canadaduane/fix_occ_upgrade
Ensure db connection before changing cache state
2014-09-03 11:27:16 +02:00
Thomas Müller 52dc31e13c Merge pull request #10725 from owncloud/sabredav-etag-master
adding OC-ETag header
2014-09-03 11:21:47 +02:00
Lukas Reschke 77c0adb520 Merge branch 'securityutils' of https://github.com/owncloud/core into securityutils 2014-09-03 11:04:49 +02:00
Lukas Reschke 50b430ee7c Add char consts, hash the specified password for the HMAC 2014-09-03 11:03:27 +02:00
Olivier Paroz 0c3c72aec0 Libreoffice config folder needs to be set
In order to avoid conflicts between multiple instances installed on one server, it's required to define a LibreOffice configuration folder per instance.

Just like with my PR for the documents app (https://github.com/owncloud/documents/pull/353), I propose to use /tmp/owncloud-instanceid
2014-09-03 03:12:35 +02:00
Olivier Paroz b559b21dc3 Converts TIFF files to PNG 2014-09-02 22:56:39 +02:00
Olivier Paroz 1e600a0d36 Adding support for tiff files 2014-09-02 22:53:41 +02:00
Vincent Petry e05b95636b Fix upgrade process when apps enabled for specific groups
Fix issue where the currently logged user was causing side-effects when
upgrading.
Now setting incognito mode (no user) on update to make sure the whole
apps list is taken into account with getEnabledApps() or isEnabled().
2014-09-02 17:16:14 +02:00
Robin Appelman a9a37b5363 Don't automatically setup the filesystem the moment we load OC\Files\FileSystem 2014-09-02 16:15:42 +02:00
cbhp 969b41c1c9 added missing User-Agents
header "User-Agent" was missed
2014-08-31 19:44:06 +02:00
Morris Jobke 4024960a0e Merge pull request #10780 from owncloud/config-public
Extend public config interface
2014-08-31 15:54:35 +02:00
Lukas Reschke 8009df0b60 Merge pull request #10420 from owncloud/external-share-self-signed
Make external shares work with imported self signed certificates
2014-08-31 15:50:30 +02:00
Robin Appelman 0a1e5aebf1 Extend public config interface 2014-08-31 15:27:36 +02:00
Lukas Reschke ae3425d2da Merge branch 'master' into securityutils
Conflicts:
	lib/private/util.php
2014-08-31 15:21:09 +02:00
Lukas Reschke a197ef0f6c Merge pull request #10768 from owncloud/l10n-use-public
Use public api for getting l10n
2014-08-31 11:58:59 +02:00
Robin Appelman bfa0c4b78a Explicitly set the timezones 2014-08-31 11:06:18 +02:00
Lukas Reschke 4efe6f6240 Add unit tests and fix rootcerts creation bug 2014-08-31 10:47:50 +02:00
Robin Appelman e64aa330fd check for blacklisted file certificate filenames 2014-08-31 10:47:50 +02:00
Robin Appelman 79d896e830 Rename namespace 2014-08-31 10:47:50 +02:00
Robin Appelman 6044ad0e17 Cleanup certificate code 2014-08-31 10:47:50 +02:00
Robin Appelman ba8416a04f move certificate classes to their own namespace 2014-08-31 10:47:50 +02:00
Robin Appelman c158db7200 Add certificate class 2014-08-31 10:47:50 +02:00
Robin Appelman c1b11571ea Move certificate management interface from files_external to core 2014-08-31 10:47:50 +02:00
Robin Appelman 4efdbff6df No need for this folder to be world accessible 2014-08-31 10:45:11 +02:00
Robin Appelman dcc4f96d3e Verify names of certificates 2014-08-31 10:45:11 +02:00
Robin Appelman ecdbf00628 Move certificate management code to core 2014-08-31 10:45:10 +02:00
Robin Appelman d0266c0bf8 Use public api for getting l10n 2014-08-31 10:08:22 +02:00
Morris Jobke 06e6f10ce4 Add optional user ID parameter for getUseFolder 2014-08-31 09:49:19 +02:00
Duane Johnson ccf440495e Ensure db connection before changing cache state
When trying to upgrade from 7.0.0 to 7.0.2, the manual upgrade path
(e.g. ` sudo -u www-data /usr/bin/php5 ./occ upgrade`) exits with the
following fatal error:

```
/var/www/owncloud# php occ upgrade
PHP Fatal error:  Call to a member function
  disableQueryStatementCaching() on a non-object in
  /var/www/owncloud/lib/private/db.php on line 423
```

This is caused by the self::$connection static variable having not
been initialized at the point of call. Adding a self::connect() fixes
the issue.

See https://forum.owncloud.org/viewtopic.php?f=29&t=23398&p=68556#p68556
2014-08-30 15:46:56 -06:00
cetra3 6b24aa5224 Refactor internal session to write directly to $_SESSION 2014-08-30 08:48:13 +00:00
Robin Appelman 0b88355368 Merge pull request #10721 from owncloud/kill-rand
Kill insecure random number generation
2014-08-29 19:48:00 +02:00
Morris Jobke 3a4b71ffb4 Merge pull request #10734 from owncloud/fix-10268
retrieve local users, groups and group members in a sorted way
2014-08-29 19:35:32 +02:00
Lukas Reschke 35276def1c Merge pull request #10614 from owncloud/remove-ee-hack
Remove different URL for EE
2014-08-29 18:23:15 +02:00
Jörn Friedrich Dreyer 10382ef2f0 allow empty hostname and dots in service name for oracle autosetup 2014-08-29 17:09:17 +02:00
Robin Appelman 3de69ff81b Don't register the call when rendering error pages 2014-08-29 15:44:39 +02:00
Robin Appelman dd7b8e4555 Remove insecure fallback random number generation 2014-08-29 15:44:09 +02:00
Arthur Schiwon 0bb460c9b5 retrieve local users, groups and group members in a sorted way 2014-08-29 15:17:37 +02:00
Thomas Müller 96a931929e adding OC-ETag header 2014-08-29 12:09:33 +02:00
Thomas Müller 647120fb36 adding new webdav property containing the folder size 2014-08-29 11:39:02 +02:00
Jörn Friedrich Dreyer f551917a3c kill OC::$session
maintain deprecated \OC::$session when getting or setting the session via the server container or UserSession

restore order os OC::$session and OC::$CLI

remove unneded initialization of dummy session

write back session when $useCustomSession is true

log warning when deprecated app is used
2014-08-29 10:22:21 +02:00
voxsim a49610e18a change logic in displayNamesInGroup and add some unit tests 2014-08-28 13:51:48 +02:00
Arthur Schiwon aeb9cfc6c9 make sure class file is loaded once 2014-08-28 12:34:29 +02:00
Lukas Reschke 9ab62ad5b7 Escape error messages 2014-08-27 17:01:51 +02:00
Clark Tomlinson cb0da1178b Merge pull request #10653 from owncloud/x-forwarded-for
Add support for getting the real client IP behind proxies
2014-08-27 10:32:34 -04:00
Pascal de Bruijn 49da0a7943 defaults: add customizable defaultiTunesAppId 2014-08-27 14:07:39 +02:00
Björn Schießle c35d60f6d8 Merge pull request #9915 from suraia/unsharefromself-source
Allow specifying the item source in unshareFromSelf().
2014-08-27 10:31:35 +02:00
Lukas Reschke 3329e0f2b2 Use DI 2014-08-27 00:49:53 +02:00
Lukas Reschke d26a9c3c58 Add some security utilities
This adds some security utilities to core including:
- A library for basic crypto operations (e.g. to encrypt passwords)
- A better library for cryptographic actions which allows you to specify the charset
- A library for secure string comparisions

Remove .htaccess

Remove .htaccess

Fix typo

Add public API

Use timing constant comparision

Remove CBC constant

Adjust code

Remove confusing $this
2014-08-27 00:18:04 +02:00
Lukas Reschke 7acdd018a1 Add support for getting the real client IP behind proxies
Fixes https://github.com/owncloud/core/issues/10624

Fix copy paste fail

Add unittest for comma separated headers

Revert 3rdparty
2014-08-27 00:05:04 +02:00
Thomas Müller 2e8026a7b5 Merge pull request #10619 from owncloud/issue/6722
Add a test to break the slugifyPath() with folder and file afterwards
2014-08-26 10:33:18 +02:00
Lukas Reschke ca7e4c8c67 Add isAppstoreEnabled instead of hijacking the URL 2014-08-26 10:20:51 +02:00
Clark Tomlinson 6523c575f3 Merge pull request #10623 from owncloud/not-a-valid-resource-log-entries
Do not try to close the same resource multiple times
2014-08-25 12:52:06 -04:00
Vincent Petry c86824fa09 Merge pull request #10023 from owncloud/tmp-file-created-status
Log unsuccessful temp file creation and return false
2014-08-25 17:24:46 +02:00
Joas Schilling 989da69cff Do not try to close the same resource multiple times 2014-08-25 15:31:43 +02:00
Joas Schilling 1846aebfff Use md5() of the original name instead of uniqid() for slugifying
Previously we used uniqid() here.
However this means that the behaviour is not reproducable, so
when uploading files into a "empty" folder, the folders name is
different.

If there would be a md5() hash collition, the deduplicate check
will spot this and append an index later, so this should not be
a problem.

Fix #6722
2014-08-25 15:06:12 +02:00
Joas Schilling b861e1d696 Fix code layout before fixing the function 2014-08-25 15:06:10 +02:00
Jörn Friedrich Dreyer ebf7758d10 Merge pull request #10595 from owncloud/swift-stream
Stream downloads from Swift object stores without downloading it first
2014-08-25 11:26:39 +02:00
Lukas Reschke 4bc72cc4e0 Remove different URL for EE
This can now be achieved by setting `appstoreenabled` to `false` in config.php
2014-08-24 20:22:15 +02:00
Clark Tomlinson 2ad0d3f1be Throw exception if file cannot be accessed via http
Format file

Removing calls to deprecated classes and using internal method to get via http

Missed a character

Fix inverted logic
2014-08-22 19:41:30 -04:00
Thomas Müller a77d468d35 Merge pull request #10584 from owncloud/simple-wizard-trusted-domains
Add a trusted domain wizard
2014-08-22 17:12:17 +02:00
Lukas Reschke 88c3a4a31a Expose setSystemValue 2014-08-22 15:53:23 +02:00
Thomas Müller 0e8916b147 Merge pull request #7539 from owncloud/repair-legacystorageid
Added repair script to upgrade the legacy home storage ids
2014-08-22 14:22:39 +02:00
Robin Appelman 191a82e768 Stream downloads from Swift object stores without downloading it first 2014-08-22 14:11:36 +02:00
Thomas Müller b8b2ef8748 no statement caching for Oracle 2014-08-22 12:06:36 +02:00
Robin Appelman 63570df75f Add files as string to tar archives 2014-08-21 08:49:57 +02:00
Robin Appelman 88c32861bc reformat 2014-08-21 08:49:57 +02:00
Vincent Petry 8f201c7383 Explicily close the statement cursors
Fixes the issue that makes SQLite freeze on later tests.
2014-08-20 23:49:15 +02:00
Lukas Reschke 92c80dd946 Merge pull request #10518 from owncloud/fix_storage_const_autoload
Fix storage const autoload
2014-08-20 23:23:42 +02:00
Vincent Petry 068f9d10f1 Added repair step for legacy storages 2014-08-20 23:14:05 +02:00
Vincent Petry 36c88e2830 Merge pull request #10422 from owncloud/dav-disablerangerequestwhennotsupported
Return whole file if range request cannot be granted due to encryption
2014-08-20 18:14:09 +02:00
Morris Jobke 9a5e745a64 fix typo 2014-08-19 16:45:22 +02:00
Morris Jobke b3b3354809 move to public namespace 2014-08-19 14:05:08 +02:00
Stephan Peijnik 5d7deefd95 Use tabs for indentation.
Signed-off-by: Stephan Peijnik <speijnik@anexia-it.com>
2014-08-19 13:55:43 +02:00
Stephan Peijnik 2df52e54d7 Fix STORAGE_* constants usage by moving those constants into \OC\Files\Filesystem.
As constants not defined within a class cannot be automatically found by the
autoloader moving those constants into a class makes them accessible to
code which uses them.

Signed-off-by: Stephan Peijnik <speijnik@anexia-it.com>
2014-08-19 13:55:35 +02:00
Robin Appelman fdfc5c67f8 Merge pull request #9866 from owncloud/app-upgrade
Don't do app upgrades in the background
2014-08-19 13:33:38 +02:00
Thomas Müller 1c23f54d42 Merge pull request #10341 from owncloud/issue/9928
[Issue/9928] Problems with filemtime in MappedLocal Storage
2014-08-19 10:10:09 +02:00
Vincent Petry ec274ad40b Use afterBind to send fileId header for files and directories
afterBind is called for both files and directories and is now used to
send the OC-FileId headers.
2014-08-18 18:40:58 +02:00
helix84 722a119e46 fix typo in util.php 2014-08-18 15:59:36 +02:00
Robin Appelman ab590ce9a0 fix undefined variable 2014-08-18 15:30:46 +02:00
Thomas Müller 62e06cb0ba Merge pull request #10472 from owncloud/fix_undefined_index_ocsid
check if array index ocsid is set before accessing it
2014-08-18 10:43:21 +02:00
Thomas Müller c933848c55 Merge pull request #10156 from owncloud/issue/9968
Check return of fopen() before using it
2014-08-18 10:35:04 +02:00
Frank Karlitschek ddeb301ad6 Merge pull request #10456 from kroimon/skeleton_dir_config
Make skeleton directory configurable.
2014-08-17 20:01:02 -04:00
Georg Ehrke 7347174636 check if array index ocsid is set before accessing it 2014-08-17 22:26:14 +02:00
Lukas Reschke a2677c14c8 Remove X-Mailer header from mails 2014-08-17 18:55:13 +02:00
Stefan Rado ccc46be740 Make skeleton directory configurable. 2014-08-16 01:07:42 +02:00
Lukas Reschke a822a31ce3 Merge pull request #10442 from owncloud/move-failed-logins
Move authentication failed logging to checkPassword
2014-08-15 16:50:28 +02:00
Lukas Reschke 98fc56831d Merge pull request #9275 from NormalRa/master
Add .apk mimetype.
2014-08-15 14:41:53 +02:00
Lukas Reschke a82cd1ff67 Fix unit test 2014-08-15 14:15:27 +02:00
Lukas Reschke 5bb4772858 Move authentication failed logging to checkPassword
Fixes https://github.com/owncloud/core/issues/10366
2014-08-15 12:13:00 +02:00
Jörn Friedrich Dreyer 799fb46927 add missing @deprecated annotation to legacy classes 2014-08-14 22:18:12 +02:00
Thomas Müller c1102b1671 Merge pull request #10417 from owncloud/update_deprecation_doc
update deprecation docs
2014-08-14 17:54:23 +02:00
Björn Schießle 64c3fe670c Merge pull request #10399 from owncloud/fix_setSendMailStatus
[sharing] fix mail notification
2014-08-14 17:45:39 +02:00
Joas Schilling 4d32e3548b Ensure that filename is prefixed with a slash 2014-08-14 16:48:30 +02:00
Clark Tomlinson 4502eaf9f8 Merge pull request #10414 from owncloud/relax-code-checker
in order to prevent false-positives on the code checker - exec and eval ...
2014-08-14 09:35:20 -04:00
Vincent Petry cc8c1d8e07 Return whole file if range request cannot be granted due to encryption
Whenenver range headers are set and encryption is enabled, it is not
possible to automatically fseek() to the proper position.

To avoid returning corrupt/invalid data or causing a decryption error,
the range headers are stripped so that the SabreDAV code in httpGet()
returns the whole file.
2014-08-14 15:18:49 +02:00
Jörn Friedrich Dreyer fd798fd982 update deprecation docs 2014-08-14 12:22:34 +02:00
Morris Jobke 987a0565fb Merge pull request #10395 from owncloud/close-filehandle-lib-files
Close open file handles in files library
2014-08-14 10:57:54 +02:00
Thomas Müller a4932dc5e2 in order to prevent false-positives on the code checker - exec and eval will not longer be grepped for 2014-08-14 10:48:42 +02:00
Thomas Müller 6d94fc846d Merge pull request #10394 from owncloud/close-filehandle-lib-image
Close file handle if exception occurs in image class
2014-08-13 22:41:33 +02:00
Robin Appelman bba59bf815 Cast file id's to int so we can compare them properly 2014-08-13 19:18:34 +02:00
Bjoern Schiessle d9f35d8c15 we need the recipient as a additional parameter to know for which share the notification was send 2014-08-13 17:02:51 +02:00
Morris Jobke c6bf51c457 Close open file handles in files library
ref #10392
2014-08-13 15:48:32 +02:00
Morris Jobke f61658945f Close file handle if exception occurs in image class
ref #10392
2014-08-13 15:19:58 +02:00
Robin Appelman 174805f5e3 Merge pull request #9762 from owncloud/owner-public
Return the proper owner for home storages
2014-08-12 14:29:17 +02:00
Normal Ra 1633ec5c87 APK mimetype icon to be a generic package icon. 2014-08-12 14:10:49 +02:00
Clark Tomlinson e63853a353 Merge pull request #10335 from owncloud/fix-emptyapplist
Fix issue when no apps are enabled
2014-08-11 16:16:18 -04:00
Thomas Müller 3e493501da Merge pull request #9890 from owncloud/check-php-charset-master
setting and checking default_charset in php.ini to be UTF-8
2014-08-11 22:11:11 +02:00
Vincent Petry a32eac1477 Fix issue when no apps are enabled
Properly initialize $apps array
2014-08-11 20:36:51 +02:00
Joas Schilling 564bf23c1b Do not filemtime() on "." directory. Use empty string instead
Fix #9928
2014-08-11 17:39:37 +02:00
Joas Schilling d7666d9d3d Remove doubled slash between folder and path 2014-08-11 16:50:52 +02:00
Thomas Müller 13d44f8f7f Merge pull request #10251 from owncloud/fix-dav-attributes-master
shared files/folders are not mounted
2014-08-11 14:40:47 +02:00
Vincent Petry 79fa2bc391 Merge pull request #10301 from owncloud/fix-internal-mail-share-links
Don't use /Shared as a base for links in share email
2014-08-11 13:33:39 +02:00
Vincent Petry f2001a48a4 Fixed sort algo for additional cases 2014-08-11 13:28:53 +02:00
Vincent Petry 173059f6d0 Fixed file list sorting
Now using a natural sort algorithm that is more consistent between JS
and PHP (although not perfect in some corner cases)

- added OC.Util.naturalSortComparator that uses the same algo that was
  used for the user list
- changed user list and files list to use OC.Util.naturalSortComparator
- removed toLowerCase() and changed the comparator to use
  String.localeCompare()
- added unit tests
- added OC_NaturalSort that is used by OCP\Util::naturalSortCompare()
2014-08-11 13:28:53 +02:00
Thomas Müller b83d00f847 Merge pull request #10249 from mroi/patch-1
file size on non-(Linux/BSD/Windows)-installations
2014-08-11 13:02:01 +02:00
Tom Needham aeef10eb47 Add scrollto to the url if sharing a file for long file lists 2014-08-09 00:21:29 +01:00
Tom Needham 16dafa9cac Fix link to files and folders in internal share emails 2014-08-09 00:08:45 +01:00
Bjoern Schiessle 6dda30b5a2 remove share permissions if user is excluded from sharing 2014-08-08 12:16:54 +02:00
Morris Jobke b6a2a85bb8 Merge pull request #9953 from owncloud/fix_text_preview_for_systems_without_ttf
implement a txt preview fallback for the case that ttf is not support
2014-08-07 22:55:06 +02:00
Thomas Müller 520f6422ac Merge pull request #10079 from owncloud/Improve_scanner_message
Improved scanner error message
2014-08-07 16:09:52 +02:00
Thomas Müller 9d2cff50ed shared files/folders are not mounted 2014-08-07 16:01:13 +02:00
Michael Roitzsch cde1a9241d file size on non-(Linux/BSD/Windows)-installations
Determining the file size using the exec() method is implemented for Linux, BSD, and Windows. However, on systems matching neither platform name (like SunOS), the fall-through path will return a file size result constituting a zero size instead of an invalid null return value.
2014-08-07 15:41:58 +02:00
Thomas Müller e33fc2807c Merge pull request #10142 from owncloud/fix-#9283-gzip_support
Removed broken tar cutter, added tar and fixed extension switch.
2014-08-07 14:53:31 +02:00
Robin Appelman f1091280de Merge pull request #10184 from owncloud/getbyid-node
Fix Folder::getById
2014-08-07 13:40:17 +02:00
Thomas Müller d2365afad6 Merge pull request #8915 from owncloud/MorrisJobke-travis
Travis support for PRs and master, stable5 and stable6
2014-08-07 11:33:13 +02:00
Volkan Gezer 173538befb typo fix from transifex suggestion 2014-08-06 20:48:26 +02:00
Robin Appelman 12207ec0c7 Fix SharedCache::getPathById 2014-08-06 13:38:14 +02:00
Robin Appelman 1deb6aadd3 return null instead of throwing an exception 2014-08-06 12:06:41 +02:00
Thomas Müller a72dae6842 Merge pull request #10144 from owncloud/issue/9972
Issue/9972 Fix issues with group and username `0`
2014-08-06 09:53:13 +02:00
Morris Jobke 9fb79c86f0 Merge pull request #10191 from owncloud/sharing_rm_trailing_slash
[sharing] remove trailing slash
2014-08-05 23:13:35 +02:00
Bjoern Schiessle 48c57b80e3 remove trailing slash from path 2014-08-05 20:34:32 +02:00
Björn Schießle d35bfc9a4c Merge pull request #9520 from owncloud/theme_urls
Add ability to theme iOS and Android client URLs just like desktop URLs.
2014-08-05 17:53:18 +02:00
Robin Appelman bf8f910a32 Fix Folder::getById 2014-08-05 16:58:10 +02:00
Morris Jobke 676fa459d7 Minor fixes
* instanceof \OC\Files\View
* fix misplaced paranthesis
* remove misplaced character in comment
2014-08-05 16:53:28 +02:00
Robin Appelman 244d4e1399 Make View->shouldEmitHooks more robust 2014-08-05 16:53:28 +02:00
Morris Jobke 8561d0dfca remove escaping because it's unneeded 2014-08-05 13:18:38 +02:00
Morris Jobke 7b222c4ab5 fix uppercase issue 2014-08-05 13:16:51 +02:00
scolebrook 2e127d2c5e Add ability to theme iOS and Android client URLs just like desktop URLs. 2014-08-05 13:16:51 +02:00
Bjoern Schiessle 41cca70a63 don't display share permission if resharing was disabled by the admin 2014-08-05 10:57:51 +02:00
Morris Jobke c0e78d9841 Merge pull request #10151 from owncloud/issue/9912
Increase word wrap limit for emails to 78 characters
2014-08-05 08:20:57 +02:00
Joas Schilling 303f6da76f Check return of fopen() before using it
Fix #9968
2014-08-04 17:53:06 +02:00
Joas Schilling f4c7e3c1e9 Merge pull request #10083 from th3fallen/fix-9969-take-two
Fix 9969
2014-08-04 17:41:03 +02:00
Joas Schilling c1b8d93cb0 Increase word wrap limit for emails to 78 characters 2014-08-04 16:05:09 +02:00
Joas Schilling 4865c52aa6 Fix isLoggedIn() check for user '0'
Fix #9972
2014-08-04 15:53:55 +02:00
Joas Schilling f80baf03d4 Fix getting group '0' from database backend
Fix #9972
2014-08-04 15:53:55 +02:00
Remco Brenninkmeijer cb842ba793 Previous commit was not based on master, retry. Removed broken tar cutter, double extensions are not possible in temp files. Added tar support. Fixed extension switch. 2014-08-04 14:10:09 +02:00
Robin Appelman 8b4d3c065c only set core version at the end 2014-08-04 13:42:16 +02:00
Robin Appelman ae263da69a Also set the app version when updating from app store 2014-08-04 13:41:05 +02:00
Robin Appelman 776cc45a5a Allow loading app without checking the upgrade 2014-08-04 13:41:05 +02:00
Robin Appelman 4602d1f2a6 extract upgrade parts to their own methods 2014-08-04 13:41:05 +02:00
Robin Appelman 4608f8a3b5 Throw an exception when we try to load an app that needs to be upgraded 2014-08-04 13:41:04 +02:00
Robin Appelman 43d790239d Extend OC_Util::needUpgrade to also catch app upgrades 2014-08-04 13:41:04 +02:00
Thomas Müller 65903a012a Merge pull request #10025 from owncloud/l10n-typo
typo fix from transifex suggestion
2014-08-04 11:03:50 +02:00
Volkan Gezer 7a07690b25 expire -> expiration 2014-08-02 04:02:39 +02:00
Jörn Friedrich Dreyer a0ab4c2434 fix return documentation 2014-08-01 13:42:35 +02:00
Thomas Müller 378f35f0ec prevent PHP errors and enhance logging 2014-08-01 09:54:32 +02:00
Volkan Gezer 5f015067f4 suggestions by deepdiver 2014-08-01 01:39:52 +02:00
Clark Tomlinson 26af116fcd Removing unnecessary switch statements in fopen methods. 2014-07-31 09:34:27 -04:00
Martin d975012ae6 Improved scanner error message 2014-07-31 13:12:35 +02:00
Thomas Müller 4eb2b4e1b0 Merge pull request #10051 from owncloud/preview-empty-text
Use svg mimeicons for empty text files
2014-07-31 11:38:29 +02:00
Jan-Christoph Borchardt 5b11a18dea Merge pull request #10044 from owncloud/transparency_fix
extract transparency fix from #8050
2014-07-30 18:36:51 +02:00
Morris Jobke 62b37fbb99 Merge pull request #10024 from owncloud/preview-restrict-height
Also keep maxY into account when scaling a preview while preserving aspect ratio
2014-07-30 17:22:20 +02:00
Jörn Friedrich Dreyer dd9347fdd2 Merge pull request #10000 from owncloud/fix-lowlat-cache-autoload
Cache factory needs to use globalPrefix in createLowLatency()
2014-07-30 16:56:45 +02:00
Robin Appelman 4a9b0d5465 Use svg mimeicons for empty text files 2014-07-30 16:31:37 +02:00
Georg Ehrke fa461befbc extract transparency fix from #8050 2014-07-30 16:13:33 +02:00
Morris Jobke 38e309b0fe Merge pull request #9970 from owncloud/sharing_set_expire_date
Sharing set expire date
2014-07-30 14:37:16 +02:00
Volkan Gezer 90d8f42d7c typo fix from transifex suggestion 2014-07-30 14:07:32 +02:00
Robin Appelman c066320208 Also keep maxY into account when scaling a preview while preserving aspect ratio 2014-07-30 13:52:40 +02:00
Victor Dubiniuk 0113ad0b33 Log unsuccessful temp file creation and return false 2014-07-30 13:50:41 +02:00
Thomas Müller 54d5d03271 Merge pull request #9888 from owncloud/mysql-tinyint-master
migration test for sqlite - adding type mapping for 'tinyint unsigned'
2014-07-30 11:48:10 +02:00
Andreas Fischer 9be8ac5867 Memcache\Factory: Remove static, use globalPrefix. 2014-07-29 11:14:36 +02:00
Bjoern Schiessle 67e302885c remove share permission if user is excluded from sharing 2014-07-29 10:08:08 +02:00
Thomas Müller 58472a2660 migration test for sqlite - adding type mapping for 'tinyint unsigned' 2014-07-29 09:18:37 +02:00
Bjoern Schiessle 4e87ac2bb9 make sure that we set the expire date if a date is adefault date is set 2014-07-28 22:45:03 +02:00
Björn Schießle c53b56e313 Merge pull request #9798 from owncloud/ocs_share_api_add_expire_date
[share api] add OCS api call to set expire date for link shares
2014-07-28 17:28:32 +02:00
Morris Jobke 1fbbaed261 Merge pull request #9949 from owncloud/fixing-sqlite-migration-shared-hoster
generate copy of sqlite database file in data directory
2014-07-28 16:54:52 +02:00
Robin Appelman cb0ff19dc4 Merge pull request #9924 from owncloud/eventsource-nginx-buffering
Prevent nginx from buffering event source events
2014-07-28 16:17:35 +02:00
Georg Ehrke 4e8e69dc81 implement a txt preview fallback for the case that ttf is not support 2014-07-28 13:05:08 +02:00
Thomas Müller 539d2b7ec3 Merge pull request #9784 from josh4trunks/libreoffice_match_cl
Cleanup Document Preview
2014-07-28 13:03:33 +02:00
Thomas Müller a3411e3719 Merge pull request #9641 from owncloud/localuser-addressbook
ownCloud users are exported as address book
2014-07-28 12:18:56 +02:00
Thomas Müller 534fb9ebf9 Merge pull request #9631 from owncloud/update-getid3
update getID3 library
2014-07-28 11:51:36 +02:00
Thomas Müller 11214219f3 Merge pull request #9819 from owncloud/updater-setversionafterupdate
Set version AFTER a successful update
2014-07-28 11:19:57 +02:00
Thomas Müller 0aa652ecfd Merge pull request #9859 from tiezdne/master
Update mimetypes.list.php
2014-07-28 11:16:43 +02:00
Thomas Müller cfaa05cc0e Merge pull request #9905 from owncloud/joblist-non-existing-class
Dont try to execute jobs that no longer exist
2014-07-28 11:09:27 +02:00
Thomas Müller ab8efe3aa2 Merge pull request #9935 from owncloud/harden-get-urlco
Verify whether the URL is valid
2014-07-28 11:07:41 +02:00
Thomas Müller c87f425fe7 generate copy of sqlite database file in data directory 2014-07-28 10:29:39 +02:00
Thomas Müller f2982b7a08 Merge pull request #9904 from owncloud/loggedout-getuserfolder
Dont throw an error when calling $server->getUserFolder when logged out
2014-07-28 10:04:01 +02:00
Lukas Reschke 260729fd7d Verify whether the URL is valid
Required for https://github.com/owncloud/mail/pull/100#issuecomment-50266017

@karlitschek Backport for stable6 and stable7 requested.
2014-07-27 16:46:32 +02:00
Robin Appelman 2c4e06d325 Prevent nginx from buffering event source events 2014-07-26 16:07:11 +02:00
Michael Kuhn ecdd04374a Allow specifying the item source in unshareFromSelf(). 2014-07-26 02:00:49 +02:00
Robin Appelman 43978befda Dont try to execute jobs that no longer exist 2014-07-25 18:02:02 +02:00
Robin Appelman acafb4a426 Merge pull request #9669 from owncloud/group-public
Add group management to the public api
2014-07-25 17:55:12 +02:00
Robin Appelman bf12bba079 Dont throw an error when calling $server->getUserFolder when logged out 2014-07-25 17:52:50 +02:00
Morris Jobke ae3761f15d add autoload 2014-07-25 17:37:33 +02:00
Morris Jobke a9666c4f5b update getID3 library 2014-07-25 15:25:45 +02:00
Bjoern Schiessle ecc1f92bb6 add OCS api call to set expire date for link shares 2014-07-25 13:38:18 +02:00
Thomas Müller 07dc0b2fdf setting and checking default_charset in php.ini to be UTF-8 2014-07-25 09:53:25 +02:00
Thomas Müller 176ecbd311 ownCloud users are exported as address book 2014-07-24 17:35:02 +02:00
Thomas Müller 788a2eca2f Merge pull request #9841 from owncloud/fix-password-reset-master
Fix password reset in console command and lost password controller
2014-07-24 15:58:02 +02:00
tiezdne 6a2f3921f6 Update mimetypes.list.php 2014-07-24 15:43:55 +02:00
Thomas Müller a8b6cc6a07 - adding default value for $recoveryPassword
- set password correctly in lost password
2014-07-24 12:50:39 +02:00
Thomas Müller 7d60f7a222 register type mappings for unknown/unsupported mysql types 2014-07-24 12:17:26 +02:00
Vincent Petry 6f329dcb6c Set version AFTER a successful update
If an app upgrade failed, the core version will not be increased either
in the database. This will re-display the update page and make it
possible to redo the apps upgrade.

Note that any core repair routine must take into account that an update
might need to be redone again even though the core's DB state is already
the one of the new version.
2014-07-23 23:38:17 +02:00
Thomas Müller 363ba04f5e only commit in case a transaction is active 2014-07-23 20:13:19 +02:00
josh4trunks acd5660492 Cleanup Document Preview
Use the env:UserInstallation flag like https://github.com/owncloud/documents/blob/master/lib/converter.php.
This will stop the creating of multiple directories for document conversion in tmpDir.
2014-07-22 22:46:38 -07:00
Sander 4e2954673a Revert change 2014-07-22 19:45:01 +02:00
Sander eacdf26cde Allow getAppFolder to get another apps path
cc @Raydiation
2014-07-22 16:07:43 +02:00
Thomas Müller 31149fb1c3 adding special handling of checkPrecondition() for chunked upload 2014-07-22 13:06:20 +02:00
Robin Appelman e9de20952a Return the proper owner for home storages 2014-07-21 16:59:59 +02:00
Thomas Müller 0a9e0d1051 perm -> permissions 2014-07-21 13:49:22 +02:00
Vincent Petry 3df7a83c72 Merge pull request #9406 from philfry/master
silently discard the response body, needed for apache/mod_dav and maybe ...
2014-07-21 12:22:06 +02:00
Andreas Fischer 8cd1f7464e Merge pull request #9672 from owncloud/mysql-affectedrows
Make MySQL affected row count consistent with other DBMSes

* owncloud/mysql-affectedrows:
  Added test of OCS privatedata to trigger key duplication
  Document why we have to check with defined() first.
  Make MySQL return "number of found rows" instead of number of "affected rows".
2014-07-20 21:29:16 +02:00
Frank Karlitschek f92b5a2507 update appstore api url 2014-07-17 21:54:46 -04:00
Robin Appelman 5a0397eb5e Fix renaming files in the root folder of a MappedLocal storage 2014-07-16 21:24:18 +02:00
icewind1991 d58c8d72cf Merge pull request #9550 from kofemann/dcache-fixes-for-upstream
storage: do not check file mode on rename
2014-07-16 16:06:14 +02:00
Andreas Fischer d8bd8c4b66 Document why we have to check with defined() first. 2014-07-16 15:13:35 +02:00
Andreas Fischer e26612244a Make MySQL return "number of found rows" instead of number of "affected rows". 2014-07-16 14:35:47 +02:00
Robin Appelman 94fa21d146 Add group management to the public api 2014-07-16 14:25:31 +02:00
Stephan Peijnik 4d74aa09bf Port of #9584
Fixes #9583

lib/private/group/metadata.php: For subadmins also return an array of groups, indexed by their GIDs.
settings/users.php: Convert array of arrays to array of GIDs before calling into OC_Group::displayNamesInGroups.

Signed-off-by: Stephan Peijnik <speijnik@anexia-it.com>

Fix indentation.

Signed-off-by: Stephan Peijnik <speijnik@anexia-it.com>

Renamed $grp to $group in foreach loop.

Signed-off-by: Stephan Peijnik <speijnik@anexia-it.com>

Use is_null() instead of empty() when checking the return value of GroupManager::get().

Additionally, $grp was renamed to $group inside
 \OC\Group\MetaData::fetchGroups().

Signed-off-by: Stephan Peijnik <speijnik@anexia-it.com>

Updated code to reflect changes introduced to \OC\Group\MetaData.

Now that fetchGroups() does not exist anymore and getGroups() is called
directory, the 'groups' property does not exist anymore.
Instead, we now generate that array on the fly and return it from getGroups.

Signed-off-by: Stephan Peijnik <speijnik@anexia-it.com>
2014-07-16 12:23:26 +02:00
Björn Schießle 7d8a8e78fa Merge pull request #9640 from owncloud/fix_9627
make sure that 'OC_Theme' exists before checking if the method exists
2014-07-16 10:12:52 +02:00
Thomas Müller 0f9b22107b Merge pull request #9644 from owncloud/fix_user_api
Fix user api
2014-07-15 23:57:02 +02:00
blizzz 10b59f101f Merge pull request #9540 from owncloud/use_fileinfo_in_search_results
use fileinfo object in search results
2014-07-15 19:49:36 +02:00
Bjoern Schiessle 6967d328e2 make sure that 'OC_Theme' exists before checking if the method exists 2014-07-15 17:48:25 +02:00
Jörn Friedrich Dreyer 818929274d use UserSession service to resolve user id 2014-07-15 17:42:17 +02:00
Vincent Petry a8d95356ca Merge pull request #8987 from owncloud/lastindexid-debug
[DEBUG] Test case for debugging the last index ID bug from Doctrine/MySQL
2014-07-15 17:01:57 +02:00
icewind1991 61b5a770e4 Merge pull request #9561 from libasys/patch-3
Fix Error undefined index: file_target
2014-07-15 16:54:57 +02:00
Thomas Müller 6c93bcc814 Merge pull request #9621 from owncloud/fix_logger_implementation
fix logger implementation
2014-07-15 16:05:15 +02:00
Jörn Friedrich Dreyer 4a855be814 fix logger implementation and test 2014-07-15 10:10:16 +02:00
Thomas Müller e8f02b9410 Merge pull request #9562 from owncloud/users-groupfilter
Do not filter groups, but therefore update the user counts according to  the filter
2014-07-15 07:40:55 +02:00
Thomas Müller 73e2bf7bf4 fixing PHPDoc 2014-07-14 21:26:47 +02:00
Arthur Schiwon ab2c7e06a4 remove dead code
do not filter groups. but update the user count according to the filter

improve phpdoc

improve metadata runtime cache

add metadata tests
2014-07-14 21:26:37 +02:00
Jörn Friedrich Dreyer 8f11019f45 mkae getRelativePath of file search results overwriteable in subclasses 2014-07-14 19:27:10 +02:00
Jörn Friedrich Dreyer eea5c2ee0a return relative path 2014-07-14 19:12:06 +02:00
Robin Appelman c3991ae13e Use the correct path when building the FileInfo for the search result 2014-07-14 18:32:45 +02:00
Morris Jobke 9ee1c7ff71 Merge pull request #9228 from owncloud/remove-routing-singular-issues
Routing: Dont strip the s from the resource id to prevent possible weird behavior with irregular english plural nouns
2014-07-14 17:10:07 +02:00
Thomas Müller 4b91741875 Merge pull request #9598 from owncloud/fix-app-installation-master
append file extension to the temporary file which contains the downloade...
2014-07-14 17:05:36 +02:00
Vincent Petry 10a29556b0 - Added test to trigger index id error
- re-enable encryption migration tests
- sqlite requires reconnect after schema changes
2014-07-14 16:20:09 +02:00
Robin Appelman 20c1ce7f47 Add public interfaces for User, UserManager and UserSession 2014-07-14 15:10:51 +02:00
Björn Schießle 05ba9b3c64 Merge pull request #9539 from enoch85/patch-1
Fix for #9422
2014-07-14 12:58:23 +02:00
Vincent Petry e58dce2ee0 Merge pull request #9571 from owncloud/fix_appstore_update_issue
Fix update to button issue
2014-07-14 10:00:39 +02:00
Thomas Müller e47cd5ebf1 append file extension to the temporary file which contains the downloaded archive - in case of zip files fileinfo doesn't seem to return anything reliable 2014-07-11 16:51:59 +02:00
Georg Ehrke fb685b0856 improve check for duplicate apps 2014-07-10 17:18:10 +02:00
Georg Ehrke 305db9c2d7 add proper version comparision in OC_Installer::isUpdateAvailable 2014-07-10 17:17:55 +02:00
Morris Jobke e33ef0d449 Merge pull request #9536 from owncloud/default-app-groups-master
Default app groups master
2014-07-10 15:45:44 +02:00
Tigran Mkrtchyan 03f422153d files: storage: rename should check parent directories of old and new files
as described by POSIX.1-2008
(see http://pubs.opengroup.org/onlinepubs/9699919799/functions/rename.html)

Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
2014-07-10 14:58:59 +02:00
libasys cd88c2fd7b Update share.php
change isset with empty on line 1911
2014-07-10 13:19:35 +02:00
libasys b395ff549b Update share.php
Added isset for error:
```
Undefined index: file_target at /var/www/owncloud/lib/private/share/share.php#1911
```
2014-07-10 13:02:04 +02:00
Georg Ehrke 380aacdf93 fix orientation in image-backend, not in preview system itself 2014-07-09 23:07:58 +02:00
Jörn Friedrich Dreyer 3f093974f9 use fileinfo object in search results 2014-07-09 14:47:43 +02:00
Daniel Hansson 851c1f87d6 Fix for #9422 2014-07-09 14:40:05 +02:00
Thomas Müller 5d2a3c83ac adding 'groups' entry to remote apps 2014-07-09 11:23:17 +02:00
Thomas Müller 1ae6e1bcf8 fixing typos 2014-07-09 10:20:17 +02:00
Thomas Müller 63fdaacbfc Merge pull request #9510 from libasys/patch-1
BugFix missing $item on 'file_target' Line 1911
2014-07-09 07:58:37 +02:00
Thomas Müller 10978a80c2 Merge pull request #9507 from owncloud/fix-9302-master
Upload abortion is now detected within the  OC_Connector_Sabre_File::put...
2014-07-08 17:39:34 +02:00
Thomas Müller 65d9d6ad01 Merge pull request #9412 from owncloud/public-api-activity
Public api activity
2014-07-08 16:37:18 +02:00
Arthur Schiwon 3338a0f236 port of #9500
don't trigger update from checkPassword, it is already  called by userExists, this is enough.

do not write to database when the value is the same

add test cases. also split test classes in a file each, looks like only the first class is being executed

also appconfig shall not write to database if the value is unchanged
2014-07-08 16:32:01 +02:00
Robin Appelman 3e3d460729 use case insensitive LIKE when searching for files in mysql 2014-07-08 15:49:27 +02:00
Robin Appelman 76c709d7de Add repair step to set MySQL collation to utf8_bin
Set default collation of mysql connection to utf8_bin
Set utf_bin as default collation for new tables
2014-07-08 15:12:07 +02:00
Thomas Müller ea269f0067 Upload abortion is now detected within the OC_Connector_Sabre_File::put()
OC_Connector_Sabre_AbortedUploadDetectionPlugin is pointless

Adding unit test testUploadAbort()
2014-07-08 11:09:59 +02:00
libasys e70a7af6da BugFix missing $item on 'file_target' Line 1911
I think this should be right!
2014-07-08 10:51:05 +02:00
Thomas Müller 8363f3c635 Adding new interface \OCP\Activity\IExtentsion
Adding method getNotificationTypes()
Adding method filterNotificationTypes()
Adding method getDefaultTypes()
Adding method translate() and getTypeIcon()
Adding method getGroupParameter()
Adding method getNavigation()
Adding method getNavigation()
Adding method isFilterValid() and getQueryForFilter()
Adding unit tests for \OC\ActivityManager
2014-07-08 09:04:37 +02:00
Morris Jobke 29bdfc0ce2 Merge pull request #9502 from owncloud/add_ocsids
Add ocsids for shipped apps in core repo
2014-07-07 19:58:41 +02:00
Morris Jobke b2377129b6 Merge pull request #9494 from owncloud/issue/9490
[issues/9490] \OC::$WEBROOT is invalid when called from cron.php
2014-07-07 19:36:41 +02:00
Georg Ehrke e5e8e28ae7 add ocsids to info.xml 2014-07-07 17:11:50 +02:00
Joas Schilling e8537afd60 Only overwrite serverHost when in unit tests
The intention of the original commit 12f7cb8767
was to fix tests. But cron should always return a valid host not localhost.
2014-07-07 15:08:45 +02:00
Thomas Müller b091b15f0b MySQL: adding repair step to convert MyIsam tables to InnoDB 2014-07-07 12:32:24 +02:00
Vincent Petry 5c444c2da8 Merge pull request #9468 from owncloud/fix_logout_error_messages
better validation: cadd extra check if appinfo/info.xml exists
2014-07-07 10:58:23 +02:00
Georg Ehrke 1565089c02 fix phpDocBlock for OC_App::getAppInfo 2014-07-05 13:32:21 +02:00
Georg Ehrke 042ec984bd better validation: cadd extra check if appinfo/info.xml exists 2014-07-05 13:28:47 +02:00
Jörn Friedrich Dreyer 8fbcca1291 Merge pull request #9419 from owncloud/fix_search_results_in_root_dir
Fix search results in root dir & deprecate OC_Search_Provider
2014-07-04 18:28:54 +02:00
Björn Schießle a544bd3a0f Merge pull request #9357 from owncloud/sharing_unshare_on_delete
[sharing] unshare childrens on delete
2014-07-04 17:42:52 +02:00
icewind1991 d3fab824f7 Merge pull request #9445 from owncloud/filelist-auth-error
Reload the page when the files app encounters an authentication error
2014-07-04 16:39:00 +02:00
Robin Appelman 4fe1cdd2a7 Add machine readable error messages to OC\JSON
Reload the files app in case of authentication errors, expired tokens or disabled app

Reloading will triger the full server side handeling of those errors

formatting

fix missing semicolon + some jshint warnings
2014-07-04 16:20:27 +02:00
Jörn Friedrich Dreyer aeeae5f1b2 Merge pull request #8308 from owncloud/case_insensitive_search_oracle
use case insensitive linguistic sort and compare when connecting to oracle
2014-07-04 15:51:57 +02:00
Thomas Müller 2327d41b11 Merge pull request #9269 from owncloud/fix_versions_preview
change order of registering api and capabilities to fix file version previews
2014-07-04 15:25:24 +02:00
Bjoern Schiessle e9f5730869 make sure that the umount hook always contains the path relative to data/user/files 2014-07-04 10:34:54 +02:00
Jörn Friedrich Dreyer b5545b81c6 make search case insensitive on postgres and oracle 2014-07-03 19:01:00 +02:00
Jörn Friedrich Dreyer b56f5f2773 deprecate OC_Search_Provider in favor of \OCP\Search\Provider 2014-07-03 16:03:09 +02:00
Vincent Petry 2fec6cbd5b Remove forgotten debug log 2014-07-03 12:26:17 +02:00
Philippe Kueck ef114b6594 silently discard the response body, needed for apache/mod_dav and maybe other dav servers which return an html body 2014-07-03 12:04:38 +02:00
Vincent Petry ed29e7d160 Merge pull request #9329 from owncloud/sharing_check_target
don't move a share mount point into a different mount point
2014-07-02 21:01:03 +02:00
Vincent Petry f4eb90e229 Merge pull request #9311 from owncloud/storage-not-available
Handle storages not being available in webui and webdav
2014-07-02 18:15:58 +02:00
Morris Jobke 904e3102d3 Merge pull request #9288 from owncloud/fix_dispatcher_null_values
don't typecast null values inside dispatcher.php
2014-07-02 15:29:33 +02:00
Robin Appelman c4fa07d7cf Also update sqliteadapter 2014-07-02 15:27:27 +02:00
Robin Appelman edb67f9f4d Remove invalid mounts from the active fs 2014-07-02 15:00:12 +02:00
Volkan Gezer 805a7cf485 Merge pull request #9338 from owncloud/fix-redirect-for-appframework
Redirect after session expiry to the previous loaded page
2014-07-02 11:39:41 +02:00
Vincent Petry 94c3bac9ed Merge pull request #9327 from owncloud/migrator-postgreskeywordtest
Added migrator test for reserved keyword
2014-07-01 20:40:18 +02:00
Vincent Petry 3d921ed3c3 Merge pull request #9334 from owncloud/defaultappfix
Default app fix
2014-07-01 20:39:13 +02:00
Bjoern Schiessle bb935978fa don't move a share mount point into a different mount point 2014-07-01 19:38:55 +02:00
Jonny007-MKD 4161fd2408 Update adapter.php
Modified insertIfNotExist() to support NULL values
2014-07-01 17:47:27 +02:00
Bjoern Schiessle 735eac6c9d add a explicit interface for the home storage 2014-07-01 17:31:33 +02:00
Vincent Petry 7c17452028 Added unit test for default app URL 2014-07-01 16:55:29 +02:00
Morris Jobke b6a4cc20f7 Redirect after session expiry to the previous loaded page
* fixes #6945
2014-07-01 16:54:52 +02:00
Jörn Friedrich Dreyer 5a588333b2 introduce and use getCurrentConnection() 2014-07-01 16:45:00 +02:00
Vincent Petry 3e78f41d00 Use getAbsoluteUrl for redirection URL
Also separate the function into getDefaultPageUrl() and
redirectToDefaultPage() to make it testable.
2014-07-01 16:02:38 +02:00
Vincent Petry c005515ebd Support for multiple default apps
If a default app isn't visible for the user, try the next one.
Else fallback to the "files" app.
2014-07-01 15:42:26 +02:00
Robin Appelman 8161104420 Catch StorageInvalidException in webdav 2014-07-01 15:03:29 +02:00
blizzz 616f9b1e03 Merge pull request #9156 from owncloud/solve-8959
search term for users and groups may occur anywhere in the name or displ...
2014-07-01 14:37:09 +02:00
Vincent Petry 894d69184a Add bak defaultapp setting 2014-07-01 14:28:45 +02:00
Jörn Friedrich Dreyer dd20b9f672 reset collection to 'root' after adding a route to the api 2014-07-01 14:21:20 +02:00
Vincent Petry b752aff51d Fix migrator tests to use the correct migrator instances 2014-07-01 12:54:35 +02:00
Jan-Christoph Borchardt 75a5746b70 Merge pull request #9306 from owncloud/publicneedsupgrade
Return 503 in  public.php and OCS API when upgrade is due
2014-07-01 11:52:39 +02:00
Arthur Schiwon 16275eca84 loop over usernames, not passwords 2014-06-30 20:43:50 +02:00
Robin Appelman 99960d7747 Handle StorageNotAvailableException in webdav 2014-06-30 16:36:11 +02:00
Robin Appelman d78a2a9f78 Add StorageNotAvailableException 2014-06-30 15:46:37 +02:00
Vincent Petry 972fffbe02 Return 503 OCS response with requested format 2014-06-30 15:37:38 +02:00
Joas Schilling 0c711e1cfa Use get random bytes as uniqeid() is not unique in some cases
Fix #9161
2014-06-30 11:10:10 +02:00
Georg Ehrke c30bea45e9 don't typecast null values inside dispatcher.php 2014-06-29 22:40:50 +02:00
Thomas Müller 9032ce4535 Merge pull request #9266 from owncloud/fix_objectstore_etag_update
always regenerate etag when writing back file to objectstore
2014-06-29 20:59:20 +02:00
Volkan Gezer ae68a773c0 more strings to translate in utils also some fixes in defaults 2014-06-28 13:29:24 +02:00
Normal Ra 42edd5b788 Add .apk mimetype. 2014-06-28 00:13:15 +02:00
icewind1991 1a3e698294 Merge pull request #9263 from owncloud/remote-share-update
Better detecting of remote changes for external shares
2014-06-27 19:31:18 +02:00
Jörn Friedrich Dreyer 23fa75f5ac always regenerate etag when writing back file to objectstore 2014-06-27 18:49:06 +02:00
Robin Appelman db3f0cee4a Fix parsing of webdav permissions 2014-06-27 17:28:56 +02:00
Robin Appelman 6f5d5b9a30 Also check for updated permissions for webdav storages 2014-06-27 17:27:47 +02:00
Robin Appelman 5b8c2ac750 Use the etag to check for updates in webdav storages where available 2014-06-27 17:10:46 +02:00
Vincent Petry fd8b5680dd Merge pull request #8383 from owncloud/object_storage
Object storage
2014-06-27 16:53:03 +02:00
Jörn Friedrich Dreyer 25dbbbadd3 use normalize path to convert '.' to '' in objectstorestorage 2014-06-27 15:00:29 +02:00
Thomas Müller 4d6019b73f Merge pull request #9247 from owncloud/move-webdav-class-to-core-master
Move webdav class to core master
2014-06-27 12:59:59 +02:00
Jörn Friedrich Dreyer ab93f1949d update hasUpdated description, overwrtie testStat for objectstore test 2014-06-27 12:14:31 +02:00
Vincent Petry 4b5bf606cb Merge pull request #9215 from owncloud/officemimetypesupdatefix
Office mime types update fix
2014-06-27 11:23:19 +02:00
Thomas Müller 171475b95a fix autoloader 2014-06-27 08:52:40 +02:00
Thomas Müller c745240543 Move \OC\Files\Storage\DAV to core in order to reduce inter-app dependencies 2014-06-27 08:52:28 +02:00
Robin Appelman f93457c41d Fix check if class exists 2014-06-27 00:52:37 +02:00
Robin Appelman 437094bbfc Check if classes/method exists before trying to call them in background jobs 2014-06-26 22:40:12 +02:00
Thomas Müller 7804bd010c Merge pull request #9230 from owncloud/fix-repair-step-php-53
Redeclared as public to allow invocation from within the closure in php ...
2014-06-26 17:20:09 +02:00
Vincent Petry 8526556110 Merge pull request #9206 from owncloud/occ-scan-user
Prevent running the files:scan command as the wrong user
2014-06-26 17:03:23 +02:00
Vincent Petry b7d79a90b0 Merge pull request #9210 from owncloud/better_validation_in_getAppPath
better validation for OC_App::getAppPath()
2014-06-26 15:52:12 +02:00
Thomas Müller 4c80c9595f Redeclared as public to allow invocation from within the closure in php 5.3 2014-06-26 14:27:41 +02:00
Bernhard Posselt 2662c4c61b use id instead of resourceId 2014-06-26 14:20:35 +02:00
Bernhard Posselt 5496ca234b dont strip the s from the resource 2014-06-26 14:02:20 +02:00
voxsim 5d30ed9ad1 fix in displayNamesInGroup: when specified limit N, we did complex search only in the first N users 2014-06-26 12:38:33 +02:00
Jörn Friedrich Dreyer f96a535f80 fix objectstore test execution 2014-06-26 11:30:00 +02:00
Björn Schießle 1822bba5e9 Merge pull request #9193 from owncloud/sharing_etag_propagation
make sure that the etags get propagated correctly
2014-06-26 10:26:24 +02:00
Vincent Petry b1e778d5fd Moved office mimetype update to a repair step 2014-06-25 19:49:18 +02:00
Georg Ehrke 09356bc5b3 better validation for OC_App::getAppPath() 2014-06-25 16:24:55 +02:00
Robin Appelman 9a2ed86672 Prevent running the files:scan command as the wrong user 2014-06-25 15:22:49 +02:00
icewind1991 16396e2e33 Merge pull request #9123 from owncloud/webdav-move-permissions
Fix permissions check when moving a file to a different directory over webdav
2014-06-25 15:09:58 +02:00
Jörn Friedrich Dreyer 8e6cb6dc54 delete object without downloading it first 2014-06-25 14:53:38 +02:00
Arthur Schiwon f3ecf819ec extend Dummy user and group implementation to pass tests 2014-06-25 13:13:53 +02:00
Robin Appelman 113749bd96 really always take root of the substorage 2014-06-25 13:00:11 +02:00
Bjoern Schiessle a0b85fc5e4 make sure that during share and unshare the etags get propagated correctly 2014-06-25 12:11:56 +02:00
Arthur Schiwon 121d52860e return int, not string 2014-06-24 21:54:57 +02:00
Bjoern Schiessle 92a82f02b3 always take root of the substorage 2014-06-24 18:53:51 +02:00
Robin Appelman 92f2a430a8 Don't bother checking for external updates for objectstore storages 2014-06-24 14:48:59 +02:00
Robin Appelman eb97eee964 Only initialize the swift container when manipulating an object 2014-06-24 14:42:52 +02:00
Robin Appelman 159b603d13 Add support for rackspace swift backends 2014-06-24 14:36:29 +02:00
Bjoern Schiessle 70ca292fd9 only the mount point has delete and update permissions to enable rename operation 2014-06-24 13:55:04 +02:00
Bjoern Schiessle 84d36df70b make sure that we always return the correct permissions 2014-06-24 13:39:37 +02:00
Thomas Müller f913b1629b Merge pull request #9158 from owncloud/no-recursion-on-rmdirr-master
fix recursion on rmdirr
2014-06-23 23:18:10 +02:00
Thomas Müller fba694edae update PHPDoc $fileInfo is a SplFileInfo 2014-06-23 23:15:30 +02:00
Joas Schilling 167ba14af7 Merge pull request #9159 from owncloud/enabledapp-cache-loggedin
Only cache enabled apps when logged in
2014-06-23 18:02:57 +02:00
Jörn Friedrich Dreyer 28c1a95575 use common storage test 2014-06-23 16:29:01 +02:00
macjohnny 11ccb57fc7 modified caching mechanism in getUserGroupIds
removed cachedUserGroupIds, instead changed indexing in getUserGroups to groupId
2014-06-23 15:59:27 +02:00
Vincent Petry 8c82098281 Merge pull request #8974 from owncloud/router-preventloadappsonupgrade
Prevent loadApps on upgrade
2014-06-23 15:15:50 +02:00
Robin Appelman 2547945779 Add comment 2014-06-23 15:14:35 +02:00
macjohnny 24e397afd2 clean up function getUserGroupIds
clean up of function getUserGroupIds and improved caching mechanism of cachedUserGroupIds
2014-06-23 14:47:19 +02:00
Thomas Müller ed31f30afd dir itself has to be removed as well 2014-06-23 14:40:55 +02:00
Robin Appelman 8b41689fe6 Only cache enabled apps when logged in 2014-06-23 13:55:21 +02:00
Thomas Müller f83821c388 fix recursion on rmdirr 2014-06-23 13:54:27 +02:00
Arthur Schiwon 01a012980a search term for users and groups may occur anywhere in the name or displayname, not just in the beginning 2014-06-23 12:03:09 +02:00
Jörn Friedrich Dreyer 7ec53571c4 use 'object' as the fakedir stream name 2014-06-23 11:07:01 +02:00
Arthur Schiwon 81ecbbb061 trusted domains shall not be ignored on autosetup 2014-06-23 10:33:15 +02:00
Bart Visscher 089139f8ea Add explanation about the current implementation of updateApp 2014-06-22 12:45:59 +02:00
macjohnny 405e89f45a Update manager.php 2014-06-21 16:06:11 +02:00
Robin Appelman 80e6d357a2 Fix permissions check when moving a file to a different directory over webdav 2014-06-20 14:29:13 +02:00
Jörn Friedrich Dreyer c112a1d323 move to stream based IObjectStore interface, rearrange & reformat code 2014-06-20 12:27:47 +02:00
macjohnny 6a3d6d3e4b Update manager.php 2014-06-19 20:32:37 +02:00
macjohnny 14fcd68172 Update manager.php 2014-06-19 19:35:10 +02:00
macjohnny c954168973 Update manager.php
defined $uid in getUserGroupIds
2014-06-19 13:28:37 +02:00
macjohnny 18c7c94b7a Update manager.php
added description and blank lines in getUserGroupIds
2014-06-19 11:41:29 +02:00
macjohnny 356e4b6665 Update manager.php
add caching to getUserGroupIds
2014-06-19 11:37:46 +02:00
Jörn Friedrich Dreyer f2fe00e972 fix rebase, use 'object::user:<username>' or 'object::store:<storageid> as storage id, by default use container/bucket name for storageid, make storageid configurable, store user only for HomeObjectStoreStorage, change updateObject() to writeObject() 2014-06-18 15:20:26 +02:00
Jörn Friedrich Dreyer 5cae863408 change architecture from inheritance to composition 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 9335a5f07f remove duplicate method 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 5722e31d1a add autocreate config option for containers, implement autocreate and delete of containers, use generated container names for tests 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 4e65889f54 only use one config option 'objectstore' for root and home storage configuration 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 7493ff0624 fix unit test by always initializing the root of the storage in the constructor 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 10de4a7b90 move creation of / and users 'files' from storage constructor to setupFS / mount initialization 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 87aaf39259 fix checking unset array values, deduplicate code, remove file from cache if it could not be stored in the objectstore 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer eca536d8b4 minor code cleanup 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer c020e8e658 use exceptions to notify abstract parent class of problems 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 60a8419a1f when root storage cannot be mounted throw an exception visible to the end user 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 1374ba9adf fix fallback config for default home storage 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer ccb698a6a8 move swift and abstract code to core 2014-06-18 12:53:20 +02:00
Jörn Friedrich Dreyer 85ccfad37c change 'object_storage' config param to 'root_storage'
copy skeleton only for local filesystems
2014-06-18 12:53:19 +02:00
Jörn Friedrich Dreyer 2bf7e5c02f make objectstore setup more robust, don't pass user to object store mounted as root 2014-06-18 12:53:19 +02:00
Jörn Friedrich Dreyer 3c66a8c8ed allow configuring objectstore as home and root storage 2014-06-18 12:53:19 +02:00
Vincent Petry 799205488c Prevent loadApps on upgrade
Moved OC::needUpgrade() to OCP\Util::needUpgrade() to make it accessible
form the router.
Moved maintenance + upgrade check to the router.
2014-06-18 11:10:07 +02:00
icewind1991 8d1cf79152 Merge pull request #8399 from owncloud/server-server-sharing
Add server<->server sharing
2014-06-17 17:40:05 +02:00
Vincent Petry cce58368ad Merge pull request #9065 from owncloud/migrator-keepprimaryindexname
Do not rename primary key index when renaming table
2014-06-17 16:43:33 +02:00
Vincent Petry 7aa11b4361 Do not rename primary key index when renaming table
When the migrator renames a table, for example for upgrade simulation,
it should not rename the primary key to avoid messing up with the diff
because the MySQL Doctrine code expects that index to always be called
"primary".
2014-06-17 15:23:18 +02:00
Andreas Fischer 9db0a82a26 We obviously have to pass the hostname as is when there is no ':' in the hostname.
This reverts commit 73062040e6.
2014-06-17 14:48:32 +02:00
Robin Appelman 07fdeba50b Fix moving movablemount over webdav 2014-06-17 14:10:11 +02:00
Jörn Friedrich Dreyer cd77f92f4c add new keynote mimetype 2014-06-16 16:25:12 +02:00
Robin Appelman b188550c22 Also support removeable mounts with rmdir 2014-06-16 16:24:42 +02:00
Robin Appelman 0532f5c39a Fix permission for movable storage root 2014-06-16 16:20:40 +02:00
Georg Ehrke 15c215cd03 Merge pull request #8808 from owncloud/update_shipped_apps_from_appstore
Make shipped apps updatable via appstore
2014-06-16 15:54:50 +02:00
Georg Ehrke 86f546ff64 disable code check for shipped apps 2014-06-16 13:49:02 +02:00
Vincent Petry a48bcceb23 Merge pull request #8917 from owncloud/repair-routine-base
Add support for repair step classes
2014-06-16 11:13:10 +02:00
macjohnny e5224782fa Merge pull request #9022 from owncloud/speedup-nested-ldap-groups
drastic speedup for nested ldap groups
2014-06-16 07:50:53 +02:00
Robin Appelman 87e311b996 Fix storage being passed to cache/watcher and scanner when using storage wrappers 2014-06-14 10:14:08 +02:00
Robin Appelman c61f759a8b Fix check for shared files inside shares 2014-06-14 10:14:08 +02:00
Robin Appelman c6a83b2f17 Fix exposing single files over webdav 2014-06-14 10:13:24 +02:00
Robin Appelman 65f3b2fad2 Add server<->server sharing backend 2014-06-14 10:10:37 +02:00
Morris Jobke 35f7565e9b Merge pull request #8978 from owncloud/movie_preview_improvements
movie previews: use file directly when it's stored locally and encryption is not enabled
2014-06-14 01:01:59 +02:00
Georg Ehrke 65028c459b don't skip code check for skipped apps
those apps will have to use the public api
2014-06-13 21:51:16 +02:00
Georg Ehrke c378e76412 skip certain tests for shipped apps 2014-06-13 21:45:31 +02:00
Frank Karlitschek 87101e6638 Merge pull request #9018 from owncloud/dbms-socket-support
Refactor OC_DB::connect() to properly support sockets.
2014-06-13 18:09:51 +02:00
macjohnny 767aa4e35f drastic speedup for nested ldap groups
add a function getUserGroupIds for retrieving group ids instead of group objects. this significantly improves performance when using many (nested) groups.

Changes a function call in getUserGroups to only retrieve group ids instead of objects.
this change significantly improves performance when using owncloud with many groups, e.g. nested ldap hierarchy (1.2.840.113556.1.4.1941), since getUserGroups gets called in oc_share::getItems, which is needed for every page request.
in my particular case, it took more than 10s to load the calendar page and more than 6s to load the file page.
this was in an environment with 100 user groups (nested) per user. The performance was bad due to the following call stack:
self::getManager()->getUserGroups($user)
  - getGroupObject() (executed for every group!)
     - groupExists() (resulting in many ldap-requests)
since the groups are loaded from ldap, it is unnecessary to check whether the group exists or not.
2014-06-13 00:04:06 +02:00
Andreas Fischer 73062040e6 Don't specify host when using a socket. 2014-06-12 20:22:45 +02:00
Andreas Fischer 0932760304 Rename variable to indicate that it can be port and socket. 2014-06-12 20:18:38 +02:00
Andreas Fischer 3d8eabedbd No need to check the port number as this will fail anyway. 2014-06-12 20:17:30 +02:00
Andreas Fischer 4ca1e3cc02 Move getValue() to where required. This actually is not required "global data". 2014-06-12 19:59:40 +02:00
Andreas Fischer 17c2e63449 Move check for : to where it belongs, getting rid of $socket = false; 2014-06-12 19:56:51 +02:00
Andreas Fischer 4b87586487 Extract common variables of $connectionParams. 2014-06-12 19:53:33 +02:00
Andreas Fischer 6da2beeaff Inline $port expression, getting rid of $port variable. 2014-06-12 19:48:37 +02:00
Vincent Petry b595c982d0 Merge pull request #8968 from owncloud/scanner-parent-repair
Repair broken parent link in the scanner
2014-06-12 17:40:44 +02:00