Commit graph

189 commits

Author SHA1 Message Date
Bjoern Schiessle
698ecbf308 OCS API for server-to-server sharing 2014-12-04 13:18:13 +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
Joas Schilling
2c39aec8cb Replace deprecated constant with new class constant 2014-11-25 16:30:21 +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
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
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
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
Lukas Reschke
c30b7f8197 Remove unreachable statement 2014-10-23 23:03:14 +02:00
Bjoern Schiessle
b7718bc212 always use the correct share type 2014-10-22 11:48:29 +02:00
Bernhard Reiter
7e9baafc53 Add option to include tags for shared items. 2014-10-14 00:06:07 +02:00
Bjoern Schiessle
c6c9a51b11 distinguish between file dependent shares and other shares 2014-10-13 15:04:54 +02:00
Bjoern Schiessle
3431d547a9 fix performance issues 2014-10-10 12:16:26 +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
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
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
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
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
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
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
kondou
a10411d2bc Readd TOKEN_LENGTH 2014-09-04 19:09:26 +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
Joas Schilling
a0e8e88bc6 Use correct language package so the subject is correctly translated
Fix #10847
2014-09-04 11:23:23 +02:00
Robin Appelman
d0266c0bf8 Use public api for getting l10n 2014-08-31 10:08:22 +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
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
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
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
Volkan Gezer
173538befb typo fix from transifex suggestion 2014-08-06 20:48:26 +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
Bjoern Schiessle
41cca70a63 don't display share permission if resharing was disabled by the admin 2014-08-05 10:57:51 +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
Volkan Gezer
5f015067f4 suggestions by deepdiver 2014-08-01 01:39:52 +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
Bjoern Schiessle
67e302885c remove share permission if user is excluded from sharing 2014-07-29 10:08:08 +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
Michael Kuhn
ecdd04374a Allow specifying the item source in unshareFromSelf(). 2014-07-26 02:00:49 +02:00
Bjoern Schiessle
ecc1f92bb6 add OCS api call to set expire date for link shares 2014-07-25 13:38:18 +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
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
Daniel Hansson
851c1f87d6 Fix for #9422 2014-07-09 14:40:05 +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
Bjoern Schiessle
a0b85fc5e4 make sure that during share and unshare the etags get propagated correctly 2014-06-25 12:11:56 +02:00
Robin Appelman
c61f759a8b Fix check for shared files inside shares 2014-06-14 10:14:08 +02:00
Robin Appelman
65f3b2fad2 Add server<->server sharing backend 2014-06-14 10:10:37 +02:00
Vincent Petry
65b3d293ce Added ORDER BY to enforce share entry order
Sometimes MySQL decides to return the shares in the wrong order, but
some parts of the code seem to require the order to be known, at least
so that the parent shares come before the children shares.

