summaryrefslogtreecommitdiffstats
path: root/lib/private/Share20/Manager.php
Commit message (Collapse)AuthorAgeFilesLines
* Fix sharebymail testsJohn Molakvoæ (skjnldsv)2021-03-221-12/+27
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Remove duplicated query for email sharesDaniel Calviño Sánchez2021-03-221-34/+18
| | | | | Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com> Signed-off-by: npmbuildbot-nextcloud[bot] <npmbuildbot-nextcloud[bot]@users.noreply.github.com>
* Sharing link & mail parityJohn Molakvoæ (skjnldsv)2021-03-221-18/+24
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Merge pull request #23718 from nextcloud/already-shared-error-messageRoeland Jago Douma2021-03-191-3/+5
|\ | | | | expand 'path is already shared' error message
| * expand 'path is already shared' error messageRobin Appelman2021-03-151-3/+5
| | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Update user share must use correct expiration validationVincent Petry2021-03-181-5/+5
|/ | | | | | | | | | | Updating a user or group share now uses the correct method for the validation of the expiration date. Instead of using the one from links it uses the one for internal shares. To avoid future confusion, the method "validateExpirationDate" has been renamed to "validateExpirationDateLink". Signed-off-by: Vincent Petry <vincent@nextcloud.com>
* Add a setting to restrict returning a full match unless in phonebook or same ↵Joas Schilling2021-03-101-0/+4
| | | | | | group Signed-off-by: Joas Schilling <coding@schilljs.com>
* Restrict autocompletion also based on the phonebook known usersJoas Schilling2021-03-101-0/+5
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* send share notification instead of erroring on duplicate shareRobin Appelman2021-03-091-63/+69
| | | | | | when creating a share that already exists, instead of erroring, resend the notifications Signed-off-by: Robin Appelman <robin@icewind.nl>
* Bump nextcloud/coding-standard from 0.3.0 to 0.5.0dependabot-preview[bot]2021-02-181-4/+4
| | | | | | | | | | Bumps [nextcloud/coding-standard](https://github.com/nextcloud/coding-standard) from 0.3.0 to 0.5.0. - [Release notes](https://github.com/nextcloud/coding-standard/releases) - [Changelog](https://github.com/nextcloud/coding-standard/blob/master/CHANGELOG.md) - [Commits](https://github.com/nextcloud/coding-standard/compare/v0.3.0...v0.5.0) Signed-off-by: dependabot-preview[bot] <support@dependabot.com> Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* revert(comment)Samuel2021-02-051-1/+0
| | | | Signed-off-by: Samuel <faust64@gmail.com>
* revert(exception): keep throwing an exception for nowSamuel2021-02-051-2/+3
| | | | Signed-off-by: Samuel <faust64@gmail.com>
* fix(translation): replace static error messageSamuel2021-02-051-2/+3
| | | | | | as suggested by @kesselb in nextcloud/server#25490 Signed-off-by: Samuel <faust64@gmail.com>
* Move to single share event. Just emit more if neededRoeland Jago Douma2020-12-231-1/+2
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* +ShareDeletedEventMaxence Lange2020-12-231-0/+2
| | | Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
* Update all license headers for Nextcloud 21Christoph Wurst2020-12-161-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Dummy general share checks for deckJulius Härtl2020-12-091-0/+1
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Allow apps to register their share providers from outsideJulius Härtl2020-12-091-0/+4
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Fix default internal expiration dateDaniel Calviño Sánchez2020-11-161-3/+3
| | | | | | | The default expiration date for internal shares was set from the default link expiration date instead of the internal one. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* use file name instead of path in 'not allowed to share' messageRobin Appelman2020-10-291-2/+1
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Format code to a single space around binary operatorsChristoph Wurst2020-10-051-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #22234 from nextcloud/bugfix/noid/reshare-mountMorris Jobke2020-09-101-4/+12
|\ | | | | Use user mount with matching shared storage only
| * Use user mount with matching shared storage onlyJulius Härtl2020-08-131-4/+12
| | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Update the license headers for Nextcloud 20Christoph Wurst2020-08-241-1/+1
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Allow to disable share emailsJoas Schilling2020-08-191-1/+2
|/ | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Use the correct mountpoint to calculateRoeland Jago Douma2020-07-091-1/+8
| | | | | | | If we use the owners mount point this results in null. And then the rest of the checks get called with null. Which doesn't work. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Use the new method everywhereJoas Schilling2020-07-031-1/+1
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Replace Share with IShare and add missing return.Daniel Kesselberg2020-06-261-3/+3
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* Update share type constant usageJoas Schilling2020-06-241-84/+85
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Prevent harder to share your rootJoas Schilling2020-06-031-3/+1
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Fix disabling send password by Talk without new password in mail sharesDaniel Calviño Sánchez2020-05-291-4/+4
| | | | | | | | | | | | | | | | | | When "send password by Talk" was disabled in a mail share it was possible to keep the same password as before, as it does not pose any security issue (unlike keeping it when "send password by Talk" is enabled, as in that case the password was already disclosed by mail). However, if a mail share is updated but the password is not set again only the hashed password will be available. In that case it would not make sense to send the password by mail, so now the password must be changed when disabling "send password by Talk". Note that, even if explicitly setting the same password again along with the "send password by Talk" property would work, this was also prevented for simplicity. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Fix enabling send password by Talk with same password in mail sharesDaniel Calviño Sánchez2020-05-281-1/+11
| | | | | | | | | | | | | When "send password by Talk" is enabled in a mail share a new password must be also set. However, when the passwords of the original and the new share were compared it was not taken into account that the original password is now hashed, while the new one is not (unless no new password was sent, in which case the password of the original share was set in the new share by the controller, but that was already prevented due to both passwords being literally the same), so it was possible to set the same password again. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Fix enabling send password by Talk with empty password in link sharesDaniel Calviño Sánchez2020-05-281-0/+6
| | | | | | | When "send password by Talk" is enabled in a link share now a non empty password is enforced. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Remove group from excluded_groups_list after deleteDaniel Kesselberg2020-05-171-0/+13
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* Update license headers for 19Christoph Wurst2020-04-291-1/+0
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #19793 from nextcloud/bugfix/noid/link-to-federated-reshareMorris Jobke2020-04-271-5/+0
|\ | | | | Fix resharing of federated shares that were created out of links
| * Link shares have reshare permission if outgoing federated shares are enabledJulius Härtl2020-04-211-5/+0
| | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Allow specifying a default expiration dateRoeland Jago Douma2020-04-241-2/+12
|/ | | | | | This overrides the max expiration date. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Provide the proper language to the mailerRoeland Jago Douma2020-04-161-2/+2
| | | | | | | Else we can't properly translate the footer in the recipients e-mail language. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Merge pull request #19936 from ↵Joas Schilling2020-04-141-2/+6
|\ | | | | | | | | nextcloud/bugfix/noid/handle-unset-owner-in-sharing Handle unset owner in sharing
| * Handle unset owner in sharingJoas Schilling2020-03-131-2/+6
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Format control structures, classes, methods and functionChristoph Wurst2020-04-101-16/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To continue this formatting madness, here's a tiny patch that adds unified formatting for control structures like if and loops as well as classes, their methods and anonymous functions. This basically forces the constructs to start on the same line. This is not exactly what PSR2 wants, but I think we can have a few exceptions with "our" style. The starting of braces on the same line is pracrically standard for our code. This also removes and empty lines from method/function bodies at the beginning and end. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Use elseif instead of else ifChristoph Wurst2020-04-101-13/+13
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Unify function spacing to PSR2 recommendationChristoph Wurst2020-04-091-2/+2
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Fix (array) indent style to always use one tabChristoph Wurst2020-04-091-1/+1
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Use the short array syntax, everywhereChristoph Wurst2020-03-261-3/+3
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Expose enumeration config though share managerJulius Härtl2020-03-201-0/+9
| | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Update the target when it isempty after sharingRoeland Jago Douma2020-03-161-0/+5
|/ | | | | | | Hooks that listen to it (audit log) benefit from having the target properly set. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Strip of users home path from share api messageJoas Schilling2020-02-201-2/+4
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Accept shares when you open mailRoeland Jago Douma2020-01-061-1/+1
| | | | | | | | | Fixes #18380 When you open a direct share to yourself. We should autoaccept the share. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>