Roeland Jago Douma
85e48d796c
Merge pull request #25929 from nextcloud/techdept/psalm/25839/redundantcasts
...
Remove Redundantcasts
2021-03-05 08:42:54 +01:00
Roeland Jago Douma
d7f7d3bc51
Type CompositeExpression and ICompositeExpression
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-04 21:47:44 +01:00
Robin Appelman
b844293536
catch notfound and forbidden exception in smb::getmetadata
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-03-04 21:34:54 +01:00
Roeland Jago Douma
c3f1eb4f7f
Remove Redundantcasts
...
For #25839
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-04 14:44:04 +01:00
Roeland Jago Douma
b14be34689
Type Entry and IEntry
...
* Fixed a docblock
* Typed the entries
Psalm happier, Roeland happier
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-04 14:30:21 +01:00
Roeland Jago Douma
76a6328d10
Add executeQuery and executeUpdate
...
Names shamelessly copied from Doctrine itself.
Internally it is still using the same flow. But I added some checks
around it.
This should make static analysis a bit more happy. Which in turn makes
me more happy.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-04 14:03:31 +01:00
Roeland Jago Douma
5325c3002c
Merge pull request #25917 from nextcloud/techdept/kill_deprecated/ocp_api
...
Remove deprecated \OCP\API
2021-03-03 21:57:34 +01:00
Roeland Jago Douma
a58b4ceaab
Merge pull request #25889 from nextcloud/techdept/psalm/fix_group_manager_function_return_type
...
Fix types in the Group Manager
2021-03-03 20:55:52 +01:00
Roeland Jago Douma
cc744740b7
Remove deprecated \OCP\API
...
Time to remove this forgood now.
Remaining constant moved over
The world is a tiny bit better
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-03 20:54:32 +01:00
Roeland Jago Douma
68ec18323d
Fix types in the Group Manager
...
Psalm found an issue. However the issue found was because of lying
docblocks. Fixed those and did some typing to make it all better.
For #25839
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-03 14:52:47 +01:00
Joas Schilling
a6246be34c
Merge pull request #25656 from nextcloud/enh/type/expressionbuilder
...
Type the experssionbuilders
2021-03-03 11:37:16 +01:00
Roeland Jago Douma
4bdf9f5849
Type the experssionbuilders
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-03 10:44:09 +01:00
Robin Appelman
47dd8e54b5
allow non string join conditions in query builder
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-03-03 10:43:15 +01:00
Roeland Jago Douma
1531414e8d
Fix docblock return type for IShareProvider
...
All the implementations already returned an array of array of shares. So
better to make sure the docblock also doesn't lie.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-03-02 20:12:46 +01:00
Joas Schilling
3d62233cab
Merge pull request #25869 from nextcloud/fix/imanager-namespacing
...
Fix namespacing
2021-03-02 11:05:14 +01:00
Anna Larch
f9083ef7bf
Fix namespacing
...
Signed-off-by: Anna Larch <anna@nextcloud.com>
2021-03-02 09:37:34 +01:00
Johannes Leuker
2796ef80ff
Show group backends in occ group:list --info and group:info
...
Signed-off-by: Johannes Leuker <j.leuker@hosting.de>
2021-03-01 16:02:08 +01:00
Jonas Rittershofer
f02362e029
Include RichObject for forms
...
Ref. https://github.com/nextcloud/forms/pull/789
Signed-off-by: Jonas Rittershofer <jotoeri@users.noreply.github.com>
2021-03-01 14:00:33 +01:00
Lukas Reschke
e5a0219133
Merge pull request #25680 from nextcloud/taint-expressionbuilder
...
Add expression taint source and sanitizer
2021-02-22 12:26:48 +01:00
dependabot-preview[bot]
eb502c02ff
Bump nextcloud/coding-standard from 0.3.0 to 0.5.0
...
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>
2021-02-18 13:31:24 +01:00
Lukas Reschke
d7590a6190
Add expression taint source and sanitizer
...
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2021-02-17 21:38:15 +01:00
Christoph Wurst
08d4458542
Initialize \OCP\AppFramework\Http\ZipResponse::$resources
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-17 19:59:27 +01:00
Christoph Wurst
24e035dfc8
Drop \OCP\Defaults::getLogoClaim
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-16 11:46:06 +01:00
Christoph Wurst
0c5adaddf8
Drop \OC\Memcache\Factory::create
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-16 11:43:05 +01:00
Robin Appelman
0363af3790
move AbstractCacheEvent into OCP
...
otherwise we have concrete cache events in OCP extending non OCP classes
Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-02-15 19:12:30 +01:00
Christoph Wurst
d45692ee96
Migrate custom loggers to PSR
...
This will help phase out the deprecated ILogger interface.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-11 16:16:34 +01:00
Roeland Jago Douma
1cc23c6e6e
Merge pull request #25558 from nextcloud/deprecate/generic-event-wrapper
...
Deprecate the GenericEvent wrapper
2021-02-10 18:57:07 +01:00
Christoph Wurst
039ecbdcf9
Merge pull request #25560 from nextcloud/enhancement/pure-psr-event
...
Make our event base class independent of Symfony and follow PSR
2021-02-10 16:13:06 +01:00
Christoph Wurst
2f26ff40e9
Merge pull request #25359 from nextcloud/enhancement/typed-service-registration
...
Type the service registration
2021-02-10 15:31:42 +01:00
Christoph Wurst
0a28440bf6
Make our event base class independent of Symfony and follow PSR
...
Symfony is migrating towards a pure PSR event dispatcher, hence their
event class is POPO that implements the PSR stoppable event interface.
Since we can do that ourself and this change doesn't come with any API
changes (breakage), it's easy for us to become independent of Symfony
but also stay PSR-compliant at the same step.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-10 15:15:29 +01:00
Christoph Wurst
aabd73912e
Type the service registration
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-10 09:44:24 +01:00
Christoph Wurst
f76ec25e58
Deprecate the GenericEvent wrapper
...
This class is a convenience type to replace the old Symfony GenericEvent
with our own type, to ease the transition from Symfony events to our
(PSR) events. Hence we can deprecate the class as precaution to smoothen
the next transition step in the future.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-10 08:54:08 +01:00
Christoph Wurst
3c2ea99940
Merge pull request #25546 from nextcloud/techdept/deprecate-event-constants
...
Deprecate all remaining event constants
2021-02-09 20:19:04 +01:00
Christoph Wurst
4fc0b2c639
Deprecate all remaining event constants
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-09 13:53:41 +01:00
Christoph Wurst
3d075c370a
Deprecate the internal IDBConnection event name constants
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-02-09 11:27:59 +01:00
Julius Härtl
a71bb8a485
Make whole Template class final
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-01-28 12:00:21 +01:00
Julius Härtl
6c1b357973
Move TemplateProvider registration to boot context and make template type registration lazy
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-01-28 12:00:21 +01:00
John Molakvoæ (skjnldsv)
4f90766ba3
Skip template picker if none available
...
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2021-01-28 12:00:20 +01:00
Julius Härtl
7e6d69d166
Add templatedirectory config value to let admins have their custom templates by default
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-01-28 12:00:20 +01:00
Julius Härtl
66fa3fca83
Add ratio to template creators
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-01-28 12:00:20 +01:00
John Molakvoæ (skjnldsv)
78e114ed72
Add template picker
...
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2021-01-28 12:00:18 +01:00
Julius Härtl
4974404774
files: Create files from template API
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-01-28 11:59:46 +01:00
Morris Jobke
1d2707ad78
Merge pull request #25273 from nextcloud/enhancement/hide-two-factor-settings-if-no-providers
...
Do not show 2FA settings if the user has no providers available
2021-01-22 16:26:17 +01:00
Christoph Wurst
ac591e2fc2
Fully deprecate the old initial state interface, not just the methods
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-01-22 14:53:26 +01:00
blizzz
939433363e
Merge pull request #25128 from nextcloud/ldapprovider-get-property
...
extend ILDAPProvider to allow reading arbitrairy ldap attributes for users
2021-01-22 14:31:19 +01:00
blizzz
f15148f695
adjust since
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
Co-authored-by: Morris Jobke <hey@morrisjobke.de>
2021-01-22 14:29:39 +01:00
Christoph Wurst
378f116a63
Do not show 2FA settings if the user has no providers available
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-01-22 13:55:22 +01:00
Joas Schilling
6c1e294edd
Compare and store the login name via the event
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-01-20 08:50:17 +01:00
Robin Appelman
fdc8635afb
extend ILDAPProvider to allow reading arbitrairy ldap attributes for users
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-01-19 16:33:58 +01:00
Morris Jobke
bcb52d64f0
Merge pull request #25141 from nextcloud/bugfix/noid/add-a-hint-about-priority
...
Add a hint about the direction of priority
2021-01-15 09:46:37 +01:00
Joas Schilling
b8acf2fe69
Add a hint about the direction of priority
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-01-15 08:34:24 +01:00
Christoph Wurst
b9287f9780
Merge pull request #25091 from nextcloud/enhancement/ocp-db-exception-abstraction
...
Add our own DB exception abstraction
2021-01-14 12:27:23 +01:00
Christoph Wurst
2c9cdc1cdb
Add our own DB exception abstraction
...
Right now our API exports the Doctrine/dbal exception. As we've seen
with the dbal 3 upgrade, the leakage of 3rdparty types is problematic as
a dependency update means lots of work in apps, due to the direct
dependency of what Nextcloud ships. This breaks this dependency so that
apps only need to depend on our public API. That API can then be vendor
(db lib) agnostic and we can work around future deprecations/removals in
dbal more easily.
Right now the type of exception thrown is transported as "reason". For
the more popular types of errors we can extend the new exception class
and allow apps to catch specific errors only. Right now they have to
catch-check-rethrow. This is not ideal, but better than the dependnecy
on dbal.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-01-12 16:38:23 +01:00
blizzz
3447ea4955
Merge pull request #25089 from nextcloud/enhancement/ocp-db-types
...
Add our own db column types via the public API
2021-01-12 15:24:15 +01:00
Christoph Wurst
d4e6463eb2
Add our own constants for db column types
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-01-12 14:09:13 +01:00
Roeland Jago Douma
41c80d6c19
Fix option in the client code itself as well
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-01-12 12:36:21 +01:00
Joas Schilling
078ecac188
Deck Rich-Object-String definitions for deck boards and cards
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-01-11 12:03:13 +01:00
Christoph Wurst
8b64e92b92
Bump doctrine/dbal from 2.12.0 to 3.0.0
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-01-08 11:45:19 +01:00
Christoph Wurst
9ce3ea3368
Update license headers
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-12-30 14:07:05 +01:00
Christoph Wurst
73c7d0dc81
Bump icewind/streams from 0.7.1 to 0.7.2
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-12-29 09:07:36 +01:00
Roeland Jago Douma
bb411c75c6
Move to single share event. Just emit more if needed
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-12-23 11:05:29 +01:00
Maxence Lange
874a1a4c43
cs fix
...
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
2020-12-23 11:00:47 +01:00
Maxence Lange
85783e45e9
+ShareDeletedEvent
...
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
2020-12-23 11:00:45 +01:00
Roeland Jago Douma
adc4f1a811
Merge pull request #22916 from J0WI/unifiy-links-to-php.net
...
Unify links to php.net
2020-12-22 09:53:31 +01:00
Julius Härtl
5094e29ebd
Merge pull request #24594 from kofemann/dcache
2020-12-22 09:26:07 +01:00
Tigran Mkrtchyan
4f2dc18f58
storage: update IStorage#file_put_contents docs to match usage
...
The current phpdoc of IStorage#file_put_contents doesnt corresponds to
it's actual usage in code, e.g.
Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
2020-12-21 19:04:18 +01:00
Christoph Wurst
f37e150d1c
Merge pull request #24702 from nextcloud/enhancement/well-known-handler-api
...
Add well known handlers API
2020-12-18 13:34:04 +01:00
Christoph Wurst
d89a75be0b
Update all license headers for Nextcloud 21
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-12-16 18:48:22 +01:00
Christoph Wurst
6995223b1e
Add well known handlers API
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-12-16 13:13:05 +01:00
Roeland Jago Douma
1d4c8961ef
Merge pull request #24659 from nextcloud/enh/noid/dav-honour-sharing.maxAutocompleteResults
...
dav principal search to honour sharing.maxAutocompleteResults setting
2020-12-16 10:47:32 +01:00
Arthur Schiwon
d8ad4ef6b5
use a consistent default value for sharing.maxAutocompleteResults
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-12-15 11:53:39 +01:00
Joas Schilling
329ffa257e
Log an error when setting a custom header on "Not Modified" responses
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-12-15 11:24:15 +01:00
Thomas Citharel
71cf92697c
Update comment to reflect current CSP policy
...
JS unsafe-eval was removed a long time ago in https://github.com/nextcloud/server/pull/11028
2020-12-12 21:11:42 +01:00
Julius Härtl
c4ea37b8a1
Address minor comments
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-12-09 15:51:41 +01:00
Julius Härtl
c770d33717
Add internal DECK_USER type to allow unsharing for individual users
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-12-09 13:20:24 +01:00
Julius Härtl
fcc0d35895
Add share type for deck
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-12-09 13:20:23 +01:00
Julius Härtl
fdea545415
Allow apps to register their share providers from outside
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-12-09 13:20:23 +01:00
Joas Schilling
fe9c46e595
Add an endpoint to search for accounts based on phone number
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-12-07 14:19:37 +01:00
Christoph Wurst
cc92d5a293
Allow unified search results to have attributes
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-12-03 18:24:33 +01:00
Roeland Jago Douma
6f4d3edb5e
Merge pull request #24113 from nextcloud/extend-cache-events
...
extend cache events
2020-12-02 19:48:20 +01:00
Robin Appelman
aef1cdba03
code style and dispatchTyped
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-12-02 16:15:02 +01:00
Morris Jobke
d87705a894
Allow subscription to indicate that a userlimit is reached
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-12-02 15:20:03 +01:00
Morris Jobke
a125d8aaa1
Reduce code complexity in Share::getItems by tracing all remaining callers
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-11-29 22:30:09 +01:00
Robin Appelman
88f35d52d2
rename cache event to follow new naming standards
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-11-26 15:39:46 +01:00
Robin Appelman
23fb497ff5
extend cache events
...
- adds cache remove event
- expose storage id in event
- emit events during cache move
Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-11-26 15:22:03 +01:00
Christoph Wurst
54e3beba16
Merge pull request #24319 from nextcloud/techdebt/noid/streamline-user-creation-and-deletion-events
...
Streamline user creation and deletion events
2020-11-26 14:09:54 +01:00
Robin Appelman
9d4848e863
use in objectstore copy
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-11-24 15:16:58 +01:00
Roeland Jago Douma
d4fd61b7c6
Merge pull request #24324 from nextcloud/td/psalm/backgroundjob_job
...
Fix the OCP\BackgroundJob\Job to make it compatible with its interface
2020-11-24 13:16:12 +01:00
Roeland Jago Douma
82d3f50b78
Fix the OCP\BackgroundJob\Job to make it compatible with its interface
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-11-24 09:33:49 +01:00
Morris Jobke
f4c1512bb7
Fix typo in @deprecated PHPDoc tag
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-11-24 00:13:09 +01:00
Morris Jobke
9bf76d2bad
Streamline user creation and deletion events
...
CreateUserEvent was the only one that didn't matched the naming scheme of BeforePASTTENSEEvent and PASTTENSEEvent. The event wasn't used at all so this just removes it again as there is BeforeUserCreatedEvent that is also available since 18.
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-11-23 23:59:52 +01:00
Lukas Reschke
a5d4d3d4cc
Add IRequest taint sources
...
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2020-11-22 23:04:43 +01:00
Roeland Jago Douma
1e111b2ad2
Fix DataResponse typehints
...
We use this already in several places where we just pass strings or
numbers.
This all works because we just convert it to a json response in the end.
So better to have the typehints reflect this.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-11-19 20:34:42 +01:00
Roeland Jago Douma
66013f906d
Merge pull request #24189 from nextcloud/enh/csp/frame-ancestors
...
Set frame-ancestors to none if none are filled
2020-11-18 11:29:28 +01:00
Roeland Jago Douma
9163790b7c
Set frame-ancestors to none if none are filled
...
frame-ancestors doesn't fall back to default-src. So when we apply a
very restricted CSP we should make sure to set it to 'none' and not
leave it empty.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-11-18 10:13:36 +01:00
Roeland Jago Douma
72a9c35be3
Remove some IRouter methods
...
This is not the end. IRouter needs to burn.
But it is a start.
🎵 we didn't start the fire 🎵
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-11-17 14:08:20 +01:00
Joas Schilling
a8cb8e21c1
Add types to function builder
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-16 19:46:24 +01:00
Joas Schilling
d5df033ede
Create primary keys on all tables and add a command to create the afterwards
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-10 15:36:27 +01:00
Joas Schilling
d9e471771a
Update parameters
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-07 14:06:03 +01:00
Joas Schilling
ede7510854
Add a function to get the unread count for multiple objects in one go
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-04 11:01:21 +01:00