Robin Appelman
edaa436345
add key location to info:file output
Signed-off-by: Robin Appelman <robin@icewind.nl>
5 місяці тому
Côme Chilliet
c1d67cc614
chore: Fix DI for Encryption\DecryptAll command
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
5 місяці тому
Robin Appelman
0492e0f1d4
Revert "add key location to info:file output"
This reverts commit 7bf82fc312
.
5 місяці тому
Robin Appelman
7bf82fc312
add key location to info:file output
Signed-off-by: Robin Appelman <robin@icewind.nl>
5 місяці тому
Joas Schilling
aa5f037af7
chore: apply changes from Nextcloud coding standards 1.1.1
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
7 місяці тому
Robin Appelman
e4f85226c5
extend fix-key-location to handle cases from broken cross-storage moves
Signed-off-by: Robin Appelman <robin@icewind.nl>
1 рік тому
Faraz Samapoor
e7cc7653b8
Refactors "strpos" calls in lib/private to improve code readability.
Signed-off-by: Faraz Samapoor <fsamapoor@gmail.com>
1 рік тому
Côme Chilliet
426c0341ff
Use typed version of IConfig::getSystemValue as much as possible
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
1 рік тому
Côme Chilliet
f5c361cf44
composer run cs:fix
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
1 рік тому
Robin Appelman
c2b206db64
add marker interface to mark system mount points for encryption
Signed-off-by: Robin Appelman <robin@icewind.nl>
1 рік тому
Carl Schwan
458c2fa297
Remove OCP\App and OCP\BackgroundJob
Both deprecated since NC 23
IAppManager is the replacement for OCP\App unfortunately it can't be
dependency injected in classes used by the installed otherwise the
database connection is initialised too early
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2 роки тому
Carl Schwan
d5c23dbb9f
Move CappedMemoryCache to OCP
This is an helpful helper that should be used in more place than just
server and this is already the case with groupfodlers, deck, user_oidc
and more using it, so let's make it public
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2 роки тому
Carl Schwan
5907bba3fd
Fix hook encryption with cron job
Make sure the setup fs is set before using the Update service
Fix #29674
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2 роки тому
Vincent Petry
a704bcf97f
Trim mount point before matching in encryption code
Often times the mount point has a leading slash.
This fix sanitizes it to make sure matching works.
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2 роки тому
Carl Schwan
ec6b83cc18
Add stricter psalm type for CappedMemoryCache
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2 роки тому
Côme Chilliet
6be7aa112f
Migrate from ILogger to LoggerInterface in lib/private
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2 роки тому
J0WI
b344ff1a67
Refactor getEncryptionModule routine
3 роки тому
Robin Appelman
1052feabed
remove depricated methods from MountConfig
Signed-off-by: Robin Appelman <robin@icewind.nl>
3 роки тому
John Molakvoæ (skjnldsv)
215aef3cbd
Update php licenses
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
3 роки тому
Vincent Petry
82891cd498
Fix phpcs issues in encryption update
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
3 роки тому
Julius Härtl
76170a58eb
Log and continue when failing to update encryption keys during for individual files
Signed-off-by: Julius Härtl <jus@bitgrid.net>
3 роки тому
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>
3 роки тому
Roeland Jago Douma
317118ef79
Catch throwable instead of exception
The error that gets thrown can also be a type error etc. So we should
properly catch the Throwable.
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
3 роки тому
Robin Appelman
8501cf9b5c
dont apply encryption wrapper for root mount
the `shouldEncrypt` already disables encryption for anything thats not in the users data folder,
however the encryption wrapper being applied anyway on the root folder breaks groupfolders
Signed-off-by: Robin Appelman <robin@icewind.nl>
3 роки тому
Christoph Wurst
d89a75be0b
Update all license headers for Nextcloud 21
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 роки тому
Christoph Wurst
d9015a8c94
Format code to a single space around binary operators
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 роки тому
Christoph Wurst
2a054e6c04
Update the license headers for Nextcloud 20
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 роки тому
Roeland Jago Douma
5340ab3a75
New SSE key format
* Encrypt the keys with the instance secret
* Store them as json (so we can add other things if needed)
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
4 роки тому
Morris Jobke
065ef14cb0
Move OC_Mount_Config to proper classname and remove OC::$CLASSPATH usage in files_external
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
4 роки тому
Christoph Wurst
cb057829f7
Update license headers for 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
Christoph Wurst
28f8eb5dba
Add visibility to all constants
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
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>
4 роки тому
Christoph Wurst
44577e4345
Remove trailing and in between spaces
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
Christoph Wurst
afbd9c4e6e
Unify function spacing to PSR2 recommendation
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
Christoph Wurst
41b5e5923a
Use exactly one empty line after the namespace declaration
For PSR2
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
Christoph Wurst
85e369cddb
Fix multiline comments
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
Christoph Wurst
1a9330cd69
Update the license headers for Nextcloud 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
Christoph Wurst
b80ebc9674
Use the short array syntax, everywhere
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
sammo2828
bb0c69524b
Keep the modification time during decryptFile
4 роки тому
Christoph Wurst
5bf3d1bb38
Update license headers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 роки тому
Roeland Jago Douma
68748d4f85
Some php-cs fixes
* Order the imports
* No leading slash on imports
* Empty line before namespace
* One line per import
* Empty after imports
* Emmpty line at bottom of file
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
4 роки тому
Bjoern Schiessle
a2eaf48f6f
list files which could not be decrypted
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
5 роки тому
Robin Appelman
2c1f6331a4
Add interface to allow storages from opting out of encryption
As opposed to hard-coding a list of excluded storages
Signed-off-by: Robin Appelman <robin@icewind.nl>
5 роки тому
Bjoern Schiessle
d76a87f3b0
skip already decrypted files on decrypt all command
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
5 роки тому
Roeland Jago Douma
74f0e37233
Remove deprecated \OCP\User::userExists
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
6 роки тому
Roeland Jago Douma
6c8caa1641
Remove deprecated \OCP\User::getUsers
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
6 роки тому
Bjoern Schiessle
8042e6b8fb
this was a migration step to ownCloud 8.0 to restructure the encryption folder which is no longer needed
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
6 роки тому
Morris Jobke
6bbea33133
Simplify ternary operator statements
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
6 роки тому
Morris Jobke
0eebff152a
Update license headers
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
6 роки тому
Bjoern Schiessle
da51ec38f4
only collect detailed access list if it is really needed
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
7 роки тому