This fix adds an ORDER BY clause to force the order by id.
2014-06-11 14:28:30 +02:00
Bjoern Schiessle
f15d7dfec0 only expire link shares 2014-06-06 15:47:37 +02:00
Bjoern Schiessle
3459f99dd6 make sure that we only delete shares for the current user 2014-06-06 09:56:02 +02:00
Bjoern Schiessle
eec1c4398a only unshare user share if it was shared with the current user 2014-06-06 09:56:02 +02:00
Bjoern Schiessle
5bbfdc35d7 make sure that we remove all shares refering to the same parent 2014-06-06 09:56:02 +02:00
Bjoern Schiessle
86d7371d0c fix unshareFromSelf() 2014-06-06 09:56:02 +02:00
Bjoern Schiessle
bf5e9357fc don't allow to share single files with delete permissions, user should only be possible to unshare a single file but never to delete it 2014-06-06 09:55:59 +02:00
Bjoern Schiessle
6578f00b4b unify share settings 2014-06-05 15:49:34 +02:00
Thomas Müller
da3974bcb2 - drop permissions table and related code
- the file/folder's permission is now stored in the file cache
- BackGroundWatcher has been removed - this has meanwhile be replaced by occ files:scan which can be executed in a cron jobs
- increase version to trigger database migration
2014-06-05 08:22:01 +02:00
Bjoern Schiessle
12338e0ef0 allow admin to disable sharing for specific groups of users 2014-05-22 10:43:44 +02:00
Morris Jobke
dc36d30953 Remove all occurences of @brief and @returns from PHPDoc
* test case added to avoid adding them later
2014-05-19 17:50:53 +02:00
Joas Schilling
ab7ae004f7 Automatically copy the share expiration date when new shares are created
Fix #4823
2014-05-19 01:38:47 +02:00
Björn Schießle
42b99b6d0f Merge pull request #8555 from owncloud/sharing_default_expire_only_public_links
use default expire date only for link shares
2014-05-16 14:57:11 -04:00
Bjoern Schiessle
7a48f24459 use default expire date only for link shares 2014-05-16 18:12:13 +02:00
Bjoern Schiessle
b6e14af861 allow admin to enforce passwords for public link shares 2014-05-16 17:41:09 +02:00
Thomas Müller
fa503a4772 fix PHPDoc 2014-05-13 19:09:15 +01:00
Thomas Müller
7853bc4cac adding PHPDoc 2014-05-13 19:09:14 +01:00
Thomas Müller
147007bdd8 fixing typo and missing @throws 2014-05-13 19:09:14 +01:00
Robin McCorkell
87b548ed91 Fix all PHPDoc types and variable names, in /lib 2014-05-13 19:08:14 +01:00
Robin McCorkell
a7ae2e874a Squash 'a | b' into 'a|b', in /lib 2014-05-13 19:08:14 +01:00
Robin McCorkell
b5bc37d2e4 Fix @return array PHPDocs, in /lib 2014-05-13 19:08:14 +01:00
Vincent Petry
390549c286 Merge pull request #8221 from owncloud/type-hinting-sharing
Type hinting fixes for sharing
2014-05-08 09:30:50 +02:00
Bart Visscher
9f88141bcd Use 'boolean' as type instead of 'bool' 2014-05-07 20:46:08 +02:00
Bart Visscher
72864d1c53 Typo 2014-05-06 18:05:06 +02:00
Bart Visscher
50f49c57b5 Some more params are optional 2014-05-01 18:11:30 +02:00
Bart Visscher
66b1ad0a9b Merge branch 'master' into type-hinting-sharing
Conflicts:
	apps/files_sharing/lib/share/file.php
	apps/files_sharing/tests/api.php
	lib/private/share/share.php
2014-04-28 17:59:41 +02:00
Robin McCorkell
77e3d067f0 Better handle return values from Filesystem::getMountBy*
getMountByStorageId and getMountByNumericId return an empty array on error,
which should be detected to avoid possible errors. This commit also adds in
some new logging points and throws to aid debugging
2014-04-25 09:50:34 +01:00
Björn Schießle
f520305848 Merge pull request #8026 from owncloud/remove_shared_folder
remove the "Shared" folder
2014-04-24 18:45:45 +02:00
Bjoern Schiessle
35321c7d41 add additional rows to the select statement, 'stime' is needed for the expire check 2014-04-24 15:18:25 +02:00
Bjoern Schiessle
6650be9913 add setting to set default expire date 2014-04-24 13:34:31 +02:00
Volkan Gezer
ff0dab6e92 This adds one more missing untranslated text from lib/share
Also displays the untrusted domain warning in English
2014-04-24 01:42:18 +02:00
Bjoern Schiessle
b312d38d38 remove hard-coded shared folder 2014-04-23 12:59:22 +02:00
Bjoern Schiessle
fb88aba8f4 some fixes to make the gallery work, this made it necessary to adjust some tests and the encryption code 2014-04-23 12:54:26 +02:00
Bjoern Schiessle
652d417a58 we don't allow to share a folder if it contains a share mount point 2014-04-23 12:54:26 +02:00
Bjoern Schiessle
bffcbac7a7 allow to rename group share mount points 2014-04-23 12:54:25 +02:00
Bjoern Schiessle
4c840cb61d fix target generation for group shares 2014-04-23 12:54:25 +02:00