Commit Graph

17 Commits (feat/database/query-result-fetch-associative-fetch-num)

Author SHA1 Message Date
Côme Chilliet 1e06b61f59 Migrate away from ILogger in encryption
And modernize code a bit

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-08-08 09:14:16 +07:00
Vincent Petry 3bcbc4701a
Merge pull request #34724 from nextcloud/encryption-read-before-cache
fix reading newly written encrypted files before their cache entry is written
2022-12-20 17:16:12 +07:00
Vincent Petry 4f2923862a
Merge pull request #35108 from nextcloud/encryption-fix-versions-all
allow running encryption:fix-encrypted-version for all users
2022-12-16 17:20:40 +07:00
J0WI 71e490090f Replace getSystemValue in encryption app
Signed-off-by: J0WI <J0WI@users.noreply.github.com>
2022-12-05 14:30:58 +07:00
Robin Appelman e3a0e64698
clear is-encrypted cache when trying to fix encrypted version
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-12-01 14:36:27 +07:00
Robin Appelman 2399710356
allow running encryption:fix-encrypted-version for all users
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-29 17:49:35 +07:00
Robin Appelman 06b2ed2641
skip files that cant be opened for FixEncryptedVersion
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-22 16:40:12 +07:00
Côme Chilliet b20278f708
Fix encryption:fix-encrypted-version command when encrypted is set to 0
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-08-02 12:47:26 +07:00
Côme Chilliet bd467e5d66
Improve typing in FixEncryptedVersion command
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-08-02 12:11:15 +07:00
Côme Chilliet 37f8f7a5a1
Fix tests on PHP 8.1 for encryption, files_sharing, files_version,
files_trashbin and theming apps

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2021-12-16 09:43:29 +07:00
Vincent Petry 60e44077b7
Fix encrypted version to 0 when finding unencrypted file
Whenever the command is run and a "legacy cipher" seems to be detected
when the legacy option is disabled, it's highly likely that the file is
actually unencrypted but the database contains a encrypted version
higher than 0 for some reason.

The command now detects this case and automatically sets the encrypted
version to 0 so that the file can be read again.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-08-26 10:44:49 +07:00
Gary Kim b78f3a57d1
Migrate HintException to OCP
Signed-off-by: Gary Kim <gary@garykim.dev>
2021-06-30 15:28:02 +07:00
Vincent Petry d3eeecba54
Prevent running FixEncryptedVersion without master key
Return an error when running occ encryption:fix-encrypted-version
when master key encryption is not enabled.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-06-29 20:44:07 +07:00
Vincent Petry 101c65a949
Fix FixEncryptedVersionTest test
Fixed setup to use EncryptionTrait like other existing tests.
Fix expectations to not rely on side effects from previous test cases.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-06-29 14:39:51 +07:00
Vincent Petry 6170912ace
Fix warnings in FixEncryptedVersion command
Fixed code warnings

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-06-29 14:39:51 +07:00
Vincent Petry 4e9241c706
Detect disabled signature check when reparing
When running occ encryption:fix-encrypted-version, detect whether the
setting 'encryption_skip_signature_check' is set and abort if it is,
because the repair cannot detect version mismatch errors with it
enabled.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-06-29 14:39:51 +07:00
Vincent Petry a6dc81d419
Downstream encryption:fix-encrypted-version
For fixing "Bad signature" errors.

Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-06-29 14:39:51 +07:00