Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expand Fireproofing to include Local Storage and IndexedDB #408

Merged
merged 8 commits into from
Feb 2, 2022

Conversation

samsymons
Copy link
Collaborator

@samsymons samsymons commented Jan 28, 2022

Task/Issue URL: https://app.asana.com/0/1177771139624306/1200042850887108/f
Tech Design URL:
CC:

Description:

This PR updates the Fireproofing feature to preserve Local Storage and IndexedDB. It only preserves IndexedDB on macOS 12.2+, as earlier versions have a privacy flaw related to that feature (see the comment in the code for more).

Steps to test this PR:

Testing Fireproof sites:

  1. Sign into a site that stores data in Local Storage or IndexedDB; https://numer.ai/ is a good example, which uses Local Storage for its auth token
  2. Don't Fireproof it, and then use the Fire button; check that you are signed out
  3. Visit the site again, log in, Fireproof it, and burn once more
  4. Check that you were not signed out

Testing non-Fireproof sites:

  1. Visit some sites that aren't Fireproof, as well as some that are Fireproof
  2. Add a breakpoint in removeLocalStorageAndIndexedDBForNonFireproofDomains
  3. Use the Fire button and check that the right records are removed

Testing checklist:

  • Test with Release configuration

Internal references:

Software Engineering Expectations
Technical Design Template
When ready for review, remember to post the PR in MM

@brindy brindy self-assigned this Jan 31, 2022
Copy link
Contributor

@brindy brindy left a comment

Choose a reason for hiding this comment

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

LGTM!

Didn't test on 12.2 but commented out the available check and it left indexed db database in place when burning.

@samsymons
Copy link
Collaborator Author

@brindy So sorry – I realized belatedly that the additional step I added to remove Local Storage and IndexedDB for domains that aren't Fireproof hadn't been pushed yet (without that change, all domains would have had this data retained), so I've done that and added a bit of bonus variable/function renaming to clear things up. Would you be able to take another look? 🙏

Copy link
Contributor

@brindy brindy left a comment

Choose a reason for hiding this comment

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

Make sense! LGTM!

@samsymons samsymons merged commit fe0a685 into develop Feb 2, 2022
@samsymons samsymons deleted the sam/update-fireproofing branch February 2, 2022 02:54
samsymons added a commit that referenced this pull request Feb 3, 2022
# By Sam Symons (1) and others
# Via GitHub
* develop:
  Move embedded TDS from BSK to platform repo (#412)
  Image of shield with dot replaced (#410)
  Expand Fireproofing to include Local Storage and IndexedDB (#408)

# Conflicts:
#	DuckDuckGo.xcodeproj/project.pbxproj
samsymons added a commit that referenced this pull request Feb 18, 2022
# By Alexey Martemyanov (20) and others
# Via Tomas Strba (2) and others
* develop: (63 commits)
  Tweaks of suggestions and autocomplete (#403)
  Bump privacy dashboard to latest version (#409)
  Point to the latest BrowserServicesKit branch. (#414)
  Move embedded TDS from BSK to platform repo (#412)
  Image of shield with dot replaced (#410)
  Expand Fireproofing to include Local Storage and IndexedDB (#408)
  Version 0.18.5
  support privacy config for clickToLoad (#407)
  Automatically select available login (#405)
  initial FB Click to Load (WIP) (#329)
  onboarding updates (#398)
  Version 0.18.4
  Configuration of Sparkle - Setting SUAllowsAutomaticUpdates to NO (#404)
  Hide downloads button if the popover is opened/closed manually (#397)
  Textfield of the homepage is empty and unfocused right after switching to the homepage (#400)
  Remove navigatorCredentials (#392)
  Remove GPC header if it exists when not needed (#366)
  Version 0.18.3
  Fireproofing encrypted storage (#332)
  Fix Lock Screen UI issues (#399)
  ...

# Conflicts:
#	DuckDuckGo.xcodeproj/project.pbxproj
#	DuckDuckGo/Crash Reports/Model/CrashReportSender.swift
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