refactor(encryption): add typing and modernize IEncryptionModule - #57551
Open
joshtrichards wants to merge 24 commits into
Open
refactor(encryption): add typing and modernize IEncryptionModule#57551joshtrichards wants to merge 24 commits into
joshtrichards wants to merge 24 commits into
Conversation
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
They're now all well defined in the interface (and mostly already were). The rare implementation specific bits retained. Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
One is always an int but the other is a string and often more than than the raw position, but an id marker (e.g. `5end`). Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
Signed-off-by: Josh <josh.t.richards@gmail.com>
joshtrichards
force-pushed
the
jtr/chore-IEncryptionModule-typing
branch
from
February 4, 2026 20:00
5947bef to
7ab2238
Compare
joshtrichards
marked this pull request as ready for review
February 4, 2026 20:08
joshtrichards
requested review from
CarlSchwan,
come-nc,
leftybournes,
salmart-dev and
sorbaugh
and removed request for
a team
February 4, 2026 20:09
come-nc
reviewed
Mar 2, 2026
| */ | ||
| namespace OCP\Encryption; | ||
|
|
||
| use OC\Encryption\Exceptions\DecryptionFailedException; |
Contributor
There was a problem hiding this comment.
It’s not allowed to reference OC classes in OCP.
So either add a public interface for the exception, or document as @throws \Exception
| * @throws MultiKeyEncryptException | ||
| */ | ||
| public function end($path, $position = '0') { | ||
| public function end(string $path, string $blockId = '0'): string { |
Contributor
There was a problem hiding this comment.
This is technically a breaking change because of named parameters.
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Should be fully backwards compatible.
P.S.
$positionwas already a de facto string. Any type related changes indicated in this PR for that parameter merely make it match implementation (and drop some casting). And despite it's name, it's used for string concatenation (at least in the context relevant to this PR).TODO
Checklist
3. to review, feature component)stable32)