Skip to content
This repository was archived by the owner on Feb 24, 2025. It is now read-only.

Conversation

@diegoreymendez
Copy link
Contributor

@diegoreymendez diegoreymendez commented Aug 21, 2023

Task/Issue URL: https://app.asana.com/0/0/1205112155849085/f
BSK PR: duckduckgo/BrowserServicesKit#469
iOS PR: duckduckgo/iOS#1928

Description:

Prevents launching our menu agent app without a valid NetP auth code.

Steps to test this PR:

Before running these tests, open Keychain.app and remove all auth tokens. You'll need to enable NetP again through an invite code.

Start in develop

  1. Run NetP normally using the latest from develop (this is important so the auth token is not shared).
  2. Connect.
  3. Once connected, reset the system extension and login item (through the debug menu).
  4. Quit the app.
  5. Open Keychain.app, search for the auth token that matches your app build type and make sure it shows the following access group:
Screenshot 2023-08-21 at 21 22 10
  1. Switch to this branch
  2. Start the app
  3. Open Keychain.app, search for the app token, it should have been moved to a build specific app group:
Screenshot 2023-08-21 at 21 23 01
  1. Start NetP and make sure it works.
  2. Stop NetP, reset extension and login item through the debug menu
  3. Open Keychain.app, and remove all auth tokens.
  4. Go to /Applications/DEBUG/DuckDuckGo.app/Contents/Library/LoginItems/
  5. Double click on DuckDuckGo Agent
  6. Make sure the menu app does not open for you - ie: you can't see the icon in the status bar.

Internal references:

Pull Request Review Checklist
Software Engineering Expectations
Technical Design Template
Pull Request Documentation

Signed-off-by: Diego Rey Mendez <dreymendez@duckduckgo.com>
@diegoreymendez diegoreymendez changed the title Diego/prevent netp activation without authcode Prevents launching our menu agent without an auth code. Aug 21, 2023
@diegoreymendez diegoreymendez requested review from mallexxx and removed request for mallexxx August 21, 2023 19:06
…thout-authcode-step1' into diego/prevent-netp-activation-without-authcode

Signed-off-by: Diego Rey Mendez <dreymendez@duckduckgo.com>

# Conflicts:
#	DuckDuckGo.xcodeproj/project.pbxproj
#	DuckDuckGo/NetworkProtection/AppTargets/BothAppTargets/NetworkProtectionAppEvents.swift
@diegoreymendez diegoreymendez changed the base branch from develop to diego/prevent-netp-activation-without-authcode-step1 August 21, 2023 19:18
Copy link
Contributor

@graeme graeme left a comment

Choose a reason for hiding this comment

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

Seems to be a bit of dead code there, but feel free to merge once removed (unless I missed something…)

diegoreymendez added a commit to duckduckgo/BrowserServicesKit that referenced this pull request Aug 23, 2023
Task/Issue URL: https://app.asana.com/0/0/1205319547453836/f
iOS PR: duckduckgo/iOS#1928
macOS PR: duckduckgo/macos-browser#1516
What kind of version bump will this require?: Patch

## Description:

Small change to `KeychainType` to make the code cleaner.

**Steps to test this PR**:

Follow the testing steps in the macOS PR.
Base automatically changed from diego/prevent-netp-activation-without-authcode-step1 to develop August 23, 2023 14:16
@diegoreymendez diegoreymendez merged commit 41a1d63 into develop Aug 23, 2023
@diegoreymendez diegoreymendez deleted the diego/prevent-netp-activation-without-authcode branch August 23, 2023 14:53
diegoreymendez added a commit to duckduckgo/iOS that referenced this pull request Aug 23, 2023
Task/Issue URL: https://app.asana.com/0/0/1205319558799772/f
BSK PR: duckduckgo/BrowserServicesKit#469
macOS PR: duckduckgo/macos-browser#1516

## Description

Changes the code so that we can specify which keychain to use.

There should be no logical changes whatsoever.
samsymons added a commit that referenced this pull request Aug 23, 2023
# By Diego Rey Mendez (7) and others
# Via Sam Symons (2) and others
* develop: (26 commits)
  Improve Sync-related database cleaning logic (#1529)
  Update onboarding-related error states (#1504)
  Prevents launching our menu agent without an auth code. (#1516)
  Autofill UI letter icons (#1535)
  Cleans up some code (#1517)
  Revert "Autofill Letter Icons" (#1534)
  Adds remote pre-commit installer, which includes automatic fix for linter (#1369)
  Autofill Letter Icons (#1475)
  change context menu for mailto links (#1513)
  Updates the version to 1.53.1
  Updated the embedded files for 1.53.1
  Update the phased rollout tester to avoid caching the config (#1520)
  Require Duck Player scheme URL to be passed from YouTube Overlay User Script (#1519)
  Add pixels related to Duck Player usage (#1515)
  only allow error reloads on http(s) urls (#1523)
  Standardize TDS Loading Error handling (#1524)
  Move pixel sender logic into the main view controller (#1528)
  Update the phased rollout tester to avoid caching the config (#1520)
  Set version to 1.52.3.
  Move pixel sender logic into the main view controller (#1528)
  ...

# Conflicts:
#	DuckDuckGo.xcodeproj/project.pbxproj
#	DuckDuckGo.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved
#	DuckDuckGo/AppDelegate/AppDelegate.swift
#	DuckDuckGo/Common/Localizables/UserText.swift
#	DuckDuckGo/Common/Utilities/UserDefaultsWrapper.swift
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants