Skip to content

connector: keep the E2EE reconnect prompt after a restart - #298

Merged
highesttt merged 1 commit into
mainfrom
indent/line-keep-e2ee-relogin-state
Oct 30, 2026
Merged

highesttt merged 1 commit into
mainfrom
indent/line-keep-e2ee-relogin-state

Conversation

@indent

@indent indent Bot commented Oct 30, 2026

Copy link
Copy Markdown
Contributor

What the logs show. Over the last 24 h, 11 production logins logged DecryptMessageV2 failed on retry with missing my private key (409 lines; 100-300 a day for the past week). Each one reaches the user as "[Unable to decrypt LINE message.]". 10 of those 11 logins currently report CONNECTED. Two of them did get line-e2ee-key-missing right after a re-login that kept stale keys, but the next restart flipped them back to CONNECTED. One login has been failing for at least 5 days and never showed the prompt.

Cause. ForceFullE2EELogin is saved in metadata, but missingE2EEKeyMarked only lives in memory. After a restart, Connect sends CONNECTED. Then on the next missing-key failure, markMissingE2EEKey sees the flag already saved (needsSave == false) and returns before it sends the bridge state.

Change.

  • sendConnectedStateIfCurrent sends line-e2ee-key-missing instead of CONNECTED while the flag is set, and marks the client so SSE reconnects don't overwrite it.
  • markMissingE2EEKey now always sends the state the first time this client sees a missing key. It only skips the save.

Built with go build ./... and go vet ./pkg/connector/. go test -short ./pkg/connector/ passes.

View in Indent
Tag @indent to continue the conversation here.

A login flagged for a full E2EE reconnect went back to CONNECTED on the
next restart, and later decrypt failures never resent the prompt because
markMissingE2EEKey returned early when the flag was already saved. Send
line-e2ee-key-missing at connect while the flag is set, and always send it
when a missing key is first seen by this client.
@indent indent Bot added the to be tested label Oct 30, 2026
@indent

indent Bot commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor Author

Issues

No issues found.

CI Checks

All CI checks passed on 302e9d9.

Review agents

Select any unchecked box below to run or rerun that agent.

Passed (1)
  • Indent Review Agent · No issues found in the E2EE restart fix.
Full results

Indent Review Agent

  • Summary: No issues found in the E2EE restart fix.
  • Last ran on commit: 302e9d98
  • Latest result
    {
      "summary": "No issues found in the E2EE restart fix.",
      "findings": []
    }

@iFixRobots
iFixRobots requested a review from highesttt October 30, 2026 11:07
@highesttt
highesttt merged commit 8762708 into main Oct 30, 2026
9 checks passed
@highesttt
highesttt deleted the indent/line-keep-e2ee-relogin-state branch October 30, 2026 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

2 participants