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

BSK support for FB CTL update #760

Merged
merged 25 commits into from
Jun 14, 2024
Merged

BSK support for FB CTL update #760

merged 25 commits into from
Jun 14, 2024

Conversation

ladamski
Copy link
Collaborator

@ladamski ladamski commented Apr 4, 2024

Please review the release process for BrowserServicesKit here.

Required:

Task/Issue URL: https://app.asana.com/0/72649045549333/1205105078450227/f
iOS PR: TBD (hopefully N/A)
macOS PR: duckduckgo/macos-browser#2162
What kind of version bump will this require?: Major/Minor/Patch

Optional:

Tech Design URL: https://app.asana.com/0/1201720254973470/1206422390411022/f
CC:

Description:
Updates BSK to support separate clickToLoad rule list, with associated surrogates changes. CTL is disabled for iOS

Steps to test this PR:
1.
1.

OS Testing:

  • iOS 14
  • iOS 15
  • iOS 16
  • macOS 10.15
  • macOS 11
  • macOS 12

Internal references:

Software Engineering Expectations
Technical Design Template

@ladamski ladamski force-pushed the la/clicktoload-redux branch from 0402bab to a4ec422 Compare April 10, 2024 02:26
@ladamski ladamski changed the title BSK support for FB CTL update (WIP) BSK support for FB CTL update Apr 17, 2024
@ladamski ladamski marked this pull request as ready for review April 17, 2024 21:45
@ladamski ladamski force-pushed the la/clicktoload-redux branch from 20e59fa to 717db16 Compare April 23, 2024 18:56
@duckduckgo duckduckgo deleted a comment Apr 23, 2024
Copy link

github-actions bot commented May 1, 2024

This PR has been inactive for more than 7 days and will be automatically closed 7 days from now.

@github-actions github-actions bot added the stale label May 1, 2024
Copy link

github-actions bot commented May 9, 2024

This PR has been closed after 14 days of inactivity. Feel free to reopen it if you plan to continue working on it or have further discussions.

@github-actions github-actions bot closed this May 9, 2024
@ladamski ladamski reopened this May 9, 2024
@github-actions github-actions bot removed the stale label May 10, 2024
Copy link

This PR has been inactive for more than 7 days and will be automatically closed 7 days from now.

@github-actions github-actions bot added the stale label May 17, 2024
@github-actions github-actions bot removed the stale label May 18, 2024
Copy link

This PR has been inactive for more than 7 days and will be automatically closed 7 days from now.

@github-actions github-actions bot added the stale label May 30, 2024
ladamski and others added 4 commits May 30, 2024 22:12
@github-actions github-actions bot removed the stale label Jun 1, 2024
@ladamski ladamski requested a review from jaceklyp June 7, 2024 16:26
@ladamski ladamski dismissed jaceklyp’s stale review June 14, 2024 14:32

Review addressed

@ladamski ladamski merged commit e9e239f into main Jun 14, 2024
7 checks passed
@ladamski ladamski deleted the la/clicktoload-redux branch June 14, 2024 14:33
ladamski added a commit to duckduckgo/macos-browser that referenced this pull request Jun 14, 2024
Task/Issue URL:
https://app.asana.com/0/72649045549333/1205105078450227/f
Tech Design URL:
https://app.asana.com/0/1201720254973470/1206422390411022/f
CC:

**Description**:
This requires the corresponding BSK PR to test:
duckduckgo/BrowserServicesKit#760
Note that his PR also relies on a custom config URL for testing
purposes, to enable this new codepath. Once we merge the [corresponding
privacy config
PR](https://royal-thankful-weight.glitch.me/macos-config.json), the URL
will be reverted to the production version prior to final review &
merge.

**Steps to test this PR**:
Verify blocking
1. Navigate to
https://privacy-test-pages.site/privacy-protections/click-to-load/
2. Ensure request are blocked ("Facebook Resources Loads: NONE")
3. No social buttons should be shown ("All the social buttons from the
SDK" & "All the social buttons in iFrames")
4. Login button should be replaced with a DDG overlay and hover
5. All posts should be replaced with DDG overlays

Verify clicking through overlays
1. Click on several of the CTL overlays. They should disappear and be
replaced with the underlying FB content (note that this test page is
rather old so some posts may take several seconds to load, or even time
out)

Verify protections toggling
1. Turn protections off
4. FB requests should be allowed ("Facebook Resources Loads: DETECTED")
5. Both sets of social buttons should show up 
6. Login button should by the stock FB one (no DDG hover tip)
7. All FB content should be shown without any CTL overlays

Test login with FB
1. Navigate to
https://www.eventbrite.com/signin/?iss=https%3A%2F%2Fid.auth.eventbrite.com%2F
and/or https://www.grubhub.com/login
2. For eventbrite, a small round FB icon should be present
3. For grubhub, "Continue with Facebook" should be present
4. Click on the login button
5. You should see a DDG dialog warning the user about continuing
("Logging in with Facebook lets them track you")
6. Click on "Log In"
7. A new window should open with an FB login

At this point that means that CTL blocking rules have been removed and
the real FB sdk injected in place of the surrogate (otherwise the FB
window content would not appear)
Optionally you can complete the login process, but its not strictly
necessary.

<!--
Tagging instructions
If this PR isn't ready to be merged for whatever reason it should be
marked with the `DO NOT MERGE` label (particularly if it's a draft)
If it's pending Product Review/PFR, please add the `Pending Product
Review` label.

If at any point it isn't actively being worked on/ready for
review/otherwise moving forward (besides the above PR/PFR exception)
strongly consider closing it (or not opening it in the first place). If
you decide not to close it, make sure it's labelled to make it clear the
PRs state and comment with more information.
-->

---
###### Internal references:
[Pull Request Review
Checklist](https://app.asana.com/0/1202500774821704/1203764234894239/f)
[Software Engineering
Expectations](https://app.asana.com/0/59792373528535/199064865822552)
[Technical Design
Template](https://app.asana.com/0/59792373528535/184709971311943)
[Pull Request
Documentation](https://app.asana.com/0/1202500774821704/1204012835277482/f)

---------

Co-authored-by: Jacek Łyp <[email protected]>
Co-authored-by: Bartek Waresiak <[email protected]>
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.

3 participants