Repository navigation
Conversation
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.
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
Each
metavalue in a roster entry must now be base64url and nothing else, and an entry can't carry an emptymetaobject, as flow-sync #103 specifies.metastays opaque past that: it isn't decoded at parse, so non-canonical trailing bits and a length that can't be decoded both stay valid, and such a name is only left out when shown.apply_entryruns the same shape check asparse_entry. A LAN welcome's entries arrive withoutparse_entry, so one that broke the rule would have been saved at join and then failed to read back.parse_entry, so a parser that decodedmetawould fail them.a_signed_name_that_can_not_be_read_is_left_outused a value the rule now refuses; it uses one of an undecodable length instead.The 16 KiB limit in UTF-8 bytes in that PR is the server's, so nothing changes here for it.
Follows flow-sync #103.
Related issue
None.
Change type
Validation
Run on macOS arm64.
pnpm test: not run, no frontend file changedpnpm build: not run, no frontend file changedcargo fmt --manifest-path src-tauri/Cargo.toml --all -- --check: exit 0cargo clippy --all-targets --all-featuresinsrc-tauri: exit 0, no warnings from this change; one existing warning inroster.rson a function it doesn't touchcargo test --no-fail-fast --all-targets --all-featuresinsrc-tauri: 1286 passed, 0 failed, 9 ignoredBefore the change, the roster negatives failed. Checked by breaking the code on purpose, one change at a time, with
sync2_roster:-is refused_is refusedmetais decoded strictly at parseapply_entryskips the shape checkRisk and compatibility
No format or database change. Both apps already write unpadded base64url.
apply_entrynow also refuses any other shape fault in an entry that skipped the parser, on the LAN welcome path.A group that already holds an entry breaking this rule stops at that entry. Only a hand-made entry can do that.
Not run against Android or a server under this rule.
Overlaps other open PRs on
roster.json, the fixtures README and the changelog, so whichever lands later takes the fixtures again.No new secrets, private data, telemetry, or broad Tauri permissions were introduced.
User-facing documentation was updated where needed. (
spec/protocol.mdin flow-sync chore(deps): bump the compatible-updates group across 1 directory with 20 updates #103)Dependency and lockfile changes are intentional and limited to this PR. (none)
Breaking changes and upgrade steps are clearly documented. (none for honest clients)