Jonas
7441ce2b11
enh(IMountManager): Add method to get MountPoint from CachedMountInfo
...
Signed-off-by: Jonas <jonas@freesources.org>
2023-10-23 20:50:24 +02:00
Jonas
9193d8be40
fix(isLegitimatedForUserId): Setup mountpoints to check file access
...
This fixes workflows on groupfolders, as it will consider access to
files in groupfolders.
It also fixes false positives where access to files was limited by other
means not taken into account before, e.g. access control.
For postDelete events, check for permissions of the parent folder
instead, as the file itself no longer exists.
Fixes : nextcloud/flow_notifications#71
Signed-off-by: Jonas <jonas@freesources.org>
2023-10-23 20:47:16 +02:00
Côme Chilliet
0a9371f99f
Migrate applications away from deprecated ILogger
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-09-21 11:57:21 +02:00
Côme Chilliet
bfe42de8f8
Merge pull request #38604 from fsamapoor/replace_strpos_calls_in_workflowengine_app
...
Refactors "strpos" calls in /apps/workflowengine
2023-08-07 09:10:43 +02:00
Joas Schilling
77bc6c32d8
fix(dispatcher): Move remaining simple cases in apps/ folder to IEventDispatcher
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-07-25 11:19:26 +02:00
Joas Schilling
aa039c986a
fix(workflowengine): Remove legacy event (deprecated since 17)
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-07-19 17:37:34 +02:00
Julius Härtl
06d80ba809
fix: Avoid failing with duplicate checks
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-07-12 16:54:13 +02:00
Joas Schilling
33913ebc34
fix(workflowengine): Fix tested user agents of Android and iOS to match real ones
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-07-11 07:40:22 +02:00
Faraz Samapoor
5db241b942
Refactors "strpos" calls in /apps/workflowengine to improve code readability.
...
Signed-off-by: Faraz Samapoor <f.samapoor@gmail.com>
Signed-off-by: Faraz Samapoor <fsa@adlas.at>
2023-07-03 13:13:11 +03:30
Joas Schilling
15fc42966c
Also check the scope when reading operations from the database
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-02-23 06:13:00 +01:00
Joas Schilling
c6700150d5
Validate the scope when validating operations
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-02-23 06:13:00 +01:00
Julius Härtl
aebf654214
perf(workflowengine): Cache query that is performed on every request
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-02-10 14:33:07 +01:00
Robin Appelman
cb4648df77
add some tests for mimetype check
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-12-20 13:28:40 +01:00
John Molakvoæ (skjnldsv)
215aef3cbd
Update php licenses
...
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2021-06-04 22:02:41 +02:00
Arthur Schiwon
1eb86e46fd
inform the user when flow config data exceeds thresholds
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-10-28 14:07:14 +01:00
Morris Jobke
234b510652
Change PHPDoc type hint from PHPUnit_Framework_MockObject_MockObject to \PHPUnit\Framework\MockObject\MockObject
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-08-12 13:55:19 +02:00
Arthur Schiwon
b59efb61bd
Flow File entity implements IContextPortation
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2020-08-05 15:21:57 +02:00
Christoph Wurst
caff1023ea
Format control structures, classes, methods and function
...
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>
2020-04-10 14:19:56 +02:00
Christoph Wurst
14c996d982
Use elseif instead of else if
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-10 10:35:09 +02:00
Christoph Wurst
afbd9c4e6e
Unify function spacing to PSR2 recommendation
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-09 13:54:22 +02:00
Christoph Wurst
41b5e5923a
Use exactly one empty line after the namespace declaration
...
For PSR2
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-04-09 11:48:10 +02:00
Christoph Wurst
2ee65f177e
Use the shorter phpunit syntax for mocked return values
...
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-03-25 22:21:27 +01:00
Julius Härtl
e4829236cf
Add app config to disable user flows
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-03-21 08:58:41 +01:00
Roeland Jago Douma
25d4f3230d
Use the new Events in Flow
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-01-02 16:40:49 +01:00
Arthur Schiwon
2d34274c8a
adjust unit test
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-11-28 14:25:50 +01:00
Roeland Jago Douma
3a7cf40aaa
Mode to modern phpunit
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2019-11-27 15:27:18 +01:00
Roeland Jago Douma
c007ca624f
Make phpunit8 compatible
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2019-11-27 13:34:41 +01:00
Arthur Schiwon
2efe8aad38
relax dependency on GenericEvent, instead stay compatible with old events
...
* also fixes tagging events
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-11-13 14:23:39 +01:00
Arthur Schiwon
f889ea8373
fix manager tests
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-09-10 12:01:12 +02:00
Julius Härtl
9eb7a31864
Fix test mocking
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2019-09-10 08:59:51 +02:00
Arthur Schiwon
ed58343e60
split events DB field into entity and events, adjust biz logic
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-09-09 22:56:03 +02:00
Arthur Schiwon
827dd896fa
extend DB table, manager, controller with support for entity events
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-09-09 22:56:03 +02:00
Arthur Schiwon
fe2a78609a
add missing dep
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-09-09 22:56:02 +02:00
Arthur Schiwon
4aba1f1cff
scope aware workflow controller and manager
...
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-09-09 22:56:02 +02:00
Arthur Schiwon
804d4fe69f
introducing Entity interfaces and a File one as first implementation
...
also adds admin settings that pass entities as initial state
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2019-09-09 22:56:01 +02:00
Joas Schilling
f81d4eb060
Make the Outlook and Thunderbird addons identifyable
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-02-27 14:37:32 +01:00
Joas Schilling
bf2be08c9f
Fix risky tests without assertions
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-01-25 11:33:25 +01:00
Morris Jobke
43e498844e
Use ::class in test mocks
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2017-10-24 17:45:32 +02:00
Joas Schilling
4d6ec43402
Do not reset the list after adding cached entries
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2016-10-17 15:43:21 +02:00
Joas Schilling
6aa5d674d6
Translate the errors
2016-08-01 17:56:33 +02:00
Joas Schilling
e0b5949a9f
Add request time
2016-08-01 17:19:05 +02:00
Joas Schilling
2cfd67e13b
Add remote address
2016-08-01 17:19:05 +02:00
Joas Schilling
8a753342ee
Add file mime type
2016-08-01 17:19:04 +02:00