Skip to content

Remove logins time_of_last_breach column#7244

Merged
jo merged 1 commit intomozilla:mainfrom
jo:remove-breach-info
Mar 4, 2026
Merged

Remove logins time_of_last_breach column#7244
jo merged 1 commit intomozilla:mainfrom
jo:remove-breach-info

Conversation

@jo
Copy link
Copy Markdown
Contributor

@jo jo commented Feb 25, 2026

In #7127, we added breach alerts support.

However, in further discussions, we came to the conclusion that the column time_of_last_breach is not directly necessary, as this information can also be pulled from the Remote Settings during runtime. Performance optimizations should be subordinate to the principle of data spareness.

Therefore, this PR removes the time_of_last_breach column introduced in #7127, along with their accessors. Since this column is not yet used in Mobile, no data migration is necessary.

BREAKING CHANGES

  • Removed time_of_last_breach field from LoginMeta and Login. This can be derived from Remote Settings during runtime instead.

  • Removed record_breach(id, timestamp) API method.

  • Removed is_potentially_breached(id) API method.

  • Removed is_breach_alert_dismissed(id) API method.

  • reset_all_breaches() now clears the breachesL password table instead of resetting time_of_last_breach timestamps.

  • Schema migrated to version 5: timeOfLastBreach column dropped from loginsL and loginsM.

The Phab Patch to adapt LoginsStorage.kt and Types.kt: https://phabricator.services.mozilla.com/D285208

Pull Request checklist

  • Breaking changes: This PR follows our breaking change policy
    • This PR follows the breaking change policy:
      • This PR has no breaking API changes, or
      • There are corresponding PRs for our consumer applications that resolve the breaking changes and have been approved
  • Quality: This PR builds and tests run cleanly
    • Note:
      • For changes that need extra cross-platform testing, consider adding [ci full] to the PR title.
      • If this pull request includes a breaking change, consider cutting a new release after merging.
  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Changelog: This PR includes a changelog entry in CHANGELOG.md or an explanation of why it does not need one
    • Any breaking changes to Swift or Kotlin binding APIs are noted explicitly
  • Dependencies: This PR follows our dependency management guidelines
    • Any new dependencies are accompanied by a summary of the due diligence applied in selecting them.

@jo jo force-pushed the remove-breach-info branch from 716dd3f to 6a1f361 Compare February 25, 2026 16:19
@bendk bendk mentioned this pull request Feb 26, 2026
5 tasks
@jo jo force-pushed the remove-breach-info branch 3 times, most recently from 402c728 to 080247f Compare February 26, 2026 15:55
@jo jo changed the title wip: remove breach info wip: remove logins time_of_last_breach column Feb 27, 2026
In mozilla#7127, we added breach alerts support.

However, in further discussions, we came to the conclusion that the
column `time_of_last_breach` is not directly necessary, as this
information can also be pulled from the Remote Settings during runtime.
Performance optimizations should be subordinate to the principle of data
spareness.

Therefore, this PR removes the `time_of_last_breach` column introduced
in mozilla#7127. Since this column is not yet used in Mobile, no data migration
is necessary.
@jo jo force-pushed the remove-breach-info branch from 080247f to fe7668b Compare February 27, 2026 11:16
@jo jo changed the title wip: remove logins time_of_last_breach column Remove logins time_of_last_breach column Mar 2, 2026
@jo jo requested a review from bendk March 2, 2026 17:06
Copy link
Copy Markdown
Contributor

@bendk bendk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks right to me and the plan outlined makes sense.

What's happening with record_potentially_vulnerable_passwords? Is that still needed if you're getting the breach data from remote settings?

@jo
Copy link
Copy Markdown
Contributor Author

jo commented Mar 2, 2026

What's happening with record_potentially_vulnerable_passwords? Is that still needed if you're getting the breach data from remote settings?

Yes, this is still needed, same with last_time_breach_alert_dismissed.

@jo jo added this pull request to the merge queue Mar 4, 2026
Merged via the queue into mozilla:main with commit 4a68a06 Mar 4, 2026
13 checks passed
@jo jo deleted the remove-breach-info branch March 4, 2026 14:40
lando-worker Bot pushed a commit to mozilla-firefox/firefox that referenced this pull request Mar 4, 2026
…iewers,matt-tighe

to adapt to breaking as changes in
mozilla/application-services#7244.

timeOfLastBreach can be retrieved from Remote Settings during runtime. No
data migration needed, because this data has not been actively used yet.

Differential Revision: https://phabricator.services.mozilla.com/D285208
lando-worker Bot pushed a commit to mozilla-firefox/firefox that referenced this pull request Mar 6, 2026
…iewers,matt-tighe

to adapt to breaking as changes in
mozilla/application-services#7244.

timeOfLastBreach can be retrieved from Remote Settings during runtime. No
data migration needed, because this data has not been actively used yet.

Differential Revision: https://phabricator.services.mozilla.com/D285208
akliuxingyuan pushed a commit to akliuxingyuan/android-components that referenced this pull request Apr 23, 2026
…iewers,matt-tighe

to adapt to breaking as changes in
mozilla/application-services#7244.

timeOfLastBreach can be retrieved from Remote Settings during runtime. No
data migration needed, because this data has not been actively used yet.

Differential Revision: https://phabricator.services.mozilla.com/D285208
akliuxingyuan pushed a commit to akliuxingyuan/android-components that referenced this pull request Apr 23, 2026
…iewers,matt-tighe

to adapt to breaking as changes in
mozilla/application-services#7244.

timeOfLastBreach can be retrieved from Remote Settings during runtime. No
data migration needed, because this data has not been actively used yet.

Differential Revision: https://phabricator.services.mozilla.com/D285208
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